summaryrefslogtreecommitdiff
path: root/indra/newview/llpaneloutfitedit.cpp
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2010-06-21 12:20:24 -0400
committerNat Goodspeed <nat@lindenlab.com>2010-06-21 12:20:24 -0400
commitf17623d8c67a10c2d7547e40ac8442c703d107ed (patch)
tree2ae37385da280a758a66e920f9bdb317dcde59ee /indra/newview/llpaneloutfitedit.cpp
parent4e538adca41d486125c3b887ce694c457bcab157 (diff)
parentbef22c0325cbfeb3d290753a66ecf862bf4593d3 (diff)
Automated merge with ssh://192.168.2.107/c:/linden/viewer-release/
Diffstat (limited to 'indra/newview/llpaneloutfitedit.cpp')
-rw-r--r--indra/newview/llpaneloutfitedit.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/indra/newview/llpaneloutfitedit.cpp b/indra/newview/llpaneloutfitedit.cpp
index 8da7432e0a..5fac7efb84 100644
--- a/indra/newview/llpaneloutfitedit.cpp
+++ b/indra/newview/llpaneloutfitedit.cpp
@@ -60,6 +60,7 @@
#include "llinventorybridge.h"
#include "llinventorymodel.h"
#include "llinventorymodelbackgroundfetch.h"
+#include "llloadingindicator.h"
#include "llpaneloutfitsinventory.h"
#include "lluiconstants.h"
#include "llsaveoutfitcombobtn.h"
@@ -262,6 +263,9 @@ LLPanelOutfitEdit::LLPanelOutfitEdit()
observer.addBOFChangedCallback(boost::bind(&LLPanelOutfitEdit::updateVerbs, this));
observer.addOutfitLockChangedCallback(boost::bind(&LLPanelOutfitEdit::updateVerbs, this));
observer.addCOFChangedCallback(boost::bind(&LLPanelOutfitEdit::update, this));
+
+ gAgentWearables.addLoadingStartedCallback(boost::bind(&LLPanelOutfitEdit::onOutfitChanging, this, true));
+ gAgentWearables.addLoadedCallback(boost::bind(&LLPanelOutfitEdit::onOutfitChanging, this, false));
mFolderViewItemTypes.reserve(NUM_FOLDER_VIEW_ITEM_TYPES);
for (U32 i = 0; i < NUM_FOLDER_VIEW_ITEM_TYPES; i++)
@@ -902,6 +906,27 @@ void LLPanelOutfitEdit::showFilteredWearablesListView(LLWearableType::EType type
applyListViewFilter((EListViewItemType) (LVIT_SHAPE + type));
}
+static void update_status_widget_rect(LLView * widget, S32 right_border)
+{
+ LLRect rect = widget->getRect();
+ rect.mRight = right_border;
+ widget->setShape(rect);
+}
+
+void LLPanelOutfitEdit::onOutfitChanging(bool started)
+{
+ static LLLoadingIndicator* indicator = getChild<LLLoadingIndicator>("edit_outfit_loading_indicator");
+ static LLView* status_panel = getChild<LLView>("outfit_name_and_status");
+ static S32 indicator_delta = status_panel->getRect().getWidth() - indicator->getRect().mLeft;
+
+ S32 delta = started ? indicator_delta : 0;
+ S32 right_border = status_panel->getRect().getWidth() - delta;
+
+ update_status_widget_rect(mCurrentOutfitName, right_border);
+ update_status_widget_rect(mStatus, right_border);
+
+ indicator->setVisible(started);
+}
// EOF