Bug 1347552 - Add telemetry for the Layout Panel. r=pbro
MozReview-Commit-ID: At5Pp2WA4Ow
--- a/devtools/client/shared/telemetry.js
+++ b/devtools/client/shared/telemetry.js
@@ -92,16 +92,20 @@ Telemetry.prototype = {
ruleview: {
histogram: "DEVTOOLS_RULEVIEW_OPENED_COUNT",
timerHistogram: "DEVTOOLS_RULEVIEW_TIME_ACTIVE_SECONDS"
},
computedview: {
histogram: "DEVTOOLS_COMPUTEDVIEW_OPENED_COUNT",
timerHistogram: "DEVTOOLS_COMPUTEDVIEW_TIME_ACTIVE_SECONDS"
},
+ layoutview: {
+ histogram: "DEVTOOLS_LAYOUTVIEW_OPENED_COUNT",
+ timerHistogram: "DEVTOOLS_LAYOUTVIEW_TIME_ACTIVE_SECONDS"
+ },
fontinspector: {
histogram: "DEVTOOLS_FONTINSPECTOR_OPENED_COUNT",
timerHistogram: "DEVTOOLS_FONTINSPECTOR_TIME_ACTIVE_SECONDS"
},
animationinspector: {
histogram: "DEVTOOLS_ANIMATIONINSPECTOR_OPENED_COUNT",
timerHistogram: "DEVTOOLS_ANIMATIONINSPECTOR_TIME_ACTIVE_SECONDS"
},
--- a/devtools/client/shared/test/browser_telemetry_sidebar.js
+++ b/devtools/client/shared/test/browser_telemetry_sidebar.js
@@ -24,17 +24,17 @@ add_task(function* () {
yield gDevTools.closeToolbox(target);
gBrowser.removeCurrentTab();
});
function* testSidebar(toolbox) {
info("Testing sidebar");
let inspector = toolbox.getCurrentPanel();
- let sidebarTools = ["ruleview", "computedview", "fontinspector",
+ let sidebarTools = ["ruleview", "computedview", "layoutview", "fontinspector",
"animationinspector"];
// Concatenate the array with itself so that we can open each tool twice.
sidebarTools.push.apply(sidebarTools, sidebarTools);
return new Promise(resolve => {
// See TOOL_DELAY for why we need setTimeout here
setTimeout(function selectSidebarTab() {
--- a/toolkit/components/telemetry/Histograms.json
+++ b/toolkit/components/telemetry/Histograms.json
@@ -7740,16 +7740,24 @@
"DEVTOOLS_COMPUTEDVIEW_OPENED_COUNT": {
"alert_emails": ["dev-developer-tools@lists.mozilla.org"],
"expires_in_version": "never",
"kind": "count",
"bug_numbers": [1247985],
"description": "Number of times the DevTools Computed View has been opened.",
"releaseChannelCollection": "opt-out"
},
+ "DEVTOOLS_LAYOUTVIEW_OPENED_COUNT": {
+ "alert_emails": ["dev-developer-tools@lists.mozilla.org"],
+ "expires_in_version": "never",
+ "kind": "count",
+ "bug_numbers": [1347552],
+ "description": "Number of times the DevTools Layout View has been opened.",
+ "releaseChannelCollection": "opt-out"
+ },
"DEVTOOLS_FONTINSPECTOR_OPENED_COUNT": {
"alert_emails": ["dev-developer-tools@lists.mozilla.org"],
"expires_in_version": "never",
"kind": "count",
"bug_numbers": [1247985],
"description": "Number of times the DevTools Font Inspector has been opened.",
"releaseChannelCollection": "opt-out"
},
@@ -8035,16 +8043,23 @@
},
"DEVTOOLS_COMPUTEDVIEW_TIME_ACTIVE_SECONDS": {
"expires_in_version": "never",
"kind": "exponential",
"high": 10000000,
"n_buckets": 100,
"description": "How long has the computed view been active (seconds)"
},
+ "DEVTOOLS_LAYOUTVIEW_TIME_ACTIVE_SECONDS": {
+ "expires_in_version": "never",
+ "kind": "exponential",
+ "high": 10000000,
+ "n_buckets": 100,
+ "description": "How long has the layout view been active (seconds)"
+ },
"DEVTOOLS_FONTINSPECTOR_TIME_ACTIVE_SECONDS": {
"expires_in_version": "never",
"kind": "exponential",
"high": 10000000,
"n_buckets": 100,
"description": "How long has the font inspector been active (seconds)"
},
"DEVTOOLS_ANIMATIONINSPECTOR_TIME_ACTIVE_SECONDS": {