From b901998c6f6642a3ada3193237253a29c8e637d3 Mon Sep 17 00:00:00 2001 From: Tofu Buzzard Date: Mon, 21 Nov 2011 09:20:09 -0500 Subject: Add "Use Region Settings" to World->Sun menu --- doc/contributions.txt | 1 + indra/newview/llviewermenu.cpp | 9 ++++++++- indra/newview/skins/default/xui/en/menu_viewer.xml | 8 ++++++++ 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index 2b39e15e2a..2ebbe34073 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -1114,6 +1114,7 @@ Tofu Buzzard CTS-411 STORM-546 VWR-24509 + STORM-1684 Tony Kembia Torben Trautman TouchaHoney Perhaps diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 22d95563d8..6d45e48d23 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -7701,7 +7701,14 @@ class LLWorldEnvSettings : public view_listener_t } else { - LLEnvManagerNew::instance().setUseDayCycle(LLEnvManagerNew::instance().getDayCycleName()); + LLEnvManagerNew &envmgr = LLEnvManagerNew::instance(); + // reset all environmental settings to track the region defaults, make this reset 'sticky' like the other sun settings. + bool use_fixed_sky = false; + bool use_region_settings = true; + envmgr.setUserPrefs(envmgr.getWaterPresetName(), + envmgr.getSkyPresetName(), + envmgr.getDayCycleName(), + use_fixed_sky, use_region_settings); } return true; diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml index 263d961be1..575e3673c6 100644 --- a/indra/newview/skins/default/xui/en/menu_viewer.xml +++ b/indra/newview/skins/default/xui/en/menu_viewer.xml @@ -533,6 +533,14 @@ function="World.EnvSettings" parameter="midnight" /> + + + + -- cgit v1.2.3