Bug 1017191 - Follow-up: Use message.id in home banner telemetry instead of randomized id. r=margaret

This commit is contained in:
Chenxia Liu 2014-05-28 16:01:02 -07:00
parent f8f7a8873b
commit 7fc924eff7

View File

@ -204,13 +204,13 @@ function updateBanner(messages) {
onclick: function() {
let parentId = gChromeWin.BrowserApp.selectedTab.id;
gChromeWin.BrowserApp.addTab(message.url, { parentId: parentId });
UITelemetry.addEvent("action.1", "banner", null, id);
UITelemetry.addEvent("action.1", "banner", null, message.id);
},
ondismiss: function() {
// Remove this snippet from the banner, and store its id so we'll never show it again.
Home.banner.remove(id);
removeSnippet(message.id);
UITelemetry.addEvent("cancel.1", "banner", null, id);
UITelemetry.addEvent("cancel.1", "banner", null, message.id);
},
onshown: function() {
// 10% of the time, record the snippet id and a timestamp
@ -360,14 +360,14 @@ function loadSyncPromoBanner() {
Home.banner.remove(id);
Accounts.launchSetup();
UITelemetry.addEvent("action.1", "banner", null, id);
UITelemetry.addEvent("action.1", "banner", null, "syncpromo");
},
ondismiss: function() {
// Remove the sync promo message from the banner and never try to show it again.
Home.banner.remove(id);
Services.prefs.setBoolPref("browser.snippets.syncPromo.enabled", false);
UITelemetry.addEvent("cancel.1", "banner", null, id);
UITelemetry.addEvent("cancel.1", "banner", null, "syncpromo");
}
});
},