Bug 996753 - Workaround for Fx33 not having AppConstants.Versions. r=rnewman, a=bustage
authorNick Alexander <nalexander@mozilla.com>
Thu, 18 Sep 2014 13:31:23 -0400
changeset 217915 7cd3ae0255ec19799c950a17c76cb6f7c246f672
parent 217914 9f2dc7a2df34875f6f60a76eafd363d3c0719030
child 217916 6d79bfddb02c041c796b77f4e01b57eacc42c87e
child 217918 73fcc8d4510cd42126ca3a6f1c0599b6d15ec947
child 217920 a34329afda87f190d469a8c4e543c87f12277c11
push id515
push userraliiev@mozilla.com
push dateMon, 06 Oct 2014 12:51:51 +0000
treeherdermozilla-release@267c7a481bef [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrnewman, bustage
bugs996753
milestone33.0
Bug 996753 - Workaround for Fx33 not having AppConstants.Versions. r=rnewman, a=bustage
mobile/android/base/preferences/GeckoPreferences.java
--- a/mobile/android/base/preferences/GeckoPreferences.java
+++ b/mobile/android/base/preferences/GeckoPreferences.java
@@ -482,17 +482,18 @@ OnSharedPreferenceChangeListener
             "Sanitize:Finished");
         if (mPrefsRequestId > 0) {
             PrefsHelper.removeObserver(mPrefsRequestId);
         }
 
         // The intent extras will be null if this is the top-level settings
         // activity. In that case, we want to end the SETTINGS telmetry session.
         // For HC+ versions of Android this is handled in GeckoPreferenceFragment.
-        if (Versions.preHC && getIntent().getExtras() == null) {
+        final boolean versionsPreHC = Build.VERSION.SDK_INT < Build.VERSION_CODES.HONEYCOMB;
+        if (versionsPreHC && getIntent().getExtras() == null) {
             Telemetry.stopUISession(TelemetryContract.Session.SETTINGS);
         }
     }
 
     @Override
     public void onPause() {
         // Symmetric with onResume.
         if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) {