Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(745)

Unified Diff: base/file_version_info_mac.mm

Issue 10809059: Use CFBundleVersion for product_version on iOS (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Update year Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/file_version_info_mac.mm
diff --git a/base/file_version_info_mac.mm b/base/file_version_info_mac.mm
index 93191e0c5237fa820577901debd55436acc8e2b7..09ae95b4c2397d3834ea95f40fa9e64f1ffd73e5 100644
--- a/base/file_version_info_mac.mm
+++ b/base/file_version_info_mac.mm
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -60,7 +60,16 @@ string16 FileVersionInfoMac::legal_copyright() {
}
string16 FileVersionInfoMac::product_version() {
+ // On OS X, CFBundleVersion is used by LaunchServices, and must follow
+ // specific formatting rules, so the four-part Chrome version is in
+ // CFBundleShortVersionString. On iOS, however, CFBundleVersion can be the
Mark Mentovai 2012/07/23 20:48:43 Oh, wow.
stuartmorgan 2012/07/24 09:37:55 Yeah, having completely different arbitrary rules
+ // full version, but CFBundleShortVersionString has a policy-enfoced limit
+ // of three version components.
+#if defined(OS_IOS)
+ return GetString16Value(CFSTR("CFBundleVersion"));
+#else
return GetString16Value(CFSTR("CFBundleShortVersionString"));
+#endif // defined(OS_IOS)
}
string16 FileVersionInfoMac::file_description() {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698