diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/app_settings/commands.xml | 45 | ||||
-rw-r--r-- | indra/newview/app_settings/settings.xml | 11 | ||||
-rw-r--r-- | indra/newview/llpanelpeople.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llviewerfloaterreg.cpp | 1 | ||||
-rw-r--r-- | indra/newview/llviewerhelp.cpp | 1 | ||||
-rw-r--r-- | indra/newview/llviewermenu.cpp | 20 |
6 files changed, 54 insertions, 26 deletions
diff --git a/indra/newview/app_settings/commands.xml b/indra/newview/app_settings/commands.xml index 3625ce5088..e4aaca1bd0 100644 --- a/indra/newview/app_settings/commands.xml +++ b/indra/newview/app_settings/commands.xml @@ -5,7 +5,7 @@ icon="Command_AboutLand_Icon" label_ref="Command_AboutLand_Label" tooltip_ref="Command_AboutLand_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="about_land" is_running_function="Floater.IsOpen" is_running_parameters="about_land" @@ -15,7 +15,7 @@ icon="Command_Appearance_Icon" label_ref="Command_Appearance_Label" tooltip_ref="Command_Appearance_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="appearance" is_running_function="Floater.IsOpen" is_running_parameters="appearance" @@ -25,7 +25,7 @@ icon="Command_Avatar_Icon" label_ref="Command_Avatar_Label" tooltip_ref="Command_Avatar_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="avatar" is_running_function="Floater.IsOpen" is_running_parameters="avatar" @@ -35,7 +35,7 @@ icon="Command_Build_Icon" label_ref="Command_Build_Label" tooltip_ref="Command_Build_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="build" is_enabled_function="Agent.IsActionAllowed" is_enabled_parameters="build" @@ -47,7 +47,7 @@ icon="Command_Chat_Icon" label_ref="Command_Chat_Label" tooltip_ref="Command_Chat_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="chat_bar" is_running_function="Floater.IsOpen" is_running_parameters="chat_bar" @@ -57,7 +57,7 @@ icon="Command_Compass_Icon" label_ref="Command_Compass_Label" tooltip_ref="Command_Compass_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="compass" is_running_function="Floater.IsOpen" is_running_parameters="compass" @@ -67,7 +67,7 @@ icon="Command_Destinations_Icon" label_ref="Command_Destinations_Label" tooltip_ref="Command_Destinations_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="destinations" is_running_function="Floater.IsOpen" is_running_parameters="destinations" @@ -77,7 +77,7 @@ icon="Command_Gestures_Icon" label_ref="Command_Gestures_Label" tooltip_ref="Command_Gestures_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="gestures" is_running_function="Floater.IsOpen" is_running_parameters="gestures" @@ -87,8 +87,7 @@ icon="Command_HowTo_Icon" label_ref="Command_HowTo_Label" tooltip_ref="Command_HowTo_Tooltip" - execute_function="Floater.ToolbarToggle" - execute_parameters="help_browser" + execute_function="Help.ToggleHowTo" is_running_function="Floater.IsOpen" is_running_parameters="help_browser" /> @@ -97,7 +96,7 @@ icon="Command_Inventory_Icon" label_ref="Command_Inventory_Label" tooltip_ref="Command_Inventory_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="my_inventory" is_running_function="Floater.IsOpen" is_running_parameters="my_inventory" @@ -107,7 +106,7 @@ icon="Command_Map_Icon" label_ref="Command_Map_Label" tooltip_ref="Command_Map_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="world_map" is_running_function="Floater.IsOpen" is_running_parameters="world_map" @@ -117,7 +116,7 @@ icon="Command_Marketplace_Icon" label_ref="Command_Marketplace_Label" tooltip_ref="Command_Marketplace_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="marketplace" is_running_function="Floater.IsOpen" is_running_parameters="marketplace" @@ -127,7 +126,7 @@ icon="Command_MiniMap_Icon" label_ref="Command_MiniMap_Label" tooltip_ref="Command_MiniMap_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="mini_map" is_running_function="Floater.IsOpen" is_running_parameters="mini_map" @@ -137,7 +136,7 @@ icon="Command_Move_Icon" label_ref="Command_Move_Label" tooltip_ref="Command_Move_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="moveview" is_running_function="Floater.IsOpen" is_running_parameters="moveview" @@ -147,7 +146,7 @@ icon="Command_People_Icon" label_ref="Command_People_Label" tooltip_ref="Command_People_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="people" is_running_function="Floater.IsOpen" is_running_parameters="people" @@ -157,7 +156,7 @@ icon="Command_Picks_Icon" label_ref="Command_Picks_Label" tooltip_ref="Command_Picks_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="picks" is_running_function="Floater.IsOpen" is_running_parameters="picks" @@ -167,7 +166,7 @@ icon="Command_Places_Icon" label_ref="Command_Places_Label" tooltip_ref="Command_Places_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="places" is_running_function="Floater.IsOpen" is_running_parameters="places" @@ -177,7 +176,7 @@ icon="Command_Preferences_Icon" label_ref="Command_Preferences_Label" tooltip_ref="Command_Preferences_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="preferences" is_running_function="Floater.IsOpen" is_running_parameters="preferences" @@ -195,7 +194,7 @@ icon="Command_Search_Icon" label_ref="Command_Search_Label" tooltip_ref="Command_Search_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="search" is_running_function="Floater.IsOpen" is_running_parameters="search" @@ -205,7 +204,7 @@ icon="Command_Snapshot_Icon" label_ref="Command_Snapshot_Label" tooltip_ref="Command_Snapshot_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="snapshot" is_running_function="Floater.IsOpen" is_running_parameters="snapshot" @@ -229,7 +228,7 @@ icon="Command_View_Icon" label_ref="Command_View_Label" tooltip_ref="Command_View_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="camera" is_running_function="Floater.IsOpen" is_running_parameters="camera" @@ -239,7 +238,7 @@ icon="Command_Voice_Icon" label_ref="Command_Voice_Label" tooltip_ref="Command_Voice_Tooltip" - execute_function="Floater.ToolbarToggle" + execute_function="Floater.ToggleOrBringToFront" execute_parameters="voice_controls" is_running_function="Floater.IsOpen" is_running_parameters="voice_controls" diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 4b847dfbf7..2dbf9e714b 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -4028,6 +4028,17 @@ <key>Value</key> <string>http://viewer-help.secondlife.com/[LANGUAGE]/[CHANNEL]/[VERSION]/[TOPIC][DEBUG_MODE]</string> </map> + <key>HowToHelpURL</key> + <map> + <key>Comment</key> + <string>URL for How To help content</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>http://common-flash-secondlife-com.s3.amazonaws.com/viewer/v2.6/agni/howto/index.html</string> + </map> <key>HomeSidePanelURL</key> <map> <key>Comment</key> diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp index 80c431f481..d5e289e6e6 100644 --- a/indra/newview/llpanelpeople.cpp +++ b/indra/newview/llpanelpeople.cpp @@ -1451,7 +1451,7 @@ bool LLPanelPeople::notifyChildren(const LLSD& info) container->onOpen(LLSD().with(LLSideTrayPanelContainer::PARAM_SUB_PANEL_NAME, getName())); } else - LLFloaterReg::hideFloaterInstance("people"); + LLFloaterReg::hideInstance("people"); return true; // this notification is only supposed to be handled by task panels } diff --git a/indra/newview/llviewerfloaterreg.cpp b/indra/newview/llviewerfloaterreg.cpp index 3463eec5d8..b5ed8b04bc 100644 --- a/indra/newview/llviewerfloaterreg.cpp +++ b/indra/newview/llviewerfloaterreg.cpp @@ -289,6 +289,7 @@ void LLViewerFloaterReg::registerFloaters() LLFloaterReg::add("snapshot", "floater_snapshot.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterSnapshot>); LLFloaterReg::add("search", "floater_search.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterSearch>); LLFloaterReg::add("profile", "floater_web_content.xml", (LLFloaterBuildFunc)&LLFloaterWebContent::create); + LLFloaterReg::add("how_to", "floater_web_content.xml", (LLFloaterBuildFunc)&LLFloaterWebContent::create); LLFloaterUIPreviewUtil::registerFloater(); diff --git a/indra/newview/llviewerhelp.cpp b/indra/newview/llviewerhelp.cpp index d1120b6269..a8a918f259 100644 --- a/indra/newview/llviewerhelp.cpp +++ b/indra/newview/llviewerhelp.cpp @@ -144,4 +144,3 @@ std::string LLViewerHelp::getTopicFromFocus() return defaultTopic(); } - diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index aee46ed5be..4b90f1952a 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -3113,6 +3113,11 @@ void handle_avatar_eject(const LLSD& avatar_id) } } +bool my_profile_visible() +{ + return LLAvatarActions::profileVisible(gAgent.getID()); +} + bool enable_freeze_eject(const LLSD& avatar_id) { // Use avatar_id if available, otherwise default to right-click avatar @@ -4516,6 +4521,13 @@ bool tools_visible_take_object() return !is_selection_buy_not_take(); } +bool enable_how_to_visible(const LLSD& param) +{ + LLFloaterWebContent::Params p; + p.target = "__help_how_to"; + return LLFloaterReg::instanceVisible(param, p); +} + class LLToolsEnableBuyOrTake : public view_listener_t { bool handleEvent(const LLSD& userdata) @@ -6879,6 +6891,11 @@ class LLToggleHowTo : public view_listener_t { bool handleEvent(const LLSD& userdata) { + LLFloaterWebContent::Params p; + p.url = gSavedSettings.getString("HowToHelpURL"); + p.target = "__help_how_to"; + + LLFloaterReg::toggleInstanceOrBringToFront(userdata, p); return true; } }; @@ -8047,6 +8064,7 @@ void initialize_menus() // Help menu // most items use the ShowFloater method view_listener_t::addMenu(new LLToggleHowTo(), "Help.ToggleHowTo"); + enable.add("Help.HowToVisible", boost::bind(&enable_how_to_visible, _2)); // Advanced menu view_listener_t::addMenu(new LLAdvancedToggleConsole(), "Advanced.ToggleConsole"); @@ -8240,7 +8258,7 @@ void initialize_menus() enable.add("Avatar.EnableCall", boost::bind(&LLAvatarActions::canCall)); view_listener_t::addMenu(new LLAvatarReportAbuse(), "Avatar.ReportAbuse"); view_listener_t::addMenu(new LLAvatarToggleMyProfile(), "Avatar.ToggleMyProfile"); - enable.add("Avatar.IsMyProfileOpen", boost::bind(&LLAvatarActions::profileVisible, gAgent.getID())); + enable.add("Avatar.IsMyProfileOpen", boost::bind(&my_profile_visible)); view_listener_t::addMenu(new LLAvatarEnableAddFriend(), "Avatar.EnableAddFriend"); enable.add("Avatar.EnableFreezeEject", boost::bind(&enable_freeze_eject, _2)); |