summaryrefslogtreecommitdiff
path: root/indra/llcommon/llavatarname.h
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2012-12-07 00:10:50 -0800
committerMerov Linden <merov@lindenlab.com>2012-12-07 00:10:50 -0800
commitbb322a1cccd3fab28951ad4e11b5edcfc4e48140 (patch)
treefc6ac102b42ea1fd40c0be8e849acedfe4ad1367 /indra/llcommon/llavatarname.h
parent42a60e6ca5f4179738fa9a7376d1e842bc058ac4 (diff)
CHUI-580 : Fixed : Clean up the use of display name. Allow the use of the legacy protocol in settings.xml
Diffstat (limited to 'indra/llcommon/llavatarname.h')
-rw-r--r--indra/llcommon/llavatarname.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/indra/llcommon/llavatarname.h b/indra/llcommon/llavatarname.h
index cf9eb27b03..2f8c534974 100644
--- a/indra/llcommon/llavatarname.h
+++ b/indra/llcommon/llavatarname.h
@@ -39,20 +39,25 @@ public:
bool operator<(const LLAvatarName& rhs) const;
+ // Conversion to and from LLSD (cache file or server response)
LLSD asLLSD() const;
-
void fromLLSD(const LLSD& sd);
// Used only in legacy mode when the display name capability is not provided server side
- void fromString(const std::string& full_name, F64 expires = 0.0f);
+ // or to otherwise create a temporary valid item.
+ void fromString(const std::string& full_name);
+ // Set the name object to become invalid in "expires" seconds from now
+ void setExpires(F64 expires);
+
+ // Set and get the display name flag set by the user in preferences.
static void setUseDisplayNames(bool use);
static bool useDisplayNames();
- // Name is valid if not temporary and not yet expired
+ // A name object is valid if not temporary and not yet expired (default is expiration not checked)
bool isValidName(F64 max_unrefreshed = 0.0f) const { return !mIsTemporaryName && (mExpires >= max_unrefreshed); }
- //
+ // Return true if the name is made up from legacy or temporary data
bool isDisplayNameDefault() const { return mIsDisplayNameDefault; }
// For normal names, returns "James Linden (james.linden)"