From 2722047e162730d33806e15c033803435a906d7b Mon Sep 17 00:00:00 2001 From: Jacek Antonelli Date: Tue, 27 Jan 2009 02:47:35 -0600 Subject: Restored View > Toolbar and Show HUD Attachments. Partial revert of earlier commit e79a1cc5. --- linden/indra/newview/llviewermenu.cpp | 29 ++++++++++++++++++++++ .../skins/default/xui/en-us/menu_viewer.xml | 10 ++++++++ 2 files changed, 39 insertions(+) (limited to 'linden') diff --git a/linden/indra/newview/llviewermenu.cpp b/linden/indra/newview/llviewermenu.cpp index 4c6de79..c4cbf84 100644 --- a/linden/indra/newview/llviewermenu.cpp +++ b/linden/indra/newview/llviewermenu.cpp @@ -5073,6 +5073,10 @@ class LLShowFloater : public view_listener_t { LLFloaterPreference::show(NULL); } + else if (floater_name == "toolbar") + { + LLToolBar::toggle(NULL); + } else if (floater_name == "chat history") { LLFloaterChat::toggleInstance(LLSD()); @@ -5205,6 +5209,10 @@ class LLFloaterVisible : public view_listener_t { new_value = LLFloaterMyFriends::instanceVisible(0); } + else if (floater_name == "toolbar") + { + new_value = LLToolBar::visible(NULL); + } else if (floater_name == "chat history") { new_value = LLFloaterChat::instanceVisible(); @@ -7203,6 +7211,25 @@ class LLViewCheckRenderType : public view_listener_t } }; +class LLViewShowHUDAttachments : public view_listener_t +{ + bool handleEvent(LLPointer event, const LLSD& userdata) + { + LLPipeline::sShowHUDAttachments = !LLPipeline::sShowHUDAttachments; + return true; + } +}; + +class LLViewCheckHUDAttachments : public view_listener_t +{ + bool handleEvent(LLPointer event, const LLSD& userdata) + { + bool new_value = LLPipeline::sShowHUDAttachments; + gMenuHolder->findControl(userdata["control"].asString())->setValue(new_value); + return true; + } +}; + class LLEditEnableTakeOff : public view_listener_t { bool handleEvent(LLPointer event, const LLSD& userdata) @@ -9657,6 +9684,7 @@ void initialize_menus() addMenu(new LLViewToggleBeacon(), "View.ToggleBeacon"); addMenu(new LLViewBeaconWidth(), "View.BeaconWidth"); addMenu(new LLViewToggleRenderType(), "View.ToggleRenderType"); + addMenu(new LLViewShowHUDAttachments(), "View.ShowHUDAttachments"); addMenu(new LLViewZoomOut(), "View.ZoomOut"); addMenu(new LLViewZoomIn(), "View.ZoomIn"); addMenu(new LLViewZoomDefault(), "View.ZoomDefault"); @@ -9671,6 +9699,7 @@ void initialize_menus() addMenu(new LLViewCheckHighlightTransparent(), "View.CheckHighlightTransparent"); addMenu(new LLViewCheckBeaconEnabled(), "View.CheckBeaconEnabled"); addMenu(new LLViewCheckRenderType(), "View.CheckRenderType"); + addMenu(new LLViewCheckHUDAttachments(), "View.CheckHUDAttachments"); // World menu addMenu(new LLWorldChat(), "World.Chat"); diff --git a/linden/indra/newview/skins/default/xui/en-us/menu_viewer.xml b/linden/indra/newview/skins/default/xui/en-us/menu_viewer.xml index a741b94..eb32ee0 100644 --- a/linden/indra/newview/skins/default/xui/en-us/menu_viewer.xml +++ b/linden/indra/newview/skins/default/xui/en-us/menu_viewer.xml @@ -281,6 +281,10 @@ + + + + @@ -440,6 +444,12 @@ + + + + -- cgit v1.1