diff options
author | andreykproductengine <akleshchev@productengine.com> | 2015-09-21 20:36:21 +0300 |
---|---|---|
committer | andreykproductengine <akleshchev@productengine.com> | 2015-09-21 20:36:21 +0300 |
commit | 47dfdff3c0d684e78bd72d671a0d840798076a87 (patch) | |
tree | a71c61cce3a12592da09bd01f7f05e19e2044f84 | |
parent | e28f920f9a6525207418ed9d96aada256a1d8228 (diff) |
MAINT-5570 limiting exposure of attachment manager
-rwxr-xr-x | indra/newview/llattachmentsmgr.cpp | 9 | ||||
-rwxr-xr-x | indra/newview/llattachmentsmgr.h | 5 | ||||
-rw-r--r-- | indra/newview/llavatarrendernotifier.cpp | 4 | ||||
-rwxr-xr-x | indra/newview/llvoavatar.cpp | 2 |
4 files changed, 12 insertions, 8 deletions
diff --git a/indra/newview/llattachmentsmgr.cpp b/indra/newview/llattachmentsmgr.cpp index 2a137cc39b..d3e66289d1 100755 --- a/indra/newview/llattachmentsmgr.cpp +++ b/indra/newview/llattachmentsmgr.cpp @@ -421,6 +421,15 @@ void LLAttachmentsMgr::onDetachCompleted(const LLUUID& inv_item_id) mQuestionableCOFLinks.addTime(inv_item_id); } +bool LLAttachmentsMgr::isAttachmentStateComplete() const +{ + return mPendingAttachments.empty() + && mAttachmentRequests.empty() + && mDetachRequests.empty() + && mRecentlyArrivedAttachments.empty() + && mQuestionableCOFLinks.empty(); +} + // Check for attachments that are (a) linked in COF and (b) not // attached to the avatar. This is a rotten function to have to // include, because it runs the risk of either repeatedly spamming out diff --git a/indra/newview/llattachmentsmgr.h b/indra/newview/llattachmentsmgr.h index fab146cb52..bb7d35edbc 100755 --- a/indra/newview/llattachmentsmgr.h +++ b/indra/newview/llattachmentsmgr.h @@ -87,10 +87,7 @@ public: void onDetachRequested(const LLUUID& inv_item_id); void onDetachCompleted(const LLUUID& inv_item_id); - bool hasPendingAttachments() { return mPendingAttachments.size() > 0; } - bool hasAttachmentRequests() { return mAttachmentRequests.size() > 0; } - bool hasDetachRequests() { return mAttachmentRequests.size() > 0; } - bool hasRecentlyArrivedAttachments() { return mRecentlyArrivedAttachments.size() > 0; } + bool isAttachmentStateComplete() const; private: diff --git a/indra/newview/llavatarrendernotifier.cpp b/indra/newview/llavatarrendernotifier.cpp index ca3c1a7310..53be573461 100644 --- a/indra/newview/llavatarrendernotifier.cpp +++ b/indra/newview/llavatarrendernotifier.cpp @@ -191,9 +191,7 @@ void LLAvatarRenderNotifier::updateNotificationState() if (mInitialCofVersion < 0 && gAgentWearables.areWearablesLoaded() - && !LLAttachmentsMgr::getInstance()->hasPendingAttachments() - && !LLAttachmentsMgr::getInstance()->hasAttachmentRequests() - && !LLAttachmentsMgr::getInstance()->hasRecentlyArrivedAttachments()) + && LLAttachmentsMgr::getInstance()->isAttachmentStateComplete()) { // cof formed mInitialCofVersion = LLAppearanceMgr::instance().getCOFVersion(); diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 3e20fbecdb..da02b96f80 100755 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -6458,7 +6458,7 @@ BOOL LLVOAvatar::processFullyLoadedChange(bool loading) mFullyLoadedInitialized = TRUE; mFullyLoadedFrameCounter++; - if (isSelf()) + if (changed && isSelf()) { // to know about outfit switching LLAvatarRenderNotifier::getInstance()->updateNotificationState(); |