diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llcommon/llsys.h | 5 | ||||
-rw-r--r-- | indra/newview/llappviewer.cpp | 23 | ||||
-rw-r--r-- | indra/newview/llappviewer.h | 4 | ||||
-rw-r--r-- | indra/newview/llfeaturemanager.cpp | 4 | ||||
-rw-r--r-- | indra/newview/llpanellogin.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llstartup.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llviewerstats.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llweb.cpp | 2 |
8 files changed, 22 insertions, 22 deletions
diff --git a/indra/llcommon/llsys.h b/indra/llcommon/llsys.h index 962367f69f..294d0066ca 100644 --- a/indra/llcommon/llsys.h +++ b/indra/llcommon/llsys.h @@ -37,13 +37,14 @@ // #include "llsd.h" +#include "llsingleton.h" #include <iosfwd> #include <string> -class LL_COMMON_API LLOSInfo +class LL_COMMON_API LLOSInfo : public LLSingleton<LLOSInfo> { + LLSINGLETON(LLOSInfo); public: - LLOSInfo(); void stream(std::ostream& s) const; const std::string& getOSString() const; diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 958876fb0a..51d7ad1138 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -733,7 +733,7 @@ LLAppViewer::LLAppViewer() // LLLoginInstance::instance().setUpdaterService(mUpdater.get()); - LLLoginInstance::instance().setPlatformInfo(gPlatform, getOSInfo().getOSVersionString()); + LLLoginInstance::instance().setPlatformInfo(gPlatform, LLOSInfo::instance().getOSVersionString()); } LLAppViewer::~LLAppViewer() @@ -3110,7 +3110,7 @@ void LLAppViewer::initUpdater() mUpdater->initialize(channel, version, gPlatform, - getOSInfo().getOSVersionString(), + LLOSInfo::instance().getOSVersionString(), unique_id, willing_to_test ); @@ -3192,10 +3192,13 @@ bool LLAppViewer::initWindow() #ifdef LL_DARWIN - //Satisfy both MAINT-3135 (OSX 10.6 and earlier) MAINT-3288 (OSX 10.7 and later) - if (getOSInfo().mMajorVer == 10 && getOSInfo().mMinorVer < 7) - if ( getOSInfo().mMinorVer == 6 && getOSInfo().mBuild < 8 ) - gViewerWindow->getWindow()->setOldResize(true); + //Satisfy both MAINT-3135 (OSX 10.6 and earlier) MAINT-3288 (OSX 10.7 and later) + LLOSInfo& os_info = LLOSInfo::instance(); + if (os_info.mMajorVer == 10 && os_info.mMinorVer < 7) + { + if ( os_info.mMinorVer == 6 && os_info.mBuild < 8 ) + gViewerWindow->getWindow()->setOldResize(true); + } #endif if (gSavedSettings.getBOOL("WindowMaximized")) @@ -3337,7 +3340,7 @@ LLSD LLAppViewer::getViewerInfo() const info["CPU"] = gSysCPU.getCPUString(); info["MEMORY_MB"] = LLSD::Integer(gSysMemory.getPhysicalMemoryKB().valueInUnits<LLUnits::Megabytes>()); // Moved hack adjustment to Windows memory size into llsys.cpp - info["OS_VERSION"] = LLAppViewer::instance()->getOSInfo().getOSString(); + info["OS_VERSION"] = LLOSInfo::instance().getOSString(); info["GRAPHICS_CARD_VENDOR"] = (const char*)(glGetString(GL_VENDOR)); info["GRAPHICS_CARD"] = (const char*)(glGetString(GL_RENDERER)); @@ -3659,7 +3662,7 @@ void LLAppViewer::writeSystemInfo() gDebugInfo["RAMInfo"]["Physical"] = (LLSD::Integer)(gSysMemory.getPhysicalMemoryKB().value()); gDebugInfo["RAMInfo"]["Allocated"] = (LLSD::Integer)(gMemoryAllocated.valueInUnits<LLUnits::Kilobytes>()); - gDebugInfo["OSInfo"] = getOSInfo().getOSStringSimple(); + gDebugInfo["OSInfo"] = LLOSInfo::instance().getOSStringSimple(); // The user is not logged on yet, but record the current grid choice login url // which may have been the intended grid. @@ -3701,8 +3704,8 @@ void LLAppViewer::writeSystemInfo() // query some system information LL_INFOS("SystemInfo") << "CPU info:\n" << gSysCPU << LL_ENDL; LL_INFOS("SystemInfo") << "Memory info:\n" << gSysMemory << LL_ENDL; - LL_INFOS("SystemInfo") << "OS: " << getOSInfo().getOSStringSimple() << LL_ENDL; - LL_INFOS("SystemInfo") << "OS info: " << getOSInfo() << LL_ENDL; + LL_INFOS("SystemInfo") << "OS: " << LLOSInfo::instance().getOSStringSimple() << LL_ENDL; + LL_INFOS("SystemInfo") << "OS info: " << LLOSInfo::instance() << LL_ENDL; gDebugInfo["SettingsFilename"] = gSavedSettings.getString("ClientSettingsFile"); gDebugInfo["ViewerExePath"] = gDirUtilp->getExecutablePathAndName(); diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h index c36d8cd9fd..520ff68a02 100644 --- a/indra/newview/llappviewer.h +++ b/indra/newview/llappviewer.h @@ -98,8 +98,6 @@ public: void writeDebugInfo(bool isStatic=true); - const LLOSInfo& getOSInfo() const { return mSysOSInfo; } - void setServerReleaseNotesURL(const std::string& url) { mServerReleaseNotesURL = url; } LLSD getViewerInfo() const; std::string getViewerInfoString() const; @@ -270,8 +268,6 @@ private: std::string mLogoutMarkerFileName; LLAPRFile mLogoutMarkerFile; // A file created to indicate the app is running. - - LLOSInfo mSysOSInfo; bool mReportedCrash; std::string mServerReleaseNotesURL; diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp index d4ba230feb..ae4ce298a0 100644 --- a/indra/newview/llfeaturemanager.cpp +++ b/indra/newview/llfeaturemanager.cpp @@ -486,7 +486,7 @@ void LLFeatureManager::fetchFeatureTableCoro(std::string tableName) #if LL_WINDOWS - std::string os_string = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); + std::string os_string = LLOSInfo::instance().getOSStringSimple(); std::string filename; if (os_string.find("Microsoft Windows XP") == 0) @@ -767,7 +767,7 @@ void LLFeatureManager::applyBaseMasks() } #if LL_DARWIN - const LLOSInfo& osInfo = LLAppViewer::instance()->getOSInfo(); + const LLOSInfo& osInfo = LLOSInfo::instance(); if (osInfo.mMajorVer == 10 && osInfo.mMinorVer < 7) { maskFeatures("OSX_10_6_8"); diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp index f8a5bbb036..a88c10521c 100644 --- a/indra/newview/llpanellogin.cpp +++ b/indra/newview/llpanellogin.cpp @@ -791,7 +791,7 @@ void LLPanelLogin::loadLoginPage() params["grid"] = LLGridManager::getInstance()->getGridId(); // add OS info - params["os"] = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); + params["os"] = LLOSInfo::instance().getOSStringSimple(); // sourceid params["sourceid"] = gSavedSettings.getString("sourceid"); diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index fcde03244a..8295ce029b 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -345,7 +345,7 @@ bool idle_startup() const std::string delims (" "); std::string system; int begIdx, endIdx; - std::string osString = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); + std::string osString = LLOSInfo::instance().getOSStringSimple(); begIdx = osString.find_first_not_of (delims); endIdx = osString.find_first_of (delims, begIdx); diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index dd44697dcd..7f88d5e30f 100644 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -489,7 +489,7 @@ void send_stats() LLSD &system = body["system"]; system["ram"] = (S32) gSysMemory.getPhysicalMemoryKB().value(); - system["os"] = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); + system["os"] = LLOSInfo::instance().getOSStringSimple(); system["cpu"] = gSysCPU.getCPUString(); unsigned char MACAddress[MAC_ADDRESS_BYTES]; LLUUID::getNodeID(MACAddress); diff --git a/indra/newview/llweb.cpp b/indra/newview/llweb.cpp index ec82765b96..b816225b07 100644 --- a/indra/newview/llweb.cpp +++ b/indra/newview/llweb.cpp @@ -192,7 +192,7 @@ std::string LLWeb::expandURLSubstitutions(const std::string &url, substitution["CHANNEL"] = LLVersionInfo::getChannel(); substitution["GRID"] = LLGridManager::getInstance()->getGridId(); substitution["GRID_LOWERCASE"] = utf8str_tolower(LLGridManager::getInstance()->getGridId()); - substitution["OS"] = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); + substitution["OS"] = LLOSInfo::instance().getOSStringSimple(); substitution["SESSION_ID"] = gAgent.getSessionID(); substitution["FIRST_LOGIN"] = gAgent.isFirstLogin(); |