Index: chrome/common/chrome_version_info.cc |
diff --git a/chrome/common/chrome_version_info.cc b/chrome/common/chrome_version_info.cc |
index c5a7a4311b97e23e736303ad642b9082a92ad0df..9309958e3737933ca5dcbe42e27f6621705a2877 100644 |
--- a/chrome/common/chrome_version_info.cc |
+++ b/chrome/common/chrome_version_info.cc |
@@ -7,10 +7,11 @@ |
#include "base/basictypes.h" |
#include "base/file_version_info.h" |
#include "base/string_util.h" |
-#include "ui/base/l10n/l10n_util.h" |
#include "base/threading/thread_restrictions.h" |
#include "build/build_config.h" |
#include "grit/chromium_strings.h" |
+#include "grit/generated_resources.h" |
+#include "ui/base/l10n/l10n_util.h" |
namespace chrome { |
@@ -89,6 +90,26 @@ bool VersionInfo::IsOfficialBuild() const { |
#endif |
+std::string VersionInfo::CreateVersionString() const { |
+ std::string current_version = ""; |
Mark Mentovai
2011/07/18 02:20:17
You don’t need the |= ""| here, get rid of it. The
haraken1
2011/07/19 04:36:35
Done.
|
+ if (is_valid()) { |
+ current_version += Version(); |
+#if !defined(GOOGLE_CHROME_BUILD) |
+ current_version += " ("; |
+ current_version += l10n_util::GetStringUTF8(IDS_ABOUT_VERSION_UNOFFICIAL); |
+ current_version += " "; |
+ current_version += OSType(); |
Mark Mentovai
2011/07/18 02:20:17
OK, so this will be
Developer Build Windows 12345
haraken1
2011/07/19 04:36:35
I changed it to
(Developer Build 12345 Windows)
|
+ current_version += " "; |
+ current_version += LastChange(); |
+ current_version += ")"; |
+#endif |
+ std::string modifier = GetVersionStringModifier(); |
+ if (!modifier.empty()) |
+ current_version += " " + modifier; |
+ } |
+ return current_version; |
+} |
+ |
std::string VersionInfo::OSType() const { |
#if defined(OS_WIN) |
return "Windows"; |