summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterpreference.cpp
diff options
context:
space:
mode:
authorJonathan Yap <jhwelch@gmail.com>2014-12-01 15:36:59 -0500
committerJonathan Yap <jhwelch@gmail.com>2014-12-01 15:36:59 -0500
commit7360f046634d013fec1e9b37c60840a83b470ce1 (patch)
treed41efe489e36c05d3c3f02d9904ed79a3ff4dc4d /indra/newview/llfloaterpreference.cpp
parent3e9c3b36960fd17cba9114bc2e4564208346b92e (diff)
STORM-2082 Better control on how (or if) to display Default preset
Make sure default preset is created when flyout panel is activated Only display deleted notification upon successful deletion
Diffstat (limited to 'indra/newview/llfloaterpreference.cpp')
-rwxr-xr-xindra/newview/llfloaterpreference.cpp17
1 files changed, 7 insertions, 10 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 521cc59dda..97af9d6ce0 100755
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -744,15 +744,7 @@ void LLFloaterPreference::onOpen(const LLSD& key)
saveSettings();
// Make sure there is a default preference file
- std::string default_file = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, PRESETS_DIR, PRESETS_GRAPHIC, "default.xml");
- if (!gDirUtilp->fileExists(default_file))
- {
- LL_WARNS() << "No " << default_file << " found -- creating one" << LL_ENDL;
- // Write current graphic settings to default.xml
- // If this name is to be localized additional code will be needed to delete the old default
- // when changing languages.
- LLPresetsManager::getInstance()->savePreset(PRESETS_GRAPHIC, "Default");
- }
+ LLPresetsManager::getInstance()->createMissingDefault();
bool started = (LLStartUp::getStartupState() == STATE_STARTED);
@@ -2121,6 +2113,10 @@ void LLPanelPreference::onChangePreset(const LLSD& user_data)
}
}
+void LLPanelPreference::setHardwareDefaults()
+{
+}
+
class LLPanelPreferencePrivacy : public LLPanelPreference
{
public:
@@ -2183,7 +2179,8 @@ void LLPanelPreferenceGraphics::setPresetNamesInComboBox()
{
LLComboBox* combo = getChild<LLComboBox>("graphic_preset_combo");
- LLPresetsManager::getInstance()->setPresetNamesInComboBox(PRESETS_GRAPHIC, combo);
+ EDefaultOptions option = DEFAULT_POSITION_TOP;
+ LLPresetsManager::getInstance()->setPresetNamesInComboBox(PRESETS_GRAPHIC, combo, option);
}
void LLPanelPreferenceGraphics::draw()