diff options
author | Richard Linden <none@none> | 2010-11-15 15:52:54 -0800 |
---|---|---|
committer | Richard Linden <none@none> | 2010-11-15 15:52:54 -0800 |
commit | 50d21a75a7c6a41a5a3355a8c4406a33454c70dd (patch) | |
tree | e2fe3e855d710700cd956b505a3f0548038c9dac /indra/newview/llstartup.cpp | |
parent | e8e1d7e629b9a4a65cde766ed81334140a749428 (diff) | |
parent | 4bdac3f152862b257b9babe9b5a43329c9f544f9 (diff) |
merge
Diffstat (limited to 'indra/newview/llstartup.cpp')
-rw-r--r-- | indra/newview/llstartup.cpp | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 5ee4599200..242d948a46 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -232,6 +232,8 @@ static LLHost gFirstSim; static std::string gFirstSimSeedCap; static LLVector3 gAgentStartLookAt(1.0f, 0.f, 0.f); static std::string gAgentStartLocation = "safe"; +static bool mLoginStatePastUI = false; + boost::scoped_ptr<LLEventPump> LLStartUp::sStateWatcher(new LLEventStream("StartupState")); boost::scoped_ptr<LLStartupListener> LLStartUp::sListener(new LLStartupListener()); @@ -705,7 +707,15 @@ bool idle_startup() if (STATE_LOGIN_SHOW == LLStartUp::getStartupState()) { LL_DEBUGS("AppInit") << "Initializing Window" << LL_ENDL; - + + // if we've gone backwards in the login state machine, to this state where we show the UI + // AND the debug setting to exit in this case is true, then go ahead and bail quickly + if ( mLoginStatePastUI && gSavedSettings.getBOOL("QuitOnLoginActivated") ) + { + // no requirement for notification here - just exit + LLAppViewer::instance()->earlyExitNoNotify(); + } + gViewerWindow->getWindow()->setCursor(UI_CURSOR_ARROW); timeout_count = 0; @@ -783,6 +793,11 @@ bool idle_startup() if (STATE_LOGIN_WAIT == LLStartUp::getStartupState()) { + // when we get to this state, we've already been past the login UI + // (possiblely automatically) - flag this so we can test in the + // STATE_LOGIN_SHOW state if we've gone backwards + mLoginStatePastUI = true; + // Don't do anything. Wait for the login view to call the login_callback, // which will push us to the next state. @@ -809,6 +824,11 @@ bool idle_startup() gKeyboard->resetKeys(); } + // when we get to this state, we've already been past the login UI + // (possiblely automatically) - flag this so we can test in the + // STATE_LOGIN_SHOW state if we've gone backwards + mLoginStatePastUI = true; + // save the credentials std::string userid = "unknown"; if(gUserCredential.notNull()) |