diff options
| author | Lynx Linden <lynx@lindenlab.com> | 2009-12-07 20:05:52 +0000 |
|---|---|---|
| committer | Lynx Linden <lynx@lindenlab.com> | 2009-12-07 20:05:52 +0000 |
| commit | de2f8212f0c8a42d02e636ecd0744d3ddfd0dce9 (patch) | |
| tree | af6922e5ee3d022317924d35f60c6f4ea436d75a /indra/newview/llviewerhome.cpp | |
| parent | 37c7e4059cab2a7152e730ca5d68530f14f8f51e (diff) | |
DEV-43439: Added calls to query the viewer version.
Rather than copy/paste the same version string formatting pattern
again, I added new string-based version routines:
/// return the full viewer version as a string like "2.0.0.200030"
const std::string &llGetViewerVersion();
/// return the viewer version as a string like "2.0.0"
const std::string &llGetViewerShortVersion();
/// return the viewer build version as a string, e.g., "200130"
const std::string &llGetViewerBuildVersion();
Diffstat (limited to 'indra/newview/llviewerhome.cpp')
| -rw-r--r-- | indra/newview/llviewerhome.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/indra/newview/llviewerhome.cpp b/indra/newview/llviewerhome.cpp index 64fe4f4fca..57e828525d 100644 --- a/indra/newview/llviewerhome.cpp +++ b/indra/newview/llviewerhome.cpp @@ -38,7 +38,7 @@ #include "llui.h" #include "lluri.h" #include "llsd.h" -#include "llversionviewer.h" +#include "llviewerbuild.h" #include "llviewercontrol.h" //static @@ -47,16 +47,8 @@ std::string LLViewerHome::getHomeURL() // Return the URL to display in the Home side tray. We read // this value from settings.xml and support various substitutions - // *TODO: We should put this version pattern in a central place; this and near - // equivalents are replicated in other code - what's a good location? - std::ostringstream version; - version << LL_VERSION_MAJOR << "." - << LL_VERSION_MINOR << "." - << LL_VERSION_PATCH << "." - << LL_VERSION_BUILD; - LLSD substitution; - substitution["VERSION"] = version.str(); + substitution["VERSION"] = llGetViewerVersion(); substitution["CHANNEL"] = LLURI::escape(gSavedSettings.getString("VersionChannelName")); substitution["LANGUAGE"] = LLUI::getLanguage(); substitution["AUTH_KEY"] = LLURI::escape(getAuthKey()); |
