summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatertoybox.cpp
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2011-10-12 18:13:01 -0700
committerMerov Linden <merov@lindenlab.com>2011-10-12 18:13:01 -0700
commit40ebe180a6592381804555d1c9e8df84bf35345a (patch)
tree523d687dedb2921d30e1d553184a8caa87ee3c45 /indra/newview/llfloatertoybox.cpp
parentaa1f0215c764fa346625ace43c467a0e0f803057 (diff)
parent1181e7c75747361e1a57f083cf82c63ef152bfc5 (diff)
Pull from richard/viewer-experience-fui
Diffstat (limited to 'indra/newview/llfloatertoybox.cpp')
-rw-r--r--indra/newview/llfloatertoybox.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/indra/newview/llfloatertoybox.cpp b/indra/newview/llfloatertoybox.cpp
index 84881655f8..b4c9894271 100644
--- a/indra/newview/llfloatertoybox.cpp
+++ b/indra/newview/llfloatertoybox.cpp
@@ -30,12 +30,13 @@
#include "llbutton.h"
#include "llcommandmanager.h"
+#include "llnotifications.h"
+#include "llnotificationsutil.h"
#include "llpanel.h"
#include "lltoolbar.h"
#include "lltoolbarview.h"
#include "lltrans.h"
-
LLFloaterToybox::LLFloaterToybox(const LLSD& key)
: LLFloater(key)
, mBtnRestoreDefaults(NULL)
@@ -113,9 +114,21 @@ void LLFloaterToybox::draw()
LLFloater::draw();
}
+static bool finish_restore_toybox(const LLSD& notification, const LLSD& response)
+{
+ S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
+
+ if (option == 0)
+ {
+ LLToolBarView::loadDefaultToolbars();
+ }
+ return false;
+}
+static LLNotificationFunctorRegistration finish_restore_toybox_reg("ConfirmRestoreToybox", finish_restore_toybox);
+
void LLFloaterToybox::onBtnRestoreDefaults()
{
- LLToolBarView::loadDefaultToolbars();
+ LLNotificationsUtil::add("ConfirmRestoreToybox");
}
BOOL LLFloaterToybox::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop,