summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterdeleteenvpreset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterdeleteenvpreset.cpp')
-rw-r--r--indra/newview/llfloaterdeleteenvpreset.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/indra/newview/llfloaterdeleteenvpreset.cpp b/indra/newview/llfloaterdeleteenvpreset.cpp
index b78e124e07..4fed5b9d5a 100644
--- a/indra/newview/llfloaterdeleteenvpreset.cpp
+++ b/indra/newview/llfloaterdeleteenvpreset.cpp
@@ -222,11 +222,17 @@ void LLFloaterDeleteEnvPreset::populateDayCyclesList()
mPresetCombo->removeall();
- // *TODO: Disable current day cycle.
+ std::string cur_day;
+ LLEnvManagerNew& env_mgr = LLEnvManagerNew::instance();
+ if (!env_mgr.getUseRegionSettings() && env_mgr.getUseDayCycle())
+ {
+ cur_day = env_mgr.getDayCycleName();
+ }
+
const LLDayCycleManager::dc_map_t& map = LLDayCycleManager::instance().getPresets();
for (LLDayCycleManager::dc_map_t::const_iterator it = map.begin(); it != map.end(); ++it)
{
- mPresetCombo->add(it->first);
+ mPresetCombo->add(it->first, ADD_BOTTOM, it->first != cur_day);
}
postPopulate();