From e1dbbd0213dd96e28aec2c5e6d9fd821ab144e48 Mon Sep 17 00:00:00 2001 From: Cho Date: Fri, 26 Apr 2013 21:26:38 +0100 Subject: removed internal browser hack for getting auth code in favor of SLApp-only approach --- indra/newview/llappviewer.cpp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 53c694eaca..31f7f61396 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -2577,19 +2577,20 @@ bool LLAppViewer::initConfiguration() // What can happen is that someone can use IE (or potentially // other browsers) and do the rough equivalent of command // injection and steal passwords. Phoenix. SL-55321 + LLSLURL option_slurl; if(clp.hasOption("url")) { - LLStartUp::setStartSLURL(LLSLURL(clp.getOption("url")[0])); + option_slurl = LLSLURL(clp.getOption("url")[0]); + LLStartUp::setStartSLURL(option_slurl); if(LLStartUp::getStartSLURL().getType() == LLSLURL::LOCATION) { LLGridManager::getInstance()->setGridChoice(LLStartUp::getStartSLURL().getGrid()); - - } + } } else if(clp.hasOption("slurl")) { - LLSLURL start_slurl(clp.getOption("slurl")[0]); - LLStartUp::setStartSLURL(start_slurl); + option_slurl = LLSLURL(clp.getOption("slurl")[0]); + LLStartUp::setStartSLURL(option_slurl); } const LLControlVariable* skinfolder = gSavedSettings.getControl("SkinCurrent"); @@ -2686,10 +2687,10 @@ bool LLAppViewer::initConfiguration() // it relies on checking a marker file which will not work when running // out of different directories - if (LLStartUp::getStartSLURL().isValid() && + if (option_slurl.isValid() && (gSavedSettings.getBOOL("SLURLPassToOtherInstance"))) { - if (sendURLToOtherInstance(LLStartUp::getStartSLURL().getSLURLString())) + if (sendURLToOtherInstance(option_slurl.getSLURLString())) { // successfully handed off URL to existing instance, exit return false; -- cgit v1.2.3 From f36171b8cae93bdaf6d3df2bf964313d1da087b6 Mon Sep 17 00:00:00 2001 From: Cho Date: Fri, 26 Apr 2013 23:35:28 +0100 Subject: made sendURLToOtherInstance() happen before viewer window actually appears, in the event of an external browser launching a SLApp --- indra/newview/llappviewer.cpp | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 31f7f61396..e97c264af3 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -2577,7 +2577,9 @@ bool LLAppViewer::initConfiguration() // What can happen is that someone can use IE (or potentially // other browsers) and do the rough equivalent of command // injection and steal passwords. Phoenix. SL-55321 + LLSLURL option_slurl; + if(clp.hasOption("url")) { option_slurl = LLSLURL(clp.getOption("url")[0]); @@ -2592,6 +2594,21 @@ bool LLAppViewer::initConfiguration() option_slurl = LLSLURL(clp.getOption("slurl")[0]); LLStartUp::setStartSLURL(option_slurl); } + + //RN: if we received a URL, hand it off to the existing instance. + // don't call anotherInstanceRunning() when doing URL handoff, as + // it relies on checking a marker file which will not work when running + // out of different directories + + if (option_slurl.isValid() && + (gSavedSettings.getBOOL("SLURLPassToOtherInstance"))) + { + if (sendURLToOtherInstance(option_slurl.getSLURLString())) + { + // successfully handed off URL to existing instance, exit + return false; + } + } const LLControlVariable* skinfolder = gSavedSettings.getControl("SkinCurrent"); if(skinfolder && LLStringUtil::null != skinfolder->getValue().asString()) @@ -2682,21 +2699,6 @@ bool LLAppViewer::initConfiguration() #endif LLStringUtil::truncate(gWindowTitle, 255); - //RN: if we received a URL, hand it off to the existing instance. - // don't call anotherInstanceRunning() when doing URL handoff, as - // it relies on checking a marker file which will not work when running - // out of different directories - - if (option_slurl.isValid() && - (gSavedSettings.getBOOL("SLURLPassToOtherInstance"))) - { - if (sendURLToOtherInstance(option_slurl.getSLURLString())) - { - // successfully handed off URL to existing instance, exit - return false; - } - } - if (!gSavedSettings.getBOOL("AllowMultipleViewers")) { // -- cgit v1.2.3 From ee0b66f080de53f70599c824d5ff231d6a9c739f Mon Sep 17 00:00:00 2001 From: "Jeff (Gioffredo Linden)" Date: Thu, 25 Jul 2013 16:07:16 -0400 Subject: VITA test framework - record events support --- indra/newview/llappviewer.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index f92274dbbd..209e91d713 100755 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -222,6 +222,10 @@ #include "llmachineid.h" #include "llmainlooprepeater.h" + +#include "llviewereventrecorder.h" + + // *FIX: These extern globals should be cleaned up. // The globals either represent state/config/resource-storage of either // this app, or another 'component' of the viewer. App globals should be @@ -696,6 +700,7 @@ LLAppViewer::LLAppViewer() : LLAppViewer::~LLAppViewer() { delete mSettingsLocationList; + LLViewerEventRecorder::instance().~LLViewerEventRecorder(); LLLoginInstance::instance().setUpdaterService(0); @@ -2545,6 +2550,10 @@ bool LLAppViewer::initConfiguration() } } + if (clp.hasOption("logevents")) { + LLViewerEventRecorder::instance().setEventLoggingOn(); + } + if(clp.hasOption("channel")) { LLVersionInfo::resetChannel(clp.getOption("channel")[0]); -- cgit v1.2.3 From 64c1fb0b82fb8ec401c82d6d66b18a1ce30ad9af Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Tue, 30 Jul 2013 11:46:08 -0400 Subject: get rid of warning generated by trying to save obsolete VersionChannelName setting --- indra/newview/llappviewer.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index f92274dbbd..72a3aa47e2 100755 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -2361,8 +2361,6 @@ bool LLAppViewer::initConfiguration() gSavedSettings.setString("ClientSettingsFile", gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, getSettingsFilename("Default", "Global"))); - gSavedSettings.setString("VersionChannelName", LLVersionInfo::getChannel()); - #ifndef LL_RELEASE_FOR_DOWNLOAD // provide developer build only overrides for these control variables that are not // persisted to settings.xml -- cgit v1.2.3 From 3364614f8b3c61a369760b4effc2ed9382be75f9 Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Thu, 29 Aug 2013 09:27:12 -0400 Subject: add "Settings" logging tag to make debugging settings loading easier --- indra/newview/llappviewer.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 338558c937..8a7c24c5b5 100755 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -2227,13 +2227,13 @@ bool LLAppViewer::loadSettingsFromDirectory(const std::string& location_key, BOOST_FOREACH(const SettingsFile& file, group.files) { - llinfos << "Attempting to load settings for the group " << file.name() - << " - from location " << location_key << llendl; + LL_INFOS("Settings") << "Attempting to load settings for the group " << file.name() + << " - from location " << location_key << LL_ENDL; LLControlGroup* settings_group = LLControlGroup::getInstance(file.name); if(!settings_group) { - llwarns << "No matching settings group for name " << file.name() << llendl; + LL_WARNS("Settings") << "No matching settings group for name " << file.name() << LL_ENDL; continue; } @@ -2262,7 +2262,7 @@ bool LLAppViewer::loadSettingsFromDirectory(const std::string& location_key, if(settings_group->loadFromFile(full_settings_path, set_defaults, file.persistent)) { // success! - llinfos << "Loaded settings file " << full_settings_path << llendl; + LL_INFOS("Settings") << "Loaded settings file " << full_settings_path << LL_ENDL; } else { // failed to load @@ -2276,7 +2276,7 @@ bool LLAppViewer::loadSettingsFromDirectory(const std::string& location_key, // only complain if we actually have a filename at this point if (!full_settings_path.empty()) { - llinfos << "Cannot load " << full_settings_path << " - No settings found." << llendl; + LL_INFOS("Settings") << "Cannot load " << full_settings_path << " - No settings found." << LL_ENDL; } } } @@ -2435,8 +2435,8 @@ bool LLAppViewer::initConfiguration() gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, clp.getOption("settings")[0]); gSavedSettings.setString("ClientSettingsFile", user_settings_filename); - llinfos << "Using command line specified settings filename: " - << user_settings_filename << llendl; + LL_INFOS("Settings") << "Using command line specified settings filename: " + << user_settings_filename << LL_ENDL; } // - load overrides from user_settings @@ -2452,8 +2452,8 @@ bool LLAppViewer::initConfiguration() { std::string session_settings_filename = clp.getOption("sessionsettings")[0]; gSavedSettings.setString("SessionSettingsFile", session_settings_filename); - llinfos << "Using session settings filename: " - << session_settings_filename << llendl; + LL_INFOS("Settings") << "Using session settings filename: " + << session_settings_filename << LL_ENDL; } loadSettingsFromDirectory("Session"); @@ -2461,8 +2461,8 @@ bool LLAppViewer::initConfiguration() { std::string user_session_settings_filename = clp.getOption("usersessionsettings")[0]; gSavedSettings.setString("UserSessionSettingsFile", user_session_settings_filename); - llinfos << "Using user session settings filename: " - << user_session_settings_filename << llendl; + LL_INFOS("Settings") << "Using user session settings filename: " + << user_session_settings_filename << LL_ENDL; } loadSettingsFromDirectory("UserSession"); -- cgit v1.2.3