diff options
author | Callum Prentice <callum@lindenlab.com> | 2021-04-29 13:45:15 -0700 |
---|---|---|
committer | Callum Prentice <callum@lindenlab.com> | 2021-04-29 13:45:15 -0700 |
commit | 99b99a1b4a21758ef888b251d8f8bbf565f8b42e (patch) | |
tree | 5c91eaa4a6dffd724cdb0cb8f4de8c11f82335a5 /indra/llui/llurlentry.h | |
parent | 0df59ff9e6e50237d36a976731e81c6e37e73933 (diff) | |
parent | ce65bc2f13409d75dbc6502c970030cc5ed2e5ad (diff) |
Clean up a merge conflict
Diffstat (limited to 'indra/llui/llurlentry.h')
-rw-r--r-- | indra/llui/llurlentry.h | 24 |
1 files changed, 18 insertions, 6 deletions
diff --git a/indra/llui/llurlentry.h b/indra/llui/llurlentry.h index 0a0c247a6a..4af1ab5096 100644 --- a/indra/llui/llurlentry.h +++ b/indra/llui/llurlentry.h @@ -212,10 +212,14 @@ public: LLUrlEntryAgent(); ~LLUrlEntryAgent() { - if (mAvatarNameCacheConnection.connected()) + for (avatar_name_cache_connection_map_t::iterator it = mAvatarNameCacheConnections.begin(); it != mAvatarNameCacheConnections.end(); ++it) { - mAvatarNameCacheConnection.disconnect(); + if (it->second.connected()) + { + it->second.disconnect(); + } } + mAvatarNameCacheConnections.clear(); } /*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb); /*virtual*/ std::string getIcon(const std::string &url); @@ -227,7 +231,9 @@ protected: /*virtual*/ void callObservers(const std::string &id, const std::string &label, const std::string& icon); private: void onAvatarNameCache(const LLUUID& id, const LLAvatarName& av_name); - boost::signals2::connection mAvatarNameCacheConnection; + + typedef std::map<LLUUID, boost::signals2::connection> avatar_name_cache_connection_map_t; + avatar_name_cache_connection_map_t mAvatarNameCacheConnections; }; /// @@ -241,10 +247,14 @@ public: LLUrlEntryAgentName(); ~LLUrlEntryAgentName() { - if (mAvatarNameCacheConnection.connected()) + for (avatar_name_cache_connection_map_t::iterator it = mAvatarNameCacheConnections.begin(); it != mAvatarNameCacheConnections.end(); ++it) { - mAvatarNameCacheConnection.disconnect(); + if (it->second.connected()) + { + it->second.disconnect(); + } } + mAvatarNameCacheConnections.clear(); } /*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb); /*virtual*/ LLStyle::Params getStyle() const; @@ -253,7 +263,9 @@ protected: virtual std::string getName(const LLAvatarName& avatar_name) = 0; private: void onAvatarNameCache(const LLUUID& id, const LLAvatarName& av_name); - boost::signals2::connection mAvatarNameCacheConnection; + + typedef std::map<LLUUID, boost::signals2::connection> avatar_name_cache_connection_map_t; + avatar_name_cache_connection_map_t mAvatarNameCacheConnections; }; |