summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llappearancemgr.cpp8
-rw-r--r--indra/newview/llappearancemgr.h2
-rw-r--r--indra/newview/llpaneloutfitedit.cpp2
3 files changed, 12 insertions, 0 deletions
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 0bd95987d7..4a30ba3066 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -1579,6 +1579,14 @@ bool LLAppearanceMgr::updateBaseOutfit()
return true;
}
+void LLAppearanceMgr::wearBaseOutfit()
+{
+ const LLUUID& base_outfit_id = getBaseOutfitUUID();
+ if (base_outfit_id.isNull()) return;
+
+ updateCOF(base_outfit_id);
+}
+
//#define DUMP_CAT_VERBOSE
void LLAppearanceMgr::dumpCat(const LLUUID& cat_id, const std::string& msg)
diff --git a/indra/newview/llappearancemgr.h b/indra/newview/llappearancemgr.h
index befad591bd..d67a7787d3 100644
--- a/indra/newview/llappearancemgr.h
+++ b/indra/newview/llappearancemgr.h
@@ -129,6 +129,8 @@ public:
// Create initial outfits from library.
void autopopulateOutfits();
+ void wearBaseOutfit();
+
// Overrides the base outfit with the content from COF
// @return false if there is no base outfit
bool updateBaseOutfit();
diff --git a/indra/newview/llpaneloutfitedit.cpp b/indra/newview/llpaneloutfitedit.cpp
index 2e94eabb3f..d1e6d7de42 100644
--- a/indra/newview/llpaneloutfitedit.cpp
+++ b/indra/newview/llpaneloutfitedit.cpp
@@ -232,6 +232,8 @@ BOOL LLPanelOutfitEdit::postBuild()
childSetAction("remove_item_btn", boost::bind(&LLPanelOutfitEdit::onRemoveFromLookClicked, this), this);
+ childSetAction("revert_btn", boost::bind(&LLAppearanceMgr::wearBaseOutfit, LLAppearanceMgr::getInstance()));
+
childSetAction("save_btn", boost::bind(&LLPanelOutfitEdit::saveOutfit, this, false));
childSetAction("save_as_btn", boost::bind(&LLPanelOutfitEdit::saveOutfit, this, true));
childSetAction("save_flyout_btn", boost::bind(&LLPanelOutfitEdit::showSaveMenu, this));