summaryrefslogtreecommitdiff
path: root/indra/newview/llavatarpropertiesprocessor.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llavatarpropertiesprocessor.h')
-rw-r--r--indra/newview/llavatarpropertiesprocessor.h103
1 files changed, 44 insertions, 59 deletions
diff --git a/indra/newview/llavatarpropertiesprocessor.h b/indra/newview/llavatarpropertiesprocessor.h
index 77bf5fd51e..0a1445419e 100644
--- a/indra/newview/llavatarpropertiesprocessor.h
+++ b/indra/newview/llavatarpropertiesprocessor.h
@@ -50,26 +50,34 @@ class LLMessageSystem;
enum EAvatarProcessorType
{
- APT_PROPERTIES,
- APT_NOTES,
- APT_GROUPS,
- APT_PICKS,
+ APT_PROPERTIES_LEGACY, // APT_PROPERTIES via udp request (Truncates data!!!)
+ APT_PROPERTIES, // APT_PROPERTIES via http request
APT_PICK_INFO,
APT_TEXTURES,
- APT_INTERESTS_INFO,
APT_CLASSIFIEDS,
APT_CLASSIFIED_INFO
};
-struct LLInterestsData
+// legacy data is supposed to match AvatarPropertiesReply,
+// but it is obsolete, fields like about_text will truncate
+// data, if you need them, use AgenProfile cap.
+// Todo: remove it once once icon ids get moved elsewhere,
+// since AgentProfile is too large for bulk icon requests
+struct LLAvatarLegacyData
{
LLUUID agent_id;
LLUUID avatar_id; //target id
- U32 want_to_mask;
- std::string want_to_text;
- U32 skills_mask;
- std::string skills_text;
- std::string languages_text;
+ LLUUID image_id;
+ LLUUID fl_image_id;
+ LLUUID partner_id;
+ std::string about_text;
+ std::string fl_about_text;
+ LLDate born_on;
+ std::string profile_url;
+ U8 caption_index;
+ std::string caption_text;
+ std::string customer_type;
+ U32 flags;
};
struct LLAvatarData
@@ -87,19 +95,28 @@ struct LLAvatarData
std::string caption_text;
std::string customer_type;
U32 flags;
- BOOL allow_publish;
-};
+ bool hide_age;
+ std::string notes;
-struct LLAvatarPicks
-{
- LLUUID agent_id;
- LLUUID target_id; //target id
+ struct LLGroupData;
+ typedef std::list<LLGroupData> group_list_t;
+ group_list_t group_list;
- typedef std::pair<LLUUID,std::string> pick_data_t;
+ typedef std::pair<LLUUID, std::string> pick_data_t;
typedef std::list< pick_data_t> picks_list_t;
picks_list_t picks_list;
};
+struct LLAvatarData::LLGroupData
+{
+ U64 group_powers;
+ BOOL accept_notices;
+ std::string group_title;
+ LLUUID group_id;
+ std::string group_name;
+ LLUUID group_insignia_id;
+};
+
struct LLPickData
{
LLUUID agent_id;
@@ -121,36 +138,6 @@ struct LLPickData
//used only in write (update) requests
LLUUID session_id;
-
-};
-
-struct LLAvatarNotes
-{
- LLUUID agent_id;
- LLUUID target_id; //target id
- std::string notes;
-};
-
-struct LLAvatarGroups
-{
- LLUUID agent_id;
- LLUUID avatar_id; //target id
- BOOL list_in_profile;
-
- struct LLGroupData;
- typedef std::list<LLGroupData> group_list_t;
-
- group_list_t group_list;
-
- struct LLGroupData
- {
- U64 group_powers;
- BOOL accept_notices;
- std::string group_title;
- LLUUID group_id;
- std::string group_name;
- LLUUID group_insignia_id;
- };
};
struct LLAvatarClassifieds
@@ -211,9 +198,7 @@ public:
// Request various types of avatar data. Duplicate requests will be
// suppressed while waiting for a response from the network.
void sendAvatarPropertiesRequest(const LLUUID& avatar_id);
- void sendAvatarPicksRequest(const LLUUID& avatar_id);
- void sendAvatarNotesRequest(const LLUUID& avatar_id);
- void sendAvatarGroupsRequest(const LLUUID& avatar_id);
+ void sendAvatarLegacyPropertiesRequest(const LLUUID& avatar_id);
void sendAvatarTexturesRequest(const LLUUID& avatar_id);
void sendAvatarClassifiedsRequest(const LLUUID& avatar_id);
@@ -222,21 +207,17 @@ public:
void sendClassifiedInfoRequest(const LLUUID& classified_id);
- void sendAvatarPropertiesUpdate(const LLAvatarData* avatar_props);
-
void sendPickInfoUpdate(const LLPickData* new_pick);
void sendClassifiedInfoUpdate(const LLAvatarClassifiedInfo* c_data);
void sendFriendRights(const LLUUID& avatar_id, S32 rights);
- void sendNotes(const LLUUID& avatar_id, const std::string notes);
-
void sendPickDelete(const LLUUID& pick_id);
void sendClassifiedDelete(const LLUUID& classified_id);
- void sendInterestsInfoUpdate(const LLInterestsData* interests_data);
+ bool isHideAgeSupportedByServer() { return mIsHideAgeSupportedByServer; }
// Returns translated, human readable string for account type, such
// as "Resident" or "Linden Employee". Used for profiles, inspectors.
@@ -249,9 +230,10 @@ public:
static bool hasPaymentInfoOnFile(const LLAvatarData* avatar_data);
- static void requestAvatarPropertiesCoro(std::string cap_url, LLUUID agent_id);
+ static void requestAvatarPropertiesCoro(std::string cap_url, LLUUID avatar_id, EAvatarProcessorType type);
- static void processAvatarPropertiesReply(LLMessageSystem* msg, void**);
+ // Processing of UDP variant of properties, truncates certain fields!
+ static void processAvatarLegacyPropertiesReply(LLMessageSystem* msg, void**);
static void processAvatarInterestsReply(LLMessageSystem* msg, void**);
@@ -272,7 +254,7 @@ protected:
void sendRequest(const LLUUID& avatar_id, EAvatarProcessorType type, const std::string &method);
void sendGenericRequest(const LLUUID& avatar_id, EAvatarProcessorType type, const std::string &method);
void sendAvatarPropertiesRequestMessage(const LLUUID& avatar_id);
- void initAgentProfileCapRequest(const LLUUID& avatar_id, const std::string& cap_url);
+ void initAgentProfileCapRequest(const LLUUID& avatar_id, const std::string& cap_url, EAvatarProcessorType type);
void notifyObservers(const LLUUID& id,void* data, EAvatarProcessorType type);
@@ -302,6 +284,9 @@ protected:
// Map avatar_id+request_type -> U32 timestamp in seconds
typedef std::map< std::pair<LLUUID, EAvatarProcessorType>, U32> timestamp_map_t;
timestamp_map_t mRequestTimestamps;
+
+ // Is returned by isHideAgeSupportedByServer()
+ bool mIsHideAgeSupportedByServer { false };
};
#endif // LL_LLAVATARPROPERTIESPROCESSOR_H