diff options
Diffstat (limited to 'indra/newview/llstartup.cpp')
-rw-r--r-- | indra/newview/llstartup.cpp | 219 |
1 files changed, 106 insertions, 113 deletions
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index c5a22d08f3..b993ba16d5 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -40,10 +40,6 @@ #include "llviewermedia_streamingaudio.h" #include "llaudioengine.h" -#ifdef LL_FMODSTUDIO -# include "llaudioengine_fmodstudio.h" -#endif - #ifdef LL_OPENAL #include "llaudioengine_openal.h" #endif @@ -334,10 +330,18 @@ void update_texture_fetch() void set_flags_and_update_appearance() { - LLAppearanceMgr::instance().setAttachmentInvLinkEnable(true); - LLAppearanceMgr::instance().updateAppearanceFromCOF(true, true, no_op); + // this may be called from a coroutine but has many side effects + // in non-thread-safe classes, post to main loop + auto work = []() + { + LLAppearanceMgr::instance().setAttachmentInvLinkEnable(true); + LLAppearanceMgr::instance().updateAppearanceFromCOF(true, true, no_op); + + LLInventoryModelBackgroundFetch::instance().start(); + }; + + LLAppViewer::instance()->postToMainCoro(work); - LLInventoryModelBackgroundFetch::instance().start(); } // Returns false to skip other idle processing. Should only return @@ -382,7 +386,7 @@ bool idle_startup() const std::string delims (" "); std::string system; - int begIdx, endIdx; + size_t begIdx, endIdx; std::string osString = LLOSInfo::instance().getOSStringSimple(); begIdx = osString.find_first_not_of (delims); @@ -541,7 +545,7 @@ bool idle_startup() LLVersionInfo::instance().getMajor(), LLVersionInfo::instance().getMinor(), LLVersionInfo::instance().getPatch(), - FALSE, + false, std::string(), responder, failure_is_fatal, @@ -612,7 +616,7 @@ bool idle_startup() F32 xfer_throttle_bps = gSavedSettings.getF32("XferThrottle"); if (xfer_throttle_bps > 1.f) { - gXferManager->setUseAckThrottling(TRUE); + gXferManager->setUseAckThrottling(true); gXferManager->setAckThrottleBPS(xfer_throttle_bps); } gAssetStorage = new LLViewerAssetStorage(msg, gXferManager); @@ -626,13 +630,13 @@ bool idle_startup() if (inBandwidth != 0.f) { LL_DEBUGS("AppInit") << "Setting packetring incoming bandwidth to " << inBandwidth << LL_ENDL; - msg->mPacketRing.setUseInThrottle(TRUE); + msg->mPacketRing.setUseInThrottle(true); msg->mPacketRing.setInBandwidth(inBandwidth); } if (outBandwidth != 0.f) { LL_DEBUGS("AppInit") << "Setting packetring outgoing bandwidth to " << outBandwidth << LL_ENDL; - msg->mPacketRing.setUseOutThrottle(TRUE); + msg->mPacketRing.setUseOutThrottle(true); msg->mPacketRing.setOutBandwidth(outBandwidth); } } @@ -644,20 +648,11 @@ bool idle_startup() // or audio cues in connection UI. //------------------------------------------------- - if (FALSE == gSavedSettings.getBOOL("NoAudio")) + if (false == gSavedSettings.getBOOL("NoAudio")) { delete gAudiop; gAudiop = NULL; -#ifdef LL_FMODSTUDIO -#if !LL_WINDOWS - if (NULL == getenv("LL_BAD_FMODSTUDIO_DRIVER")) -#endif // !LL_WINDOWS - { - gAudiop = (LLAudioEngine *) new LLAudioEngine_FMODSTUDIO(gSavedSettings.getBOOL("FMODExProfilerEnable")); - } -#endif - #ifdef LL_OPENAL #if !LL_WINDOWS if (NULL == getenv("LL_BAD_OPENAL_DRIVER")) @@ -678,21 +673,10 @@ bool idle_startup() #endif if (gAudiop->init(window_handle, LLAppViewer::instance()->getSecondLifeTitle())) { - if (FALSE == gSavedSettings.getBOOL("UseMediaPluginsForStreamingAudio")) - { - LL_INFOS("AppInit") << "Using default impl to render streaming audio" << LL_ENDL; - gAudiop->setStreamingAudioImpl(gAudiop->createDefaultStreamingAudioImpl()); - } - - // if the audio engine hasn't set up its own preferred handler for streaming audio - // then set up the generic streaming audio implementation which uses media plugins - if (NULL == gAudiop->getStreamingAudioImpl()) - { - LL_INFOS("AppInit") << "Using media plugins to render streaming audio" << LL_ENDL; - gAudiop->setStreamingAudioImpl(new LLStreamingAudio_MediaPlugins()); - } + LL_INFOS("AppInit") << "Using media plugins to render streaming audio" << LL_ENDL; + gAudiop->setStreamingAudioImpl(new LLStreamingAudio_MediaPlugins()); - gAudiop->setMuted(TRUE); + gAudiop->setMuted(true); } else { @@ -720,15 +704,15 @@ bool idle_startup() // Previous initializeLoginInfo may have generated user credentials. Re-check them. if (gUserCredential.isNull()) { - show_connect_box = TRUE; + show_connect_box = true; } else if (gSavedSettings.getBOOL("AutoLogin")) { // Log into last account gRememberPassword = true; gRememberUser = true; - gSavedSettings.setBOOL("RememberPassword", TRUE); - gSavedSettings.setBOOL("RememberUser", TRUE); + gSavedSettings.setBOOL("RememberPassword", true); + gSavedSettings.setBOOL("RememberUser", true); show_connect_box = false; } else if (gSavedSettings.getLLSD("UserLoginInfo").size() == 3) @@ -742,7 +726,7 @@ bool idle_startup() { gRememberPassword = gSavedSettings.getBOOL("RememberPassword"); gRememberUser = gSavedSettings.getBOOL("RememberUser"); - show_connect_box = TRUE; + show_connect_box = true; } //setup map of datetime strings to codes and slt & local time offset from utc @@ -751,7 +735,7 @@ bool idle_startup() // Go to the next startup state LLStartUp::setStartupState( STATE_BROWSER_INIT ); - return FALSE; + return false; } @@ -763,7 +747,7 @@ bool idle_startup() display_startup(); // LLViewerMedia::initBrowser(); LLStartUp::setStartupState( STATE_LOGIN_SHOW ); - return FALSE; + return false; } @@ -805,7 +789,7 @@ bool idle_startup() gUserCredential = gLoginHandler.initializeLoginInfo(); } // Make sure the process dialog doesn't hide things - gViewerWindow->setShowProgress(FALSE); + gViewerWindow->setShowProgress(false); // Show the login dialog login_show(); // connect dialog is already shown, so fill in the names @@ -835,9 +819,9 @@ bool idle_startup() LLStartUp::setStartupState( STATE_LOGIN_CLEANUP ); } - gViewerWindow->setNormalControlsVisible( FALSE ); - gLoginMenuBarView->setVisible( TRUE ); - gLoginMenuBarView->setEnabled( TRUE ); + gViewerWindow->setNormalControlsVisible( false ); + gLoginMenuBarView->setVisible( true ); + gLoginMenuBarView->setEnabled( true ); show_debug_menus(); // Hide the splash screen @@ -858,7 +842,7 @@ bool idle_startup() #endif display_startup(); timeout.reset(); - return FALSE; + return false; } if (STATE_LOGIN_WAIT == LLStartUp::getStartupState()) @@ -874,7 +858,7 @@ bool idle_startup() // display() function will be the one to run display_startup() // Sleep so we don't spin the CPU ms_sleep(1); - return FALSE; + return false; } if (STATE_LOGIN_CLEANUP == LLStartUp::getStartupState()) @@ -890,7 +874,7 @@ bool idle_startup() // could then change the preferences to fix the issue. LLStartUp::setStartupState(STATE_LOGIN_SHOW); - return FALSE; + return false; } // reset the values that could have come in from a slurl @@ -973,7 +957,7 @@ bool idle_startup() // and startup time is close enough if we don't have a real value. if (gSavedPerAccountSettings.getU32("LastLogoff") == 0) { - gSavedPerAccountSettings.setU32("LastLogoff", time_corrected()); + gSavedPerAccountSettings.setU32("LastLogoff", (U32)time_corrected()); } //Default the path if one isn't set. @@ -1035,14 +1019,14 @@ bool idle_startup() // Display the startup progress bar. gViewerWindow->initTextures(agent_location_id); - gViewerWindow->setShowProgress(TRUE); - gViewerWindow->setProgressCancelButtonVisible(TRUE, LLTrans::getString("Quit")); + gViewerWindow->setShowProgress(true); + gViewerWindow->setProgressCancelButtonVisible(true, LLTrans::getString("Quit")); gViewerWindow->revealIntroPanel(); LLStartUp::setStartupState( STATE_LOGIN_AUTH_INIT ); - return FALSE; + return false; } if(STATE_LOGIN_AUTH_INIT == LLStartUp::getStartupState()) @@ -1068,7 +1052,7 @@ bool idle_startup() login->connect(gUserCredential); LLStartUp::setStartupState( STATE_LOGIN_CURL_UNSTUCK ); - return FALSE; + return false; } if(STATE_LOGIN_CURL_UNSTUCK == LLStartUp::getStartupState()) @@ -1079,7 +1063,7 @@ bool idle_startup() set_startup_status(progress, auth_desc, auth_message); LLStartUp::setStartupState( STATE_LOGIN_PROCESS_RESPONSE ); - return FALSE; + return false; } if(STATE_LOGIN_PROCESS_RESPONSE == LLStartUp::getStartupState()) @@ -1197,7 +1181,7 @@ bool idle_startup() general_cert_done); reset_login(); - gSavedSettings.setBOOL("AutoLogin", FALSE); + gSavedSettings.setBOOL("AutoLogin", false); show_connect_box = true; } if(certificate) @@ -1224,7 +1208,7 @@ bool idle_startup() general_cert_done); reset_login(); - gSavedSettings.setBOOL("AutoLogin", FALSE); + gSavedSettings.setBOOL("AutoLogin", false); show_connect_box = true; } @@ -1268,10 +1252,10 @@ bool idle_startup() LLNotificationsUtil::add("ErrorMessage", args, LLSD(), login_alert_done); transition_back_to_login_panel(emsg.str()); show_connect_box = true; - return FALSE; + return false; } } - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1293,7 +1277,7 @@ bool idle_startup() // Since we connected, save off the settings so the user doesn't have to // type the name/password again if we crash. - gSavedSettings.saveToFile(gSavedSettings.getString("ClientSettingsFile"), TRUE); + gSavedSettings.saveToFile(gSavedSettings.getString("ClientSettingsFile"), true); LLUIColorTable::instance().saveUserSettings(); display_startup(); @@ -1374,7 +1358,7 @@ bool idle_startup() LLStartUp::setStartupState( STATE_MULTIMEDIA_INIT ); - return FALSE; + return false; } @@ -1387,7 +1371,7 @@ bool idle_startup() LLStartUp::multimediaInit(); LLStartUp::setStartupState( STATE_FONT_INIT ); display_startup(); - return FALSE; + return false; } // Loading fonts takes several seconds @@ -1396,7 +1380,7 @@ bool idle_startup() LLStartUp::fontInit(); LLStartUp::setStartupState( STATE_SEED_GRANTED_WAIT ); display_startup(); - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1450,7 +1434,7 @@ bool idle_startup() } } display_startup(); - return FALSE; + return false; } @@ -1475,10 +1459,10 @@ bool idle_startup() if ( gViewerWindow != NULL) { // This isn't the first logon attempt, so show the UI - gViewerWindow->setNormalControlsVisible( TRUE ); + gViewerWindow->setNormalControlsVisible( true ); } - gLoginMenuBarView->setVisible( FALSE ); - gLoginMenuBarView->setEnabled( FALSE ); + gLoginMenuBarView->setVisible( false ); + gLoginMenuBarView->setEnabled( false ); display_startup(); // direct logging to the debug console's line buffer @@ -1503,7 +1487,7 @@ bool idle_startup() display_startup(); #ifndef LL_RELEASE_FOR_DOWNLOAD - gMessageSystem->setTimeDecodes( TRUE ); // Time the decode of each msg + gMessageSystem->setTimeDecodes( true ); // Time the decode of each msg gMessageSystem->setTimeDecodesSpamThreshold( 0.05f ); // Spam if a single msg takes over 50ms to decode #endif display_startup(); @@ -1524,7 +1508,11 @@ bool idle_startup() // create a container's instance for start a controlling conversation windows // by the voice's events - LLFloaterIMContainer::getInstance(); + LLFloaterIMContainer *im_inst = LLFloaterIMContainer::getInstance(); + if(gAgent.isFirstLogin()) + { + im_inst->openFloater(im_inst->getKey()); + } if (gSavedSettings.getS32("ParcelMediaAutoPlayEnable") == 2) { LLViewerParcelAskPlay::getInstance()->loadSettings(); @@ -1620,7 +1608,7 @@ bool idle_startup() gUseCircuitCallbackCalled = false; - msg->enableCircuit(gFirstSim, TRUE); + msg->enableCircuit(gFirstSim, true); // now, use the circuit info to tell simulator about us! LL_INFOS("AppInit") << "viewer: UserLoginLocationReply() Enabling " << gFirstSim << " with code " << msg->mOurCircuitCode << LL_ENDL; msg->newMessageFast(_PREHASH_UseCircuitCode); @@ -1631,7 +1619,7 @@ bool idle_startup() msg->sendReliable( gFirstSim, gSavedSettings.getS32("UseCircuitCodeMaxRetries"), - FALSE, + false, (F32Seconds)gSavedSettings.getF32("UseCircuitCodeTimeout"), use_circuit_callback, NULL); @@ -1639,7 +1627,7 @@ bool idle_startup() timeout.reset(); display_startup(); - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1654,7 +1642,7 @@ bool idle_startup() LLStartUp::setStartupState( STATE_AGENT_SEND ); } pump_idle_startup_network(); - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1684,7 +1672,7 @@ bool idle_startup() // But not on first login, because you can't see your avatar then if (!gAgent.isFirstLogin()) { - LLHUDEffectSpiral *effectp = (LLHUDEffectSpiral *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_POINT, TRUE); + LLHUDEffectSpiral *effectp = (LLHUDEffectSpiral *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_POINT, true); effectp->setPositionGlobal(gAgent.getPositionGlobal()); effectp->setColor(LLColor4U(gAgent.getEffectColor())); LLHUDManager::getInstance()->sendEffects(); @@ -1694,7 +1682,7 @@ bool idle_startup() timeout.reset(); display_startup(); - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1745,7 +1733,7 @@ bool idle_startup() } reset_login(); } - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1799,7 +1787,7 @@ bool idle_startup() display_startup(); LLStartUp::setStartupState(STATE_INVENTORY_SKEL); display_startup(); - return FALSE; + return false; } if (STATE_INVENTORY_SKEL == LLStartUp::getStartupState()) @@ -1831,7 +1819,7 @@ bool idle_startup() display_startup(); LLStartUp::setStartupState(STATE_INVENTORY_SEND2); display_startup(); - return FALSE; + return false; } if (STATE_INVENTORY_SEND2 == LLStartUp::getStartupState()) @@ -1911,7 +1899,7 @@ bool idle_startup() // visible. JC if (show_hud || gSavedSettings.getBOOL("ShowTutorial")) { - LLFloaterReg::showInstance("hud", LLSD(), FALSE); + LLFloaterReg::showInstance("hud", LLSD(), false); } display_startup(); @@ -1948,7 +1936,7 @@ bool idle_startup() LLStartUp::setStartupState(STATE_INVENTORY_CALLBACKS ); display_startup(); - return FALSE; + return false; } //--------------------------------------------------------------------- @@ -1959,7 +1947,7 @@ bool idle_startup() if (!LLInventoryModel::isSysFoldersReady()) { display_startup(); - return FALSE; + return false; } LLInventoryModelBackgroundFetch::instance().start(); @@ -2007,7 +1995,7 @@ bool idle_startup() LLStartUp::setStartupState( STATE_MISC ); display_startup(); - return FALSE; + return false; } @@ -2047,12 +2035,12 @@ bool idle_startup() if (gSavedSettings.getBOOL("ShowHelpOnFirstLogin")) { - gSavedSettings.setBOOL("HelpFloaterOpen", TRUE); + 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); + gSavedSettings.setBOOL("ShowStartLocation", true); } display_startup(); @@ -2074,7 +2062,7 @@ bool idle_startup() display_startup(); // We're successfully logged in. - gSavedSettings.setBOOL("FirstLoginThisInstall", FALSE); + gSavedSettings.setBOOL("FirstLoginThisInstall", false); LLFloaterReg::showInitialVisibleInstances(); @@ -2108,8 +2096,8 @@ bool idle_startup() if (item_id.notNull() && asset_id.notNull()) { // Could schedule and delay these for later. - const BOOL no_inform_server = FALSE; - const BOOL no_deactivate_similar = FALSE; + const bool no_inform_server = false; + const bool no_deactivate_similar = false; LLGestureMgr::instance().activateGestureWithAsset(item_id, asset_id, no_inform_server, no_deactivate_similar); @@ -2122,7 +2110,7 @@ bool idle_startup() LLGestureMgr::instance().setFetchIDs(item_ids); LLGestureMgr::instance().startFetch(); } - gDisplaySwapBuffers = TRUE; + gDisplaySwapBuffers = true; display_startup(); LLMessageSystem* msg = gMessageSystem; @@ -2165,13 +2153,13 @@ bool idle_startup() && gSavedSettings.getBOOL("RestoreCameraPosOnLogin")) { // restore old camera pos - gAgentCamera.setFocusOnAvatar(FALSE, FALSE); + gAgentCamera.setFocusOnAvatar(false, false); gAgentCamera.setCameraPosAndFocusGlobal(gSavedSettings.getVector3d("CameraPosOnLogout"), gSavedSettings.getVector3d("FocusPosOnLogout"), LLUUID::null); - BOOL limit_hit = FALSE; + bool limit_hit = false; gAgentCamera.calcCameraPositionTargetGlobal(&limit_hit); if (limit_hit) { - gAgentCamera.setFocusOnAvatar(TRUE, FALSE); + gAgentCamera.setFocusOnAvatar(true, false); } gAgentCamera.stopCameraAnimation(); } @@ -2208,7 +2196,7 @@ bool idle_startup() LLStartUp::setStartupState( STATE_PRECACHE ); timeout.reset(); - return FALSE; + return false; } if (STATE_PRECACHE == LLStartUp::getStartupState()) @@ -2234,7 +2222,7 @@ bool idle_startup() if (isAgentAvatarValid() && !gAgent.isFirstLogin() && !gAgent.isOutfitChosen()) { gAgentWearables.notifyLoadingStarted(); - gAgent.setOutfitChosen(TRUE); + gAgent.setOutfitChosen(true); gAgentWearables.sendDummyAgentWearablesUpdate(); callAfterCOFFetch(set_flags_and_update_appearance); } @@ -2267,7 +2255,7 @@ bool idle_startup() display_startup(); } - return TRUE; + return true; } if (STATE_WEARABLES_WAIT == LLStartUp::getStartupState()) @@ -2313,7 +2301,7 @@ bool idle_startup() { LL_DEBUGS("Avatar") << "avatar fully loaded" << LL_ENDL; LLStartUp::setStartupState( STATE_CLEANUP ); - return TRUE; + return true; } } else @@ -2324,7 +2312,7 @@ bool idle_startup() // We have our clothing, proceed. LL_DEBUGS("Avatar") << "wearables loaded" << LL_ENDL; LLStartUp::setStartupState( STATE_CLEANUP ); - return TRUE; + return true; } } //fall through this frame to STATE_CLEANUP @@ -2353,7 +2341,7 @@ bool idle_startup() LL_DEBUGS("AppInit") << "Done releasing bitmap" << LL_ENDL; //gViewerWindow->revealIntroPanel(); gViewerWindow->setStartupComplete(); - gViewerWindow->setProgressCancelButtonVisible(FALSE); + gViewerWindow->setProgressCancelButtonVisible(false); display_startup(); // We're not away from keyboard, even though login might have taken @@ -2421,10 +2409,10 @@ bool idle_startup() LLPerfStats::StatsRecorder::setAutotuneInit(); - return TRUE; + return true; } - return TRUE; + return true; } // @@ -2438,7 +2426,7 @@ void login_show() // Hide the toolbars: may happen to come back here if login fails after login agent but before login in region if (gToolBarView) { - gToolBarView->setVisible(FALSE); + gToolBarView->setVisible(false); } LLPanelLogin::show( gViewerWindow->getWindowRectScaled(), login_callback, NULL ); @@ -2460,7 +2448,7 @@ void login_callback(S32 option, void *userdata) if (!gSavedSettings.getBOOL("RememberPassword")) { // turn off the setting and write out to disk - gSavedSettings.saveToFile( gSavedSettings.getString("ClientSettingsFile") , TRUE ); + gSavedSettings.saveToFile( gSavedSettings.getString("ClientSettingsFile") , true ); LLUIColorTable::instance().saveUserSettings(); } @@ -2941,7 +2929,7 @@ void LLStartUp::loadInitialOutfit( const std::string& outfit_folder_name, LL_DEBUGS() << "initial outfit category id: " << cat_id << LL_ENDL; } - gAgent.setOutfitChosen(TRUE); + gAgent.setOutfitChosen(true); gAgentWearables.sendDummyAgentWearablesUpdate(); } @@ -2990,7 +2978,7 @@ std::string LLStartUp::startupStateToString(EStartupState state) RTNENUM( STATE_AGENT_SEND ); RTNENUM( STATE_AGENT_WAIT ); RTNENUM( STATE_INVENTORY_SEND ); - RTNENUM( STATE_INVENTORY_CALLBACKS ); + RTNENUM(STATE_INVENTORY_CALLBACKS ); RTNENUM( STATE_INVENTORY_SKEL ); RTNENUM( STATE_INVENTORY_SEND2 ); RTNENUM( STATE_MISC ); @@ -3039,13 +3027,18 @@ void reset_login() if ( gViewerWindow ) { // Hide menus and normal buttons - gViewerWindow->setNormalControlsVisible( FALSE ); - gLoginMenuBarView->setVisible( TRUE ); - gLoginMenuBarView->setEnabled( TRUE ); + gViewerWindow->setNormalControlsVisible( false ); + gLoginMenuBarView->setVisible( true ); + gLoginMenuBarView->setEnabled( true ); } // Hide any other stuff LLFloaterReg::hideVisibleInstances(); + + if (LLStartUp::getStartupState() > STATE_WORLD_INIT) + { + gViewerWindow->resetStatusBarContainer(); + } LLStartUp::setStartupState( STATE_BROWSER_INIT ); if (LLVoiceClient::instanceExists()) @@ -3426,7 +3419,7 @@ void trust_cert_done(const LLSD& notification, const LLSD& response) } case OPT_CANCEL_TRUST: reset_login(); - gSavedSettings.setBOOL("AutoLogin", FALSE); + gSavedSettings.setBOOL("AutoLogin", false); LLStartUp::setStartupState( STATE_LOGIN_SHOW ); default: LLPanelLogin::giveFocus(); @@ -3645,7 +3638,7 @@ bool process_login_success_response() gFirstSim.set(sim_ip_str, sim_port); if (gFirstSim.isOk()) { - gMessageSystem->enableCircuit(gFirstSim, TRUE); + gMessageSystem->enableCircuit(gFirstSim, true); } } std::string region_x_str = response["region_x"]; @@ -3661,7 +3654,7 @@ bool process_login_success_response() if (!look_at_str.empty()) { size_t len = look_at_str.size(); - LLMemoryStream mstr((U8*)look_at_str.c_str(), len); + LLMemoryStream mstr((U8*)look_at_str.c_str(), static_cast<S32>(len)); LLSD sd = LLSDSerialize::fromNotation(mstr, len); gAgentStartLookAt = ll_vector3_from_sd(sd); } @@ -3676,7 +3669,7 @@ bool process_login_success_response() if(server_utc_time) { time_t now = time(NULL); - gUTCOffset = (server_utc_time - now); + gUTCOffset = (S32)(server_utc_time - now); // Print server timestamp LLSD substitution; @@ -3699,7 +3692,7 @@ bool process_login_success_response() if(!home_location.empty()) { size_t len = home_location.size(); - LLMemoryStream mstr((U8*)home_location.c_str(), len); + LLMemoryStream mstr((U8*)home_location.c_str(), static_cast<S32>(len)); LLSD sd = LLSDSerialize::fromNotation(mstr, len); S32 region_x = sd["region_handle"][0].asInteger(); S32 region_y = sd["region_handle"][1].asInteger(); @@ -3744,7 +3737,7 @@ bool process_login_success_response() // outfit is chosen on COF contents, initial outfit // requested and available, etc. - //gAgent.setGenderChosen(TRUE); + //gAgent.setGenderChosen(true); } bool pacific_daylight_time = false; @@ -3890,6 +3883,6 @@ void transition_back_to_login_panel(const std::string& emsg) { // Bounce back to the login screen. reset_login(); // calls LLStartUp::setStartupState( STATE_LOGIN_SHOW ); - gSavedSettings.setBOOL("AutoLogin", FALSE); + gSavedSettings.setBOOL("AutoLogin", false); } |