From de2f8212f0c8a42d02e636ecd0744d3ddfd0dce9 Mon Sep 17 00:00:00 2001 From: Lynx Linden Date: Mon, 7 Dec 2009 20:05:52 +0000 Subject: 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(); --- indra/newview/tests/llviewerhelputil_test.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview/tests/llviewerhelputil_test.cpp') diff --git a/indra/newview/tests/llviewerhelputil_test.cpp b/indra/newview/tests/llviewerhelputil_test.cpp index 988d28c301..87304cfcff 100644 --- a/indra/newview/tests/llviewerhelputil_test.cpp +++ b/indra/newview/tests/llviewerhelputil_test.cpp @@ -36,6 +36,7 @@ #include "../test/lltut.h" #include "../llviewerhelputil.h" +#include "../llviewerbuild.h" #include "llcontrol.h" #include "llsys.h" @@ -75,6 +76,12 @@ std::string LLControlGroup::getString(const std::string& name) return test_stringvec[name]; } +const std::string &llGetViewerVersion() +{ + static std::string version = "2.0.0.200099"; + return version; +} + //---------------------------------------------------------------------------- namespace tut -- cgit v1.2.3 From 24cba353a45f6c261169fcda03cb9ac860ef8d9f Mon Sep 17 00:00:00 2001 From: Lynx Linden Date: Mon, 7 Dec 2009 20:30:29 +0000 Subject: DEV-43439: Rename llviewerbuild.{cpp|h} -> llviewerversion.{cpp|h} This module now contains general viewer version routines, not just access to the viewer build number, so I've renamed it from llviewerbuild to llviewerversion. --- indra/newview/tests/llviewerhelputil_test.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/tests/llviewerhelputil_test.cpp') diff --git a/indra/newview/tests/llviewerhelputil_test.cpp b/indra/newview/tests/llviewerhelputil_test.cpp index 87304cfcff..90e3e7a7e0 100644 --- a/indra/newview/tests/llviewerhelputil_test.cpp +++ b/indra/newview/tests/llviewerhelputil_test.cpp @@ -36,7 +36,7 @@ #include "../test/lltut.h" #include "../llviewerhelputil.h" -#include "../llviewerbuild.h" +#include "../llviewerversion.h" #include "llcontrol.h" #include "llsys.h" -- cgit v1.2.3