summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterenvironmentsettings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterenvironmentsettings.cpp')
-rw-r--r--indra/newview/llfloaterenvironmentsettings.cpp20
1 files changed, 17 insertions, 3 deletions
diff --git a/indra/newview/llfloaterenvironmentsettings.cpp b/indra/newview/llfloaterenvironmentsettings.cpp
index e8d123a955..4dbc8cdee0 100644
--- a/indra/newview/llfloaterenvironmentsettings.cpp
+++ b/indra/newview/llfloaterenvironmentsettings.cpp
@@ -260,9 +260,23 @@ void LLFloaterEnvironmentSettings::populateDayCyclePresetsList()
{
mDayCyclePresetCombo->removeall();
- const LLDayCycleManager::dc_map_t& map = LLDayCycleManager::instance().getPresets();
- for (LLDayCycleManager::dc_map_t::const_iterator it = map.begin(); it != map.end(); ++it)
+ LLDayCycleManager::preset_name_list_t user_days, sys_days;
+ LLDayCycleManager::instance().getPresetNames(user_days, sys_days);
+
+ // Add user days.
+ for (LLDayCycleManager::preset_name_list_t::const_iterator it = user_days.begin(); it != user_days.end(); ++it)
+ {
+ mDayCyclePresetCombo->add(*it);
+ }
+
+ if (user_days.size() > 0)
+ {
+ mDayCyclePresetCombo->addSeparator();
+ }
+
+ // Add system days.
+ for (LLDayCycleManager::preset_name_list_t::const_iterator it = sys_days.begin(); it != sys_days.end(); ++it)
{
- mDayCyclePresetCombo->add(it->first);
+ mDayCyclePresetCombo->add(*it);
}
}