Bug 1344901 - Fix a regression introduced in bug 1337551. r=jfkthame a=gchang
authorZibi Braniecki <gandalf@mozilla.com>
Mon, 06 Mar 2017 13:54:30 -0800
changeset 395044 31cd77685e1c7646b19456fbd3e18ce521208bca
parent 395043 18b3bedeb4be8078449cb008f7d83c85120feb1f
child 395045 10641bd5df46a0b788172727c27bf7d61a194249
push id1468
push userasasaki@mozilla.com
push dateMon, 05 Jun 2017 19:31:07 +0000
treeherdermozilla-release@0641fc6ee9d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjfkthame, gchang
bugs1344901, 1337551
milestone54.0a2
Bug 1344901 - Fix a regression introduced in bug 1337551. r=jfkthame a=gchang MozReview-Commit-ID: 8SP0ucROJRF
browser/modules/DirectoryLinksProvider.jsm
toolkit/components/telemetry/TelemetryEnvironment.jsm
toolkit/modules/Locale.jsm
toolkit/mozapps/extensions/AddonManager.jsm
--- a/browser/modules/DirectoryLinksProvider.jsm
+++ b/browser/modules/DirectoryLinksProvider.jsm
@@ -190,17 +190,17 @@ var DirectoryLinksProvider = {
   get locale() {
     let matchOS;
     try {
       matchOS = Services.prefs.getBoolPref(PREF_MATCH_OS_LOCALE);
     } catch (e) {}
 
     if (matchOS) {
       return Cc["@mozilla.org/intl/ospreferences;1"].
-             getService(Ci.mozIOSPreferences).getSystemLocale();
+             getService(Ci.mozIOSPreferences).systemLocale;
     }
 
     try {
       let locale = Services.prefs.getComplexValue(PREF_SELECTED_LOCALE,
                                                   Ci.nsIPrefLocalizedString);
       if (locale) {
         return locale.data;
       }
--- a/toolkit/components/telemetry/TelemetryEnvironment.jsm
+++ b/toolkit/components/telemetry/TelemetryEnvironment.jsm
@@ -239,17 +239,17 @@ function getBrowserLocale() {
 /**
  * Get the current OS locale.
  * @return a string with the OS locale or null on failure.
  */
 function getSystemLocale() {
   try {
     return Cc["@mozilla.org/intl/ospreferences;1"].
              getService(Ci.mozIOSPreferences).
-             getSystemLocale();
+             systemLocale;
   } catch (e) {
     return null;
   }
 }
 
 /**
  * Safely get a sysinfo property and return its value. If the property is not
  * available, return aDefault.
--- a/toolkit/modules/Locale.jsm
+++ b/toolkit/modules/Locale.jsm
@@ -16,17 +16,17 @@ this.Locale = {
   /**
    * Gets the currently selected locale for display.
    * @return  the selected locale or "en-US" if none is selected
    */
   getLocale() {
     if (Preferences.get(PREF_MATCH_OS_LOCALE, false)) {
       const osPrefs =
         Cc["@mozilla.org/intl/ospreferences;1"].getService(Ci.mozIOSPreferences);
-      return osPrefs.getSystemLocale();
+      return osPrefs.systemLocale;
     }
     try {
       let locale = Preferences.get(PREF_SELECTED_LOCALE, null, Ci.nsIPrefLocalizedString);
       if (locale)
         return locale;
     } catch (e) {}
     return Preferences.get(PREF_SELECTED_LOCALE, "en-US");
   },
--- a/toolkit/mozapps/extensions/AddonManager.jsm
+++ b/toolkit/mozapps/extensions/AddonManager.jsm
@@ -327,17 +327,17 @@ function promiseCallProvider(aProvider, 
  * Gets the currently selected locale for display.
  * @return  the selected locale or "en-US" if none is selected
  */
 function getLocale() {
   try {
     if (Services.prefs.getBoolPref(PREF_MATCH_OS_LOCALE)) {
       const osPrefs =
         Cc["@mozilla.org/intl/ospreferences;1"].getService(Ci.mozIOSPreferences);
-      return osPrefs.getSystemLocale();
+      return osPrefs.systemLocale;
     }
   } catch (e) { }
 
   try {
     let locale = Services.prefs.getComplexValue(PREF_SELECTED_LOCALE,
                                                 Ci.nsIPrefLocalizedString);
     if (locale)
       return locale;