Bug 1235061 - Create histogram probe to measure how often users have zoomed view enabled/disabled. r=mfinkle p=vladan a=sylvestre
authorMargaret Leibovic <margaret.leibovic@gmail.com>
Thu, 24 Dec 2015 13:58:21 -0500
changeset 298251 2db713b1c2fb3de36fedf95076c27e9e8c453b84
parent 298250 7e1284abc4733ef0372cd96671cfaac3227e2214
child 298252 32512bb6e431ee8a5a7fa4fd7a22c1fc2a35ca78
push id8891
push usermleibovic@mozilla.com
push dateWed, 06 Jan 2016 15:24:11 +0000
treeherdermozilla-aurora@2db713b1c2fb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmfinkle, sylvestre
bugs1235061
milestone45.0a2
Bug 1235061 - Create histogram probe to measure how often users have zoomed view enabled/disabled. r=mfinkle p=vladan a=sylvestre
mobile/android/chrome/content/browser.js
toolkit/components/telemetry/Histograms.json
--- a/mobile/android/chrome/content/browser.js
+++ b/mobile/android/chrome/content/browser.js
@@ -598,16 +598,22 @@ var BrowserApp = {
         InitLater(() => ShumwayUtils.init(), window, "ShumwayUtils");
         InitLater(() => Telemetry.addData("TRACKING_PROTECTION_ENABLED",
             Services.prefs.getBoolPref("privacy.trackingprotection.enabled")));
         InitLater(() => Telemetry.addData("TRACKING_PROTECTION_PBM_DISABLED",
             !Services.prefs.getBoolPref("privacy.trackingprotection.pbmode.enabled")));
         InitLater(() => WebcompatReporter.init());
       }
 
+      // Collect telemetry data.
+      // We do this at startup because we want to move away from "gather-telemetry" (bug 1127907)
+      InitLater(() => {
+        Telemetry.addData("ZOOMED_VIEW_ENABLED", Services.prefs.getBoolPref("ui.zoomedview.enabled"));
+      });
+
       InitLater(() => LightWeightThemeWebInstaller.init());
       InitLater(() => SpatialNavigation.init(BrowserApp.deck, null), window, "SpatialNavigation");
       InitLater(() => CastingApps.init(), window, "CastingApps");
       InitLater(() => Services.search.init(), Services, "search");
       InitLater(() => DownloadNotifications.init(), window, "DownloadNotifications");
 
       if (AppConstants.MOZ_SAFE_BROWSING) {
         // Bug 778855 - Perf regression if we do this here. To be addressed in bug 779008.
--- a/toolkit/components/telemetry/Histograms.json
+++ b/toolkit/components/telemetry/Histograms.json
@@ -8434,16 +8434,23 @@
   },
   "TAP_TO_LOAD_ENABLED": {
     "expires_in_version": "50",
     "kind": "enumerated",
     "n_values": 3,
     "description": "Whether or not a user has tap-to-load enabled.",
     "bug_numbers": [1208167]
   },
+  "ZOOMED_VIEW_ENABLED": {
+    "expires_in_version": "50",
+    "kind": "boolean",
+    "description": "Whether or not a user has the zoomed view (a.k.a. \"Magnify small areas\") enabled.",
+    "alert_emails": ["mobile-frontend@mozilla.com"],
+    "bug_numbers": [1235061]
+  },
   "TRACKING_PROTECTION_ENABLED": {
     "expires_in_version": "never",
     "kind": "boolean",
     "description": "Whether or not a session has tracking protection enabled"
   },
   "TRACKING_PROTECTION_PBM_DISABLED": {
     "expires_in_version": "60",
     "kind": "boolean",