diff options
author | Jonathan Yap <jhwelch@gmail.com> | 2014-12-03 06:35:46 -0500 |
---|---|---|
committer | Jonathan Yap <jhwelch@gmail.com> | 2014-12-03 06:35:46 -0500 |
commit | cc22efa4c0d6b06bac6f49b6243df7726f89c7c4 (patch) | |
tree | 4ab1120c671cfb5953ee7e4f362df2da0ea319d9 /indra/newview/llfloaterdeleteprefpreset.cpp | |
parent | ade3953e380d9211ad6d332b9b27fa23e57a7d81 (diff) |
STORM-2082 Remove Apply button.
Add new control variable to track which preset is active. Save settings
to active preset when clicking on Ok button.
Initial work to make pulldown operational. Still to do: add pretty icon for current preset.
Notifications do not appear when called from this panel.
Diffstat (limited to 'indra/newview/llfloaterdeleteprefpreset.cpp')
-rw-r--r-- | indra/newview/llfloaterdeleteprefpreset.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/indra/newview/llfloaterdeleteprefpreset.cpp b/indra/newview/llfloaterdeleteprefpreset.cpp index 01b25398dd..d92aaa5659 100644 --- a/indra/newview/llfloaterdeleteprefpreset.cpp +++ b/indra/newview/llfloaterdeleteprefpreset.cpp @@ -28,11 +28,11 @@ #include "llfloaterdeleteprefpreset.h" -#include "llpresetsmanager.h" - #include "llbutton.h" #include "llcombobox.h" #include "llnotificationsutil.h" +#include "llpresetsmanager.h" +#include "llviewercontrol.h" LLFloaterDeletePrefPreset::LLFloaterDeletePrefPreset(const LLSD &key) : LLFloater(key) @@ -69,6 +69,11 @@ void LLFloaterDeletePrefPreset::onBtnDelete() if (LLPresetsManager::getInstance()->deletePreset(mSubdirectory, name)) { + if (name == gSavedSettings.getString("PresetGraphicActive")) + { + LLPresetsManager::getInstance()->savePreset(mSubdirectory, PRESETS_DEFAULT); + } + LLSD args; args["NAME"] = name; LLNotificationsUtil::add("PresetDeleted", args); |