diff --git a/browser/components/customizableui/src/CustomizeMode.jsm b/browser/components/customizableui/src/CustomizeMode.jsm index 9f2d6869cd05..64bce1427821 100644 --- a/browser/components/customizableui/src/CustomizeMode.jsm +++ b/browser/components/customizableui/src/CustomizeMode.jsm @@ -234,7 +234,7 @@ CustomizeMode.prototype = { this._showPanelCustomizationPlaceholders(); yield this._wrapToolbarItems(); - yield this.populatePalette(); + this.populatePalette(); this.visiblePalette.addEventListener("dragstart", this, true); this.visiblePalette.addEventListener("dragover", this, true); @@ -647,7 +647,7 @@ CustomizeMode.prototype = { let fragment = this.document.createDocumentFragment(); let toolboxPalette = this.window.gNavToolbox.palette; - return Task.spawn(function() { + try { let unusedWidgets = CustomizableUI.getUnusedWidgets(toolboxPalette); for (let widget of unusedWidgets) { let paletteItem = this.makePaletteItem(widget, "palette"); @@ -657,7 +657,9 @@ CustomizeMode.prototype = { this.visiblePalette.appendChild(fragment); this._stowedPalette = this.window.gNavToolbox.palette; this.window.gNavToolbox.palette = this.visiblePalette; - }.bind(this)).then(null, ERROR); + } catch (ex) { + ERROR(ex); + } }, //XXXunf Maybe this should use -moz-element instead of wrapping the node? @@ -985,7 +987,7 @@ CustomizeMode.prototype = { CustomizableUI.reset(); yield this._wrapToolbarItems(); - yield this.populatePalette(); + this.populatePalette(); this.persistCurrentSets(true); @@ -1011,7 +1013,7 @@ CustomizeMode.prototype = { CustomizableUI.undoReset(); yield this._wrapToolbarItems(); - yield this.populatePalette(); + this.populatePalette(); this.persistCurrentSets(true);