From caff254c9155b55412556c9270bec4b114d83270 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Wed, 6 Jul 2011 18:43:52 -0700 Subject: EXP-847 FIX As a user, I would like to see the How To floater appear the first time I log in to basic mode --- indra/newview/app_settings/settings.xml | 25 +++++++++++++++++++++- indra/newview/app_settings/settings_minimal.xml | 13 ++++++++++- indra/newview/llfloaterhelpbrowser.h | 1 + indra/newview/llstartup.cpp | 12 +++++++++++ indra/newview/llviewerhelp.cpp | 3 ++- .../skins/default/xui/en/floater_help_browser.xml | 2 ++ .../skins/minimal/xui/en/floater_help_browser.xml | 10 ++++----- 7 files changed, 58 insertions(+), 8 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 255bb48f65..0ae4545911 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -13419,6 +13419,29 @@ 650 490 0 - + + + HelpFloaterOpen + + Comment + Show Help Floater on login? + Persist + 1 + Type + Boolean + Value + 1 + + ShowHelpOnFirstLogin + + Comment + Show Help Floater on first login + Persist + 1 + Type + Boolean + Value + 0 + diff --git a/indra/newview/app_settings/settings_minimal.xml b/indra/newview/app_settings/settings_minimal.xml index 70a75cb4ca..29e52ab054 100644 --- a/indra/newview/app_settings/settings_minimal.xml +++ b/indra/newview/app_settings/settings_minimal.xml @@ -459,5 +459,16 @@ Value 0 - + ShowHelpOnFirstLogin + + Comment + Show Help Floater on first login + Persist + 1 + Type + Boolean + Value + 1 + + diff --git a/indra/newview/llfloaterhelpbrowser.h b/indra/newview/llfloaterhelpbrowser.h index 2731c81b9c..afe0f4df69 100644 --- a/indra/newview/llfloaterhelpbrowser.h +++ b/indra/newview/llfloaterhelpbrowser.h @@ -42,6 +42,7 @@ class LLFloaterHelpBrowser : /*virtual*/ BOOL postBuild(); /*virtual*/ void onClose(bool app_quitting); + /*virtual*/ void onOpen(const LLSD& key); // inherited from LLViewerMediaObserver /*virtual*/ void handleMediaEvent(LLPluginClassMedia* self, EMediaEvent event); diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 167dd68f08..ba1f7cd2e3 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -76,6 +76,7 @@ #include "lluserrelations.h" #include "llversioninfo.h" #include "llviewercontrol.h" +#include "llviewerhelp.h" #include "llvfs.h" #include "llxorcipher.h" // saved password, MAC address #include "llwindow.h" @@ -1692,11 +1693,22 @@ bool idle_startup() gViewerThrottle.setMaxBandwidth(FAST_RATE_BPS / 1024.f); } + if (gSavedSettings.getBOOL("ShowHelpOnFirstLogin")) + { + gSavedSettings.setBOOL("HelpFloaterOpen", TRUE); + } + // Set the show start location to true, now that the user has logged // on with this install. gSavedSettings.setBOOL("ShowStartLocation", TRUE); } + if (gSavedSettings.getBOOL("HelpFloaterOpen")) + { + // show default topic + LLViewerHelp::instance().showTopic(""); + } + // We're successfully logged in. gSavedSettings.setBOOL("FirstLoginThisInstall", FALSE); diff --git a/indra/newview/llviewerhelp.cpp b/indra/newview/llviewerhelp.cpp index 9fe8c142b9..69522b7ab3 100644 --- a/indra/newview/llviewerhelp.cpp +++ b/indra/newview/llviewerhelp.cpp @@ -101,8 +101,9 @@ void LLViewerHelp::showTopic(const std::string &topic) // work out the URL for this topic and display it showHelp(); + std::string helpURL = LLViewerHelpUtil::buildHelpURL( help_topic ); - setRawURL( helpURL ); + setRawURL(helpURL); } std::string LLViewerHelp::defaultTopic() diff --git a/indra/newview/skins/default/xui/en/floater_help_browser.xml b/indra/newview/skins/default/xui/en/floater_help_browser.xml index 02e50ee584..de6d586f72 100644 --- a/indra/newview/skins/default/xui/en/floater_help_browser.xml +++ b/indra/newview/skins/default/xui/en/floater_help_browser.xml @@ -2,6 +2,8 @@