Commit 5e617acf authored by stuartmorgan's avatar stuartmorgan Committed by Commit bot

Use a different plist key for iOS versioning

App Store rules appear to be moving toward enforcing the format of
CFBundleVerison on iOS, so this allows setting a custom plist key to
store the full Chrome version instead.

BUG=411302

Review URL: https://codereview.chromium.org/542223002

Cr-Commit-Position: refs/heads/master@{#293802}
parent 2cbe08da
...@@ -62,10 +62,13 @@ base::string16 FileVersionInfoMac::legal_copyright() { ...@@ -62,10 +62,13 @@ base::string16 FileVersionInfoMac::legal_copyright() {
base::string16 FileVersionInfoMac::product_version() { base::string16 FileVersionInfoMac::product_version() {
// On OS X, CFBundleVersion is used by LaunchServices, and must follow // On OS X, CFBundleVersion is used by LaunchServices, and must follow
// specific formatting rules, so the four-part Chrome version is in // specific formatting rules, so the four-part Chrome version is in
// CFBundleShortVersionString. On iOS, however, CFBundleVersion can be the // CFBundleShortVersionString. On iOS, both have a policy-enfoced limit
// full version, but CFBundleShortVersionString has a policy-enfoced limit // of three version components, so the full version is stored in a custom
// of three version components. // key (CrBundleVersion) falling back to CFBundleVersion if not present.
#if defined(OS_IOS) #if defined(OS_IOS)
base::string16 version(GetString16Value(CFSTR("CrBundleVersion")));
if (version.length() > 0)
return version;
return GetString16Value(CFSTR("CFBundleVersion")); return GetString16Value(CFSTR("CFBundleVersion"));
#else #else
return GetString16Value(CFSTR("CFBundleShortVersionString")); return GetString16Value(CFSTR("CFBundleShortVersionString"));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment