mirror of
https://github.com/classilla/tenfourfox.git
synced 2024-06-08 20:29:36 +00:00
#334: remove telemetry from customizeableui
This commit is contained in:
parent
6aee6c06ab
commit
bbe74e8efc
|
@ -10,8 +10,10 @@ this.EXPORTED_SYMBOLS = ["CustomizableWidgets"];
|
||||||
Cu.import("resource:///modules/CustomizableUI.jsm");
|
Cu.import("resource:///modules/CustomizableUI.jsm");
|
||||||
Cu.import("resource://gre/modules/Services.jsm");
|
Cu.import("resource://gre/modules/Services.jsm");
|
||||||
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
|
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
|
||||||
|
/*
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "BrowserUITelemetry",
|
XPCOMUtils.defineLazyModuleGetter(this, "BrowserUITelemetry",
|
||||||
"resource:///modules/BrowserUITelemetry.jsm");
|
"resource:///modules/BrowserUITelemetry.jsm");
|
||||||
|
*/
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "PlacesUtils",
|
XPCOMUtils.defineLazyModuleGetter(this, "PlacesUtils",
|
||||||
"resource://gre/modules/PlacesUtils.jsm");
|
"resource://gre/modules/PlacesUtils.jsm");
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "PlacesUIUtils",
|
XPCOMUtils.defineLazyModuleGetter(this, "PlacesUIUtils",
|
||||||
|
@ -1180,7 +1182,7 @@ if (Services.prefs.getBoolPref("privacy.panicButton.enabled")) {
|
||||||
this._ensureSanitizer();
|
this._ensureSanitizer();
|
||||||
this._sanitizer.range = this._getSanitizeRange(doc);
|
this._sanitizer.range = this._getSanitizeRange(doc);
|
||||||
let group = doc.getElementById("PanelUI-panic-timeSpan");
|
let group = doc.getElementById("PanelUI-panic-timeSpan");
|
||||||
BrowserUITelemetry.countPanicEvent(group.selectedItem.id);
|
//BrowserUITelemetry.countPanicEvent(group.selectedItem.id);
|
||||||
group.selectedItem = doc.getElementById("PanelUI-panic-5min");
|
group.selectedItem = doc.getElementById("PanelUI-panic-5min");
|
||||||
let itemsToClear = [
|
let itemsToClear = [
|
||||||
"cookies", "history", "openWindows", "formdata", "sessions", "cache", "downloads"
|
"cookies", "history", "openWindows", "formdata", "sessions", "cache", "downloads"
|
||||||
|
|
|
@ -31,8 +31,10 @@ Cu.import("resource://gre/modules/AddonManager.jsm");
|
||||||
|
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "DragPositionManager",
|
XPCOMUtils.defineLazyModuleGetter(this, "DragPositionManager",
|
||||||
"resource:///modules/DragPositionManager.jsm");
|
"resource:///modules/DragPositionManager.jsm");
|
||||||
|
/*
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "BrowserUITelemetry",
|
XPCOMUtils.defineLazyModuleGetter(this, "BrowserUITelemetry",
|
||||||
"resource:///modules/BrowserUITelemetry.jsm");
|
"resource:///modules/BrowserUITelemetry.jsm");
|
||||||
|
*/
|
||||||
XPCOMUtils.defineLazyModuleGetter(this, "LightweightThemeManager",
|
XPCOMUtils.defineLazyModuleGetter(this, "LightweightThemeManager",
|
||||||
"resource://gre/modules/LightweightThemeManager.jsm");
|
"resource://gre/modules/LightweightThemeManager.jsm");
|
||||||
|
|
||||||
|
@ -1117,7 +1119,7 @@ CustomizeMode.prototype = {
|
||||||
this.resetting = true;
|
this.resetting = true;
|
||||||
// Disable the reset button temporarily while resetting:
|
// Disable the reset button temporarily while resetting:
|
||||||
let btn = this.document.getElementById("customization-reset-button");
|
let btn = this.document.getElementById("customization-reset-button");
|
||||||
BrowserUITelemetry.countCustomizationEvent("reset");
|
//BrowserUITelemetry.countCustomizationEvent("reset");
|
||||||
btn.disabled = true;
|
btn.disabled = true;
|
||||||
return Task.spawn(function() {
|
return Task.spawn(function() {
|
||||||
this._removePanelCustomizationPlaceholders();
|
this._removePanelCustomizationPlaceholders();
|
||||||
|
@ -1750,7 +1752,7 @@ CustomizeMode.prototype = {
|
||||||
}
|
}
|
||||||
|
|
||||||
CustomizableUI.removeWidgetFromArea(aDraggedItemId);
|
CustomizableUI.removeWidgetFromArea(aDraggedItemId);
|
||||||
BrowserUITelemetry.countCustomizationEvent("remove");
|
//BrowserUITelemetry.countCustomizationEvent("remove");
|
||||||
// Special widgets are removed outright, we can return here:
|
// Special widgets are removed outright, we can return here:
|
||||||
if (CustomizableUI.isSpecialWidget(aDraggedItemId)) {
|
if (CustomizableUI.isSpecialWidget(aDraggedItemId)) {
|
||||||
return;
|
return;
|
||||||
|
@ -1792,7 +1794,7 @@ CustomizeMode.prototype = {
|
||||||
this.wrapToolbarItem(aTargetNode, place);
|
this.wrapToolbarItem(aTargetNode, place);
|
||||||
}
|
}
|
||||||
this.wrapToolbarItem(draggedItem, place);
|
this.wrapToolbarItem(draggedItem, place);
|
||||||
BrowserUITelemetry.countCustomizationEvent("move");
|
//BrowserUITelemetry.countCustomizationEvent("move");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1804,8 +1806,8 @@ CustomizeMode.prototype = {
|
||||||
// within the same area, and adding a widget from one area to another area
|
// within the same area, and adding a widget from one area to another area
|
||||||
// as a "move". An "add" is only when we move an item from the palette into
|
// as a "move". An "add" is only when we move an item from the palette into
|
||||||
// an area.
|
// an area.
|
||||||
let custEventType = aOriginArea.id == kPaletteId ? "add" : "move";
|
//let custEventType = aOriginArea.id == kPaletteId ? "add" : "move";
|
||||||
BrowserUITelemetry.countCustomizationEvent(custEventType);
|
//BrowserUITelemetry.countCustomizationEvent(custEventType);
|
||||||
this._onDragEnd(aEvent);
|
this._onDragEnd(aEvent);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1847,8 +1849,8 @@ CustomizeMode.prototype = {
|
||||||
|
|
||||||
// For BrowserUITelemetry, an "add" is only when we move an item from the palette
|
// For BrowserUITelemetry, an "add" is only when we move an item from the palette
|
||||||
// into an area. Otherwise, it's a move.
|
// into an area. Otherwise, it's a move.
|
||||||
let custEventType = aOriginArea.id == kPaletteId ? "add" : "move";
|
//let custEventType = aOriginArea.id == kPaletteId ? "add" : "move";
|
||||||
BrowserUITelemetry.countCustomizationEvent(custEventType);
|
//BrowserUITelemetry.countCustomizationEvent(custEventType);
|
||||||
|
|
||||||
// If we dropped onto a skipintoolbarset item, manually correct the drop location:
|
// If we dropped onto a skipintoolbarset item, manually correct the drop location:
|
||||||
if (aTargetNode != itemForPlacement) {
|
if (aTargetNode != itemForPlacement) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user