diff options
author | Tess Chu <tess@lindenlab.com> | 2007-11-15 19:22:19 +0000 |
---|---|---|
committer | Tess Chu <tess@lindenlab.com> | 2007-11-15 19:22:19 +0000 |
commit | 291d99bc66c4c2b8009ba723a43e2e97d24313f9 (patch) | |
tree | 60991ea5744899ac7ac096a4130e43238768db20 /indra/newview/llfloaterpreference.cpp | |
parent | 138bf17c3c51cbf3826a05887d73c49908025f95 (diff) |
svn merge -r73220:73877 svn+ssh://svn/svn/linden/branches/viewer-auth-6
Diffstat (limited to 'indra/newview/llfloaterpreference.cpp')
-rw-r--r-- | indra/newview/llfloaterpreference.cpp | 46 |
1 files changed, 39 insertions, 7 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index 100ae0cfae..25a88e6e7c 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -47,13 +47,16 @@ #include "llspinctrl.h" #include "message.h" +#include "llcommandhandler.h" #include "llfloaterabout.h" +#include "llfloaterpreference.h" #include "llpanelnetwork.h" #include "llpanelaudioprefs.h" #include "llpaneldisplay.h" #include "llpaneldebug.h" #include "llpanelgeneral.h" #include "llpanelinput.h" +#include "llpanellogin.h" #include "llpanelLCD.h" #include "llpanelmsgs.h" #include "llpanelweb.h" @@ -71,6 +74,13 @@ #include "llkeyboard.h" #include "llscrollcontainer.h" +#if LL_WINDOWS +// for Logitech LCD keyboards / speakers +#ifndef LL_LOGITECH_LCD_H +#include "lllogitechlcd.h" +#endif +extern llLCD *gLcdScreen; +#endif const S32 PREF_BORDER = 4; const S32 PREF_PAD = 5; @@ -81,13 +91,20 @@ const S32 PREF_FLOATER_MIN_HEIGHT = 2 * SCROLLBAR_SIZE + 2 * LLPANEL_BORDER_WIDT LLFloaterPreference* LLFloaterPreference::sInstance = NULL; -#if LL_WINDOWS -// for Logitech LCD keyboards / speakers -#ifndef LL_LOGITECH_LCD_H -#include "lllogitechlcd.h" -#endif -extern llLCD *gLcdScreen; -#endif + +class LLPreferencesHandler : public LLCommandHandler +{ +public: + LLPreferencesHandler() : LLCommandHandler("preferences") { } + bool handle(const LLSD& tokens, const LLSD& queryMap) + { + LLFloaterPreference::show(NULL); + return true; + } +}; + +LLPreferencesHandler gPreferencesHandler; + // Must be done at run time, not compile time. JC S32 pref_min_width() @@ -410,6 +427,8 @@ void LLFloaterPreference::show(void*) gMessageSystem->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID()); gAgent.sendReliableMessage(); } + + LLPanelLogin::setAlwaysRefresh(true); } @@ -423,6 +442,9 @@ void LLFloaterPreference::onClickAbout(void*) // static void LLFloaterPreference::onBtnOK( void* userdata ) { + //refresh splash page if we're displaying it + LLPanelLogin::loadLoginPage(); + LLFloaterPreference *fp =(LLFloaterPreference *)userdata; // commit any outstanding text entry if (fp->hasFocus()) @@ -466,6 +488,16 @@ void LLFloaterPreference::onBtnApply( void* userdata ) } } fp->apply(); + + //refresh splash page if we're displaying it + LLPanelLogin::loadLoginPage(); +} + + +void LLFloaterPreference::onClose(bool app_quitting) +{ + LLPanelLogin::setAlwaysRefresh(false); + LLFloater::onClose(app_quitting); } |