summaryrefslogtreecommitdiff
path: root/indra/newview/llagentwearables.cpp
diff options
context:
space:
mode:
authorVadim Savchuk <vsavchuk@productengine.com>2010-05-05 13:19:24 +0300
committerVadim Savchuk <vsavchuk@productengine.com>2010-05-05 13:19:24 +0300
commitd39ef5ce6fd52a66189e3e14da3a01b14b1d99a2 (patch)
tree6b6dcb98267da674ea6635c3d0f229a1438f18d0 /indra/newview/llagentwearables.cpp
parentc4070bd67266f9dffd333221ef2ff41a88523169 (diff)
Implemented task EXT-7156 (Appearance panel: "Wear" button should become disabled and a loading indicator should appear next to the outfit name).
When user presses the "Wear" button in the outfits list, we disable the button and display a perpetual loading indicator until all wearables of the outfit being worn get loaded. Reviewed by Sergey Litovchuk at https://codereview.productengine.com/secondlife/r/347/ --HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llagentwearables.cpp')
-rw-r--r--indra/newview/llagentwearables.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp
index b5fde0baca..47735e7179 100644
--- a/indra/newview/llagentwearables.cpp
+++ b/indra/newview/llagentwearables.cpp
@@ -1164,6 +1164,7 @@ void LLAgentWearables::createStandardWearablesAllDone()
mWearablesLoaded = TRUE;
checkWearablesLoaded();
+ mLoadedSignal();
updateServer();
@@ -1567,6 +1568,7 @@ void LLAgentWearables::setWearableOutfit(const LLInventoryItem::item_array_t& it
// Start rendering & update the server
mWearablesLoaded = TRUE;
checkWearablesLoaded();
+ mLoadedSignal();
queryWearableCache();
updateServer();
@@ -2012,6 +2014,10 @@ BOOL LLAgentWearables::areWearablesLoaded() const
void LLAgentWearables::updateWearablesLoaded()
{
mWearablesLoaded = (itemUpdatePendingCount()==0);
+ if (mWearablesLoaded)
+ {
+ mLoadedSignal();
+ }
}
bool LLAgentWearables::canWearableBeRemoved(const LLWearable* wearable) const
@@ -2091,3 +2097,8 @@ void LLAgentWearables::populateMyOutfitsFolder(void)
outfits->done();
}
}
+
+boost::signals2::connection LLAgentWearables::addLoadedCallback(loaded_callback_t cb)
+{
+ return mLoadedSignal.connect(cb);
+}