From 5f89c3da66862d82fa27092986c4065aba3574ff Mon Sep 17 00:00:00 2001 From: Ascrod <32915892+Ascrod@users.noreply.github.com> Date: Wed, 30 May 2018 17:45:05 -0400 Subject: Remove Social API. --- .../customizableui/CustomizableWidgets.jsm | 41 ---------------------- 1 file changed, 41 deletions(-) (limited to 'browser/components/customizableui/CustomizableWidgets.jsm') diff --git a/browser/components/customizableui/CustomizableWidgets.jsm b/browser/components/customizableui/CustomizableWidgets.jsm index 3e83b081c..3e00d385f 100644 --- a/browser/components/customizableui/CustomizableWidgets.jsm +++ b/browser/components/customizableui/CustomizableWidgets.jsm @@ -556,47 +556,6 @@ const CustomizableWidgets = [ clearSubview(sidebarItems); fillSubviewFromMenuItems([...menu.children], sidebarItems); } - }, { - id: "social-share-button", - // custom build our button so we can attach to the share command - type: "custom", - onBuild: function(aDocument) { - let node = aDocument.createElementNS(kNSXUL, "toolbarbutton"); - node.setAttribute("id", this.id); - node.classList.add("toolbarbutton-1"); - node.classList.add("chromeclass-toolbar-additional"); - node.setAttribute("label", CustomizableUI.getLocalizedProperty(this, "label")); - node.setAttribute("tooltiptext", CustomizableUI.getLocalizedProperty(this, "tooltiptext")); - node.setAttribute("removable", "true"); - node.setAttribute("observes", "Social:PageShareable"); - node.setAttribute("command", "Social:SharePage"); - - let listener = { - onWidgetAdded: (aWidgetId) => { - if (aWidgetId != this.id) - return; - - Services.obs.notifyObservers(null, "social:" + this.id + "-added", null); - }, - - onWidgetRemoved: aWidgetId => { - if (aWidgetId != this.id) - return; - - Services.obs.notifyObservers(null, "social:" + this.id + "-removed", null); - }, - - onWidgetInstanceRemoved: (aWidgetId, aDoc) => { - if (aWidgetId != this.id || aDoc != aDocument) - return; - - CustomizableUI.removeListener(listener); - } - }; - CustomizableUI.addListener(listener); - - return node; - } }, { id: "add-ons-button", shortcutId: "key_openAddons", -- cgit v1.2.3