aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llviewermenu.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'linden/indra/newview/llviewermenu.cpp')
-rw-r--r--linden/indra/newview/llviewermenu.cpp48
1 files changed, 38 insertions, 10 deletions
diff --git a/linden/indra/newview/llviewermenu.cpp b/linden/indra/newview/llviewermenu.cpp
index 6a7a818..fb69389 100644
--- a/linden/indra/newview/llviewermenu.cpp
+++ b/linden/indra/newview/llviewermenu.cpp
@@ -546,6 +546,11 @@ void LLMenuParcelObserver::changed()
546// code required to calculate anything about the menus 546// code required to calculate anything about the menus
547void pre_init_menus() 547void pre_init_menus()
548{ 548{
549 if (gMenuHolder)
550 {
551 cleanup_menus();
552 }
553
549 // static information 554 // static information
550 LLColor4 color; 555 LLColor4 color;
551 color = gColors.getColor( "MenuDefaultBgColor" ); 556 color = gColors.getColor( "MenuDefaultBgColor" );
@@ -10143,15 +10148,28 @@ class LLAdvancedTogglePrivateLookPointAt : public view_listener_t
10143{ 10148{
10144 bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata) 10149 bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
10145 { 10150 {
10146 // Noate: PrivateLookAtTarget also hides point at -- MC 10151 std::string command = userdata.asString();
10147 bool new_value = !gSavedSettings.getBOOL("PrivateLookAtTarget"); 10152 if ("Look" == command)
10148 if (new_value)
10149 { 10153 {
10150 // Disable show look at and show point at if you make yours private. It's only fair, after all -- MC 10154 bool new_value = !gSavedSettings.getBOOL("PrivateLookAtTarget");
10151 LLHUDEffectLookAt::sDebugLookAt = FALSE; 10155 if (new_value)
10152 LLHUDEffectPointAt::sDebugPointAt = FALSE; 10156 {
10157 // Disable show look at and show point at if you make yours private. It's only fair, after all -- MC
10158 LLHUDEffectLookAt::sDebugLookAt = FALSE;
10159 LLHUDEffectPointAt::sDebugPointAt = FALSE;
10160 }
10161 gSavedSettings.setBOOL("PrivateLookAtTarget", new_value);
10153 } 10162 }
10154 gSavedSettings.setBOOL("PrivateLookAtTarget", new_value); 10163 else if ("Point" == command)
10164 {
10165 bool new_value = !gSavedSettings.getBOOL("PrivatePointAtTarget");
10166
10167 // do not disable show look at and show point at if you make yours private,
10168 // since this only hides the arm motion while editing -- AW
10169
10170 gSavedSettings.setBOOL("PrivatePointAtTarget", new_value);
10171 }
10172
10155 return true; 10173 return true;
10156 } 10174 }
10157}; 10175};
@@ -10160,9 +10178,19 @@ class LLAdvancedCheckPrivateLookPointAt : public view_listener_t
10160{ 10178{
10161 bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata) 10179 bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
10162 { 10180 {
10163 bool new_value = gSavedSettings.getBOOL("PrivateLookAtTarget"); 10181 std::string command = userdata["data"].asString();
10164 std::string control_name = userdata["control"].asString(); 10182 if ("Look" == command)
10165 gMenuHolder->findControl(control_name)->setValue(new_value); 10183 {
10184 bool new_value = gSavedSettings.getBOOL("PrivateLookAtTarget");
10185 std::string control_name = userdata["control"].asString();
10186 gMenuHolder->findControl(control_name)->setValue(new_value);
10187 }
10188 else if ("Point" == command)
10189 {
10190 bool new_value = gSavedSettings.getBOOL("PrivatePointAtTarget");
10191 std::string control_name = userdata["control"].asString();
10192 gMenuHolder->findControl(control_name)->setValue(new_value);
10193 }
10166 return true; 10194 return true;
10167 } 10195 }
10168}; 10196};