diff options
author | paul_productengine <none@none> | 2011-02-11 13:49:10 +0200 |
---|---|---|
committer | paul_productengine <none@none> | 2011-02-11 13:49:10 +0200 |
commit | 90c9b9e9c5cd9be3a620bf5e1d5b5d233573548c (patch) | |
tree | c219202baebaf496588f7f3f80aefa68b0c30743 /indra/newview/llrecentpeople.h | |
parent | 547b40bfc8b0139789a2d9c5dcd1591343a2c60b (diff) |
STORM-680 FIXED (Avaline callers are added to the Recent list)
- When accepting an avaline call, add a caller to the recent list as AvalineListItem
- When adding item to the LLRecentPeople, check whether item with the same phone number exists and delete it if exists. This is need to avoid duplication in the Recent list of the panel People.
Diffstat (limited to 'indra/newview/llrecentpeople.h')
-rw-r--r-- | indra/newview/llrecentpeople.h | 33 |
1 files changed, 30 insertions, 3 deletions
diff --git a/indra/newview/llrecentpeople.h b/indra/newview/llrecentpeople.h index 852a92ff80..d0d6376867 100644 --- a/indra/newview/llrecentpeople.h +++ b/indra/newview/llrecentpeople.h @@ -58,9 +58,15 @@ public: * Add specified avatar to the list if it's not there already. * * @param id avatar to add. + * + * @param userdata additional information about last interaction party. + * For example when last interaction party is not an avatar + * but an avaline caller, additional info (such as phone + * number, session id and etc.) should be added. + * * @return false if the avatar is in the list already, true otherwise */ - bool add(const LLUUID& id); + bool add(const LLUUID& id, const LLSD& userdata = LLSD().with("date", LLDate::now())); /** * @param id avatar to search. @@ -75,7 +81,25 @@ public: */ void get(uuid_vec_t& result) const; - const LLDate& getDate(const LLUUID& id) const; + /** + * Returns last interaction time with specified participant + * + */ + const LLDate getDate(const LLUUID& id) const; + + /** + * Returns data about specified participant + * + * @param id identifier of specific participant + */ + const LLSD& getData(const LLUUID& id) const; + + /** + * Checks whether specific participant is an avaline caller + * + * @param id identifier of specific participant + */ + bool isAvalineCaller(const LLUUID& id) const; /** * Set callback to be called when the list changed. @@ -92,7 +116,10 @@ public: /*virtual*/ bool handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata); private: - typedef std::map<LLUUID, LLDate> recent_people_t; + + const LLUUID& getIDByPhoneNumber(const LLSD& userdata); + + typedef std::map<LLUUID, LLSD> recent_people_t; recent_people_t mPeople; signal_t mChangedSignal; }; |