diff options
| author | Jonathan Yap <jhwelch@gmail.com> | 2014-11-26 18:03:36 -0500 |
|---|---|---|
| committer | Jonathan Yap <jhwelch@gmail.com> | 2014-11-26 18:03:36 -0500 |
| commit | f71247ea542805819b82640759e1f44fd0599e7f (patch) | |
| tree | eba9a1311c584acb6e860862bd0b955dd3f4cdee /indra/newview/llfloaterpreference.cpp | |
| parent | 78060b7fd2688b113917b58dea25b072779ac4f6 (diff) | |
STORM-2082 Code now fills combobox
Diffstat (limited to 'indra/newview/llfloaterpreference.cpp')
| -rwxr-xr-x | indra/newview/llfloaterpreference.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index cea17aeef4..39f37f4e50 100755 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -2117,9 +2117,18 @@ BOOL LLPanelPreferenceGraphics::postBuild() graphic_preset->setLabel(getString("graphic_preset_combo_label")); std::string presets_dir = LLPresetsManager::getGraphicPresetsDir(); + if (!presets_dir.empty()) { - LLPresetsManager::getInstance()->getPresetsFromDir(presets_dir); + LLPresetsManager::getInstance()->loadPresetsFromDir(presets_dir); + std::list<std::string> preset_names; + LLPresetsManager::getInstance()->getPresetNames(preset_names); + + for (std::list<std::string>::const_iterator it = preset_names.begin(); it != preset_names.end(); ++it) + { + const std::string& name = *it; + graphic_preset->add(name, LLSD().with(0, name)); + } } else { LL_WARNS() << "Could not obtain graphic presets path" << LL_ENDL; |
