Merge fx-team to m-c

This commit is contained in:
Wes Kocher 2014-03-03 20:20:23 -08:00
commit abec953a8d
24 changed files with 274 additions and 105 deletions

View File

@ -502,7 +502,7 @@
<deck flex="1" id="tab-view-deck"> <deck flex="1" id="tab-view-deck">
<vbox flex="1" id="browser-panel"> <vbox flex="1" id="browser-panel">
<toolbox id="navigator-toolbox"> <toolbox id="navigator-toolbox" mode="icons">
<!-- Menu --> <!-- Menu -->
<toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true" <toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
defaultset="menubar-items" defaultset="menubar-items"

View File

@ -389,9 +389,10 @@ let CustomizableUIInternal = {
// If this area is not registered, try to do it automatically: // If this area is not registered, try to do it automatically:
if (!areaProperties) { if (!areaProperties) {
// If there's no default set attribute at all, we assume that we should // If there's no defaultset attribute and this isn't a legacy extra toolbar,
// wait for registerArea to be called: // we assume that we should wait for registerArea to be called:
if (!aToolbar.hasAttribute("defaultset")) { if (!aToolbar.hasAttribute("defaultset") &&
!aToolbar.hasAttribute("customindex")) {
if (!gPendingBuildAreas.has(area)) { if (!gPendingBuildAreas.has(area)) {
gPendingBuildAreas.set(area, new Map()); gPendingBuildAreas.set(area, new Map());
} }
@ -400,7 +401,7 @@ let CustomizableUIInternal = {
return; return;
} }
let props = {type: CustomizableUI.TYPE_TOOLBAR, legacy: true}; let props = {type: CustomizableUI.TYPE_TOOLBAR, legacy: true};
let defaultsetAttribute = aToolbar.getAttribute("defaultset"); let defaultsetAttribute = aToolbar.getAttribute("defaultset") || "";
props.defaultPlacements = defaultsetAttribute.split(',').filter(s => s); props.defaultPlacements = defaultsetAttribute.split(',').filter(s => s);
this.registerArea(area, props); this.registerArea(area, props);
areaProperties = gAreas.get(area); areaProperties = gAreas.get(area);
@ -2105,6 +2106,8 @@ let CustomizableUIInternal = {
gUIStateBeforeReset.uiCustomizationState = Services.prefs.getCharPref(kPrefCustomizationState); gUIStateBeforeReset.uiCustomizationState = Services.prefs.getCharPref(kPrefCustomizationState);
} catch(e) { } } catch(e) { }
this._resetExtraToolbars();
Services.prefs.clearUserPref(kPrefCustomizationState); Services.prefs.clearUserPref(kPrefCustomizationState);
Services.prefs.clearUserPref(kPrefDrawInTitlebar); Services.prefs.clearUserPref(kPrefDrawInTitlebar);
LOG("State reset"); LOG("State reset");
@ -2121,6 +2124,28 @@ let CustomizableUIInternal = {
} }
}, },
_resetExtraToolbars: function(aFilter = null) {
let firstWindow = true; // Only need to persist once
for (let [win, ] of gBuildWindows) {
let toolbox = win.gNavToolbox;
for (let child of toolbox.children) {
let matchesFilter = !aFilter || aFilter == child.id;
if (child.hasAttribute("customindex") && matchesFilter) {
if (firstWindow) {
let toolbarId = "toolbar" + child.getAttribute("customindex");
toolbox.toolbarset.removeAttribute(toolbarId);
win.document.persist(toolbox.toolbarset.id, toolbarId);
// We have to unregister it properly to ensure we don't kill
// XUL widgets which might be in here
this.unregisterArea(child.id, true);
}
child.remove();
}
}
firstWindow = false;
}
},
_rebuildRegisteredAreas: function() { _rebuildRegisteredAreas: function() {
for (let [areaId, areaNodes] of gBuildAreas) { for (let [areaId, areaNodes] of gBuildAreas) {
let placements = gPlacements.get(areaId); let placements = gPlacements.get(areaId);
@ -2174,6 +2199,10 @@ let CustomizableUIInternal = {
}); });
}, },
removeExtraToolbar: function(aToolbarId) {
this._resetExtraToolbars(aToolbarId);
},
/** /**
* @param {String|Node} aWidget - widget ID or a widget node (preferred for performance). * @param {String|Node} aWidget - widget ID or a widget node (preferred for performance).
* @return {Boolean} whether the widget is removable * @return {Boolean} whether the widget is removable
@ -2281,7 +2310,8 @@ let CustomizableUIInternal = {
// Toolbars have a currentSet property which also deals correctly with overflown // Toolbars have a currentSet property which also deals correctly with overflown
// widgets (if any) - use that instead: // widgets (if any) - use that instead:
if (props.get("type") == CustomizableUI.TYPE_TOOLBAR) { if (props.get("type") == CustomizableUI.TYPE_TOOLBAR) {
currentPlacements = container.currentSet.split(','); let currentSet = container.currentSet;
currentPlacements = currentSet ? currentSet.split(',') : [];
currentPlacements = currentPlacements.filter(removableOrDefault); currentPlacements = currentPlacements.filter(removableOrDefault);
} else { } else {
// Clone the array so we don't modify the actual placements... // Clone the array so we don't modify the actual placements...
@ -2942,6 +2972,17 @@ this.CustomizableUI = {
CustomizableUIInternal.undoReset(); CustomizableUIInternal.undoReset();
}, },
/**
* Remove a custom toolbar added in a previous version of Firefox or using
* an add-on. NB: only works on the customizable toolbars generated by
* the toolbox itself. Intended for use from CustomizeMode, not by
* other consumers.
* @param aToolbarId the ID of the toolbar to remove
*/
removeExtraToolbar: function(aToolbarId) {
CustomizableUIInternal.removeExtraToolbar(aToolbarId);
},
/** /**
* Can the last Restore Defaults operation be undone. * Can the last Restore Defaults operation be undone.
* *

View File

@ -300,6 +300,8 @@ CustomizeMode.prototype = {
this._handler.isExitingCustomizeMode = true; this._handler.isExitingCustomizeMode = true;
this._removeExtraToolbarsIfEmpty();
CustomizableUI.removeListener(this); CustomizableUI.removeListener(this);
this.document.removeEventListener("keypress", this); this.document.removeEventListener("keypress", this);
@ -855,6 +857,18 @@ CustomizeMode.prototype = {
}.bind(this)).then(null, ERROR); }.bind(this)).then(null, ERROR);
}, },
_removeExtraToolbarsIfEmpty: function() {
let toolbox = this.window.gNavToolbox;
for (let child of toolbox.children) {
if (child.hasAttribute("customindex")) {
let placements = CustomizableUI.getWidgetIdsInArea(child.id);
if (!placements.length) {
CustomizableUI.removeExtraToolbar(child.id);
}
}
}
},
persistCurrentSets: function(aSetBeforePersisting) { persistCurrentSets: function(aSetBeforePersisting) {
let document = this.document; let document = this.document;
let toolbars = document.querySelectorAll("toolbar[customizable='true'][currentset]"); let toolbars = document.querySelectorAll("toolbar[customizable='true'][currentset]");

View File

@ -71,4 +71,5 @@ skip-if = os == "linux"
[browser_970511_undo_restore_default.js] [browser_970511_undo_restore_default.js]
[browser_972267_customizationchange_events.js] [browser_972267_customizationchange_events.js]
[browser_973932_addonbar_currentset.js] [browser_973932_addonbar_currentset.js]
[browser_975719_customtoolbars_behaviour.js]
[browser_panel_toggle.js] [browser_panel_toggle.js]

View File

@ -59,6 +59,7 @@ add_task(function() {
"Widget should be in navbar in other window."); "Widget should be in navbar in other window.");
} }
} }
CustomizableUI.destroyWidget(spec.id);
yield promiseWindowClosed(otherWin); yield promiseWindowClosed(otherWin);
}); });

View File

@ -0,0 +1,100 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
"use strict";
add_task(function customizeToolbarAndKeepIt() {
ok(gNavToolbox.toolbarset, "There should be a toolbarset");
let toolbarID = "testAustralisCustomToolbar";
gNavToolbox.appendCustomToolbar(toolbarID, "");
let toolbarDOMID = getToolboxCustomToolbarId(toolbarID);
let toolbarElement = document.getElementById(toolbarDOMID);
ok(toolbarElement, "There should be a toolbar");
if (!toolbarElement) {
ok(false, "No toolbar created, bailing out of the test.");
return;
}
is(toolbarElement.nextSibling, gNavToolbox.toolbarset,
"Toolbar should have been inserted in toolbox, before toolbarset element");
let cuiAreaType = CustomizableUI.getAreaType(toolbarDOMID);
is(cuiAreaType, CustomizableUI.TYPE_TOOLBAR,
"CustomizableUI should know the area and think it's a toolbar");
if (cuiAreaType != CustomizableUI.TYPE_TOOLBAR) {
ok(false, "Toolbar not registered successfully, bailing out of the test.");
toolbarElement.remove();
return;
}
ok(!CustomizableUI.getWidgetIdsInArea(toolbarDOMID).length, "There should be no widgets in the area yet.");
CustomizableUI.addWidgetToArea("open-file-button", toolbarDOMID, 0);
ok(toolbarElement.hasChildNodes(), "Toolbar should now have a button.");
assertAreaPlacements(toolbarDOMID, ["open-file-button"]);
yield startCustomizing();
// First, exit customize mode without doing anything, and verify the toolbar doesn't get removed.
yield endCustomizing();
ok(!CustomizableUI.inDefaultState, "Shouldn't be in default state, the toolbar should still be there.");
cuiAreaType = CustomizableUI.getAreaType(toolbarDOMID);
is(cuiAreaType, CustomizableUI.TYPE_TOOLBAR,
"CustomizableUI should still know the area and think it's a toolbar");
ok(toolbarElement.parentNode, "Toolbar should still be in the DOM.");
ok(toolbarElement.hasChildNodes(), "Toolbar should still have items in it.");
assertAreaPlacements(toolbarDOMID, ["open-file-button"]);
// Then customize again, and this time empty out the toolbar and verify it *does* get removed.
yield startCustomizing();
let openFileButton = document.getElementById("open-file-button");
let palette = document.getElementById("customization-palette");
simulateItemDrag(openFileButton, palette);
ok(!CustomizableUI.inDefaultState, "Shouldn't be in default state because there's still a non-collapsed toolbar.");
ok(!toolbarElement.hasChildNodes(), "Toolbar should have no more child nodes.");
toolbarElement.collapsed = true;
ok(CustomizableUI.inDefaultState, "Should be in default state because there's now just a collapsed toolbar.");
toolbarElement.collapsed = false;
ok(!CustomizableUI.inDefaultState, "Shouldn't be in default state because there's a non-collapsed toolbar again.");
yield endCustomizing();
ok(CustomizableUI.inDefaultState, "Should be in default state because the toolbar should have been removed.");
ok(!toolbarElement.parentNode, "Toolbar should no longer be in the DOM.");
cuiAreaType = CustomizableUI.getAreaType(toolbarDOMID);
is(cuiAreaType, null, "CustomizableUI should have forgotten all about the area");
});
add_task(function resetShouldDealWithCustomToolbars() {
ok(gNavToolbox.toolbarset, "There should be a toolbarset");
let toolbarID = "testAustralisCustomToolbar";
gNavToolbox.appendCustomToolbar(toolbarID, "");
let toolbarDOMID = getToolboxCustomToolbarId(toolbarID);
let toolbarElement = document.getElementById(toolbarDOMID);
ok(toolbarElement, "There should be a toolbar");
if (!toolbarElement) {
ok(false, "No toolbar created, bailing out of the test.");
return;
}
is(toolbarElement.nextSibling, gNavToolbox.toolbarset,
"Toolbar should have been inserted in toolbox, before toolbarset element");
let cuiAreaType = CustomizableUI.getAreaType(toolbarDOMID);
is(cuiAreaType, CustomizableUI.TYPE_TOOLBAR,
"CustomizableUI should know the area and think it's a toolbar");
if (cuiAreaType != CustomizableUI.TYPE_TOOLBAR) {
ok(false, "Toolbar not registered successfully, bailing out of the test.");
toolbarElement.remove();
return;
}
ok(!CustomizableUI.getWidgetIdsInArea(toolbarDOMID).length, "There should be no widgets in the area yet.");
CustomizableUI.addWidgetToArea("sync-button", toolbarDOMID, 0);
ok(toolbarElement.hasChildNodes(), "Toolbar should now have a button.");
assertAreaPlacements(toolbarDOMID, ["sync-button"]);
CustomizableUI.reset();
ok(CustomizableUI.inDefaultState, "Should be in default state after reset.");
let syncButton = document.getElementById("sync-button");
ok(!syncButton, "Sync button shouldn't be in the document anymore.");
ok(gNavToolbox.palette.querySelector("#sync-button"), "Sync button should be in the palette");
ok(!toolbarElement.hasChildNodes(), "Toolbar should have no more child nodes.");
ok(!toolbarElement.parentNode, "Toolbar should no longer be in the DOM.");
cuiAreaType = CustomizableUI.getAreaType(toolbarDOMID);
is(cuiAreaType, null, "CustomizableUI should have forgotten all about the area");
});

View File

@ -11,8 +11,7 @@ Cu.import("resource:///modules/CustomizableUI.jsm", tmp);
let {Promise, CustomizableUI} = tmp; let {Promise, CustomizableUI} = tmp;
let ChromeUtils = {}; let ChromeUtils = {};
let scriptLoader = Cc["@mozilla.org/moz/jssubscript-loader;1"].getService(Ci.mozIJSSubScriptLoader); Services.scriptloader.loadSubScript("chrome://mochikit/content/tests/SimpleTest/ChromeUtils.js", ChromeUtils);
scriptLoader.loadSubScript("chrome://mochikit/content/tests/SimpleTest/ChromeUtils.js", ChromeUtils);
Services.prefs.setBoolPref("browser.uiCustomization.skipSourceNodeCheck", true); Services.prefs.setBoolPref("browser.uiCustomization.skipSourceNodeCheck", true);
registerCleanupFunction(() => Services.prefs.clearUserPref("browser.uiCustomization.skipSourceNodeCheck")); registerCleanupFunction(() => Services.prefs.clearUserPref("browser.uiCustomization.skipSourceNodeCheck"));
@ -55,6 +54,10 @@ function removeCustomToolbars() {
gAddedToolbars.clear(); gAddedToolbars.clear();
} }
function getToolboxCustomToolbarId(toolbarName) {
return "__customToolbar_" + toolbarName.replace(" ", "_");
}
function resetCustomization() { function resetCustomization() {
return CustomizableUI.reset(); return CustomizableUI.reset();
} }

View File

@ -147,11 +147,8 @@ let gSyncPane = {
document.getElementById("fxaEmailAddress2").textContent = data.email; document.getElementById("fxaEmailAddress2").textContent = data.email;
document.getElementById("fxaEmailAddress3").textContent = data.email; document.getElementById("fxaEmailAddress3").textContent = data.email;
document.getElementById("fxaSyncComputerName").value = Weave.Service.clientsEngine.localName; document.getElementById("fxaSyncComputerName").value = Weave.Service.clientsEngine.localName;
let enginesList = document.getElementById("fxaSyncEnginesList") let engines = document.getElementById("fxaSyncEngines")
enginesList.disabled = enginesListDisabled; for (let checkbox of engines.querySelectorAll("checkbox")) {
// *sigh* - disabling the <richlistbox> draws each item as if it is disabled,
// but doesn't disable the checkboxes.
for (let checkbox of enginesList.querySelectorAll("checkbox")) {
checkbox.disabled = enginesListDisabled; checkbox.disabled = enginesListDisabled;
} }
}); });

View File

@ -259,41 +259,25 @@
<groupbox id="syncOptions"> <groupbox id="syncOptions">
<caption label="&syncBrand.shortName.label;"/> <caption label="&syncBrand.shortName.label;"/>
<vbox> <vbox id="fxaSyncEngines">
<richlistbox id="fxaSyncEnginesList" <checkbox label="&engine.tabs.label;"
orient="vertical" accesskey="&engine.tabs.accesskey;"
onselect="if (this.selectedCount) this.clearSelection();"> preference="engine.tabs"/>
<richlistitem> <checkbox label="&engine.bookmarks.label;"
<checkbox label="&engine.tabs.label;" accesskey="&engine.bookmarks.accesskey;"
accesskey="&engine.tabs.accesskey;" preference="engine.bookmarks"/>
preference="engine.tabs"/> <checkbox label="&engine.passwords.label;"
</richlistitem> accesskey="&engine.passwords.accesskey;"
<richlistitem> preference="engine.passwords"/>
<checkbox label="&engine.bookmarks.label;" <checkbox label="&engine.history.label;"
accesskey="&engine.bookmarks.accesskey;" accesskey="&engine.history.accesskey;"
preference="engine.bookmarks"/> preference="engine.history"/>
</richlistitem> <checkbox label="&engine.addons.label;"
<richlistitem> accesskey="&engine.addons.accesskey;"
<checkbox label="&engine.passwords.label;" preference="engine.addons"/>
accesskey="&engine.passwords.accesskey;" <checkbox label="&engine.prefs.label;"
preference="engine.passwords"/> accesskey="&engine.prefs.accesskey;"
</richlistitem> preference="engine.prefs"/>
<richlistitem>
<checkbox label="&engine.history.label;"
accesskey="&engine.history.accesskey;"
preference="engine.history"/>
</richlistitem>
<richlistitem>
<checkbox label="&engine.addons.label;"
accesskey="&engine.addons.accesskey;"
preference="engine.addons"/>
</richlistitem>
<richlistitem>
<checkbox label="&engine.prefs.label;"
accesskey="&engine.prefs.accesskey;"
preference="engine.prefs"/>
</richlistitem>
</richlistbox>
</vbox> </vbox>
</groupbox> </groupbox>
<hbox align="center"> <hbox align="center">

View File

@ -1186,6 +1186,8 @@ RequestsMenuView.prototype = Heritage.extend(WidgetMethods, {
} }
case "status": { case "status": {
let node = $(".requests-menu-status", target); let node = $(".requests-menu-status", target);
let codeNode = $(".requests-menu-status-code", target);
codeNode.setAttribute("value", aValue);
node.setAttribute("code", aValue); node.setAttribute("code", aValue);
break; break;
} }

View File

@ -148,6 +148,8 @@
<hbox class="requests-menu-subitem requests-menu-status-and-method" <hbox class="requests-menu-subitem requests-menu-status-and-method"
align="center"> align="center">
<box class="requests-menu-status"/> <box class="requests-menu-status"/>
<label class="plain requests-menu-status-code"
crop="end"/>
<label class="plain requests-menu-method" <label class="plain requests-menu-method"
crop="end" crop="end"
flex="1"/> flex="1"/>

View File

@ -248,10 +248,13 @@ function verifyRequestItemTarget(aRequestItem, aMethod, aUrl, aData = {}) {
if (status !== undefined) { if (status !== undefined) {
let value = target.querySelector(".requests-menu-status").getAttribute("code"); let value = target.querySelector(".requests-menu-status").getAttribute("code");
let codeValue = target.querySelector(".requests-menu-status-code").getAttribute("value");
let tooltip = target.querySelector(".requests-menu-status-and-method").getAttribute("tooltiptext"); let tooltip = target.querySelector(".requests-menu-status-and-method").getAttribute("tooltiptext");
info("Displayed status: " + value); info("Displayed status: " + value);
info("Displayed code: " + codeValue);
info("Tooltip status: " + tooltip); info("Tooltip status: " + tooltip);
is(value, status, "The displayed status is incorrect."); is(value, status, "The displayed status is incorrect.");
is(codeValue, status, "The displayed status code is incorrect.");
is(tooltip, status + " " + statusText, "The tooltip status is incorrect."); is(tooltip, status + " " + statusText, "The tooltip status is incorrect.");
} }
if (type !== undefined) { if (type !== undefined) {

View File

@ -268,7 +268,6 @@ StyleEditorUI.prototype = {
new StyleSheetEditor(styleSheet, this._window, file, isNew, this._walker); new StyleSheetEditor(styleSheet, this._window, file, isNew, this._walker);
editor.on("property-change", this._summaryChange.bind(this, editor)); editor.on("property-change", this._summaryChange.bind(this, editor));
editor.on("style-applied", this._summaryChange.bind(this, editor));
editor.on("linked-css-file", this._summaryChange.bind(this, editor)); editor.on("linked-css-file", this._summaryChange.bind(this, editor));
editor.on("linked-css-file-error", this._summaryChange.bind(this, editor)); editor.on("linked-css-file-error", this._summaryChange.bind(this, editor));
editor.on("error", this._onError); editor.on("error", this._onError);

View File

@ -596,9 +596,9 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
-moz-padding-end: 5px; -moz-padding-end: 5px;
} }
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover > .toolbarbutton-icon, :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover > .toolbarbutton-icon,
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([buttonover]):not([open]):hover > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon, :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([buttonover]):not([open]):hover > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon,
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([disabled]):hover > .toolbarbutton-icon { :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([disabled=true]):hover > .toolbarbutton-icon {
background-color: hsla(0,0%,100%,.3); background-color: hsla(0,0%,100%,.3);
background-image: linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.2)); background-image: linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.2));
border: 1px solid rgb(154,154,154); border: 1px solid rgb(154,154,154);
@ -613,9 +613,9 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
margin-bottom: 4px; margin-bottom: 4px;
} }
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover:active > .toolbarbutton-icon, :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover:active > .toolbarbutton-icon,
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1[open="true"] > .toolbarbutton-menubutton-dropmarker:not([disabled]) > .dropmarker-icon, :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1[open="true"] > .toolbarbutton-menubutton-dropmarker:not([disabled=true]) > .dropmarker-icon,
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([disabled]):hover:active > .toolbarbutton-icon, :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([disabled=true]):hover:active > .toolbarbutton-icon,
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1[open="true"] > .toolbarbutton-icon { :-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1[open="true"] > .toolbarbutton-icon {
background-color: rgba(154,154,154,.5); background-color: rgba(154,154,154,.5);
background-image: linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.4)); background-image: linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.4));
@ -750,7 +750,7 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menu-dropmarker, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menu-dropmarker,
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-dropmarker, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-dropmarker,
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-button > .toolbarbutton-icon, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-button > .toolbarbutton-icon,
#main-window:not([customizing]) .toolbarbutton-1 > .toolbarbutton-menubutton-button[disabled] > .toolbarbutton-icon { #main-window:not([customizing]) .toolbarbutton-1 > .toolbarbutton-menubutton-button[disabled=true] > .toolbarbutton-icon {
opacity: 0.4; opacity: 0.4;
} }

View File

@ -2914,18 +2914,18 @@ toolbarbutton.chevron > .toolbarbutton-menu-dropmarker {
.tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled]):hover, .tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled]):hover,
.tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled]):hover, .tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled]):hover,
#TabsToolbar .toolbarbutton-1:not([type="menu-button"]):not([disabled]):not([open]):hover, #TabsToolbar .toolbarbutton-1:not([type="menu-button"]):not([disabled=true]):not([open]):hover,
#TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover, #TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover,
#TabsToolbar .toolbarbutton-1:not([disabled]):not([buttonover]):hover > .toolbarbutton-menubutton-dropmarker { #TabsToolbar .toolbarbutton-1:not([disabled=true]):not([buttonover]):hover > .toolbarbutton-menubutton-dropmarker {
background-image: linear-gradient(transparent, rgba(0,0,0,.15)) !important; background-image: linear-gradient(transparent, rgba(0,0,0,.15)) !important;
} }
.tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled]):hover:active, .tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled]):hover:active,
.tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled]):hover:active, .tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled]):hover:active,
#TabsToolbar .toolbarbutton-1:not([type="menu-button"]):not([disabled]):hover:active, #TabsToolbar .toolbarbutton-1:not([type="menu-button"]):not([disabled=true]):hover:active,
#TabsToolbar .toolbarbutton-1[type="menu"][open], #TabsToolbar .toolbarbutton-1[type="menu"][open],
#TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover:active, #TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover:active,
#TabsToolbar .toolbarbutton-1[open]:not([disabled]):hover > .toolbarbutton-menubutton-dropmarker { #TabsToolbar .toolbarbutton-1[open]:not([disabled=true]):hover > .toolbarbutton-menubutton-dropmarker {
background-image: linear-gradient(transparent, rgba(0,0,0,.3)) !important; background-image: linear-gradient(transparent, rgba(0,0,0,.3)) !important;
} }

View File

@ -113,7 +113,7 @@
/* Network requests table: specific column dimensions */ /* Network requests table: specific column dimensions */
.requests-menu-status-and-method { .requests-menu-status-and-method {
width: 8em; width: 12em;
} }
.requests-menu-status { .requests-menu-status {
@ -177,6 +177,12 @@ box.requests-menu-status {
transition: box-shadow 0.5s ease-in-out; transition: box-shadow 0.5s ease-in-out;
} }
label.requests-menu-status-code {
-moz-margin-start: 3px !important;
width: 3em;
-moz-margin-end: -3em !important;
}
.theme-dark box.requests-menu-status:not([code]) { .theme-dark box.requests-menu-status:not([code]) {
background-color: rgba(95, 115, 135, 1); /* dark grey */ background-color: rgba(95, 115, 135, 1); /* dark grey */
} }
@ -282,22 +288,22 @@ box.requests-menu-status {
} }
.theme-dark .requests-menu-timings-division[division-scale=second] { .theme-dark .requests-menu-timings-division[division-scale=second] {
-moz-border-start-color: #d99b28 !important; /* Light orange highlight color */ -moz-border-start-color: #f5f7fa !important; /* Light foreground text */
font-weight: 600; font-weight: 600;
} }
.theme-light .requests-menu-timings-division[division-scale=second] { .theme-light .requests-menu-timings-division[division-scale=second] {
-moz-border-start-color: #d97e00 !important; /* Light orange highlight color */ -moz-border-start-color: #585959 !important; /* Grey foreground text */
font-weight: 600; font-weight: 600;
} }
.theme-dark .requests-menu-timings-division[division-scale=minute] { .theme-dark .requests-menu-timings-division[division-scale=minute] {
-moz-border-start-color: #eb5368 !important; /* Red highlight color */ -moz-border-start-color: #f5f7fa !important; /* Light foreground text */
font-weight: 600; font-weight: 600;
} }
.theme-light .requests-menu-timings-division[division-scale=minute] { .theme-light .requests-menu-timings-division[division-scale=minute] {
-moz-border-start-color: #ed2655 !important; /* Red highlight color */ -moz-border-start-color: #585959 !important; /* Grey foreground text */
font-weight: 600; font-weight: 600;
} }

View File

@ -462,7 +462,7 @@ menuitem.bookmark-item {
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menu-dropmarker, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menu-dropmarker,
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-dropmarker, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-dropmarker,
#main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-button > .toolbarbutton-icon, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-button > .toolbarbutton-icon,
#main-window:not([customizing]) .toolbarbutton-1 > .toolbarbutton-menubutton-button[disabled] > .toolbarbutton-icon { #main-window:not([customizing]) .toolbarbutton-1 > .toolbarbutton-menubutton-button[disabled=true] > .toolbarbutton-icon {
opacity: .4; opacity: .4;
} }
@ -584,7 +584,7 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
} }
#nav-bar .toolbarbutton-1:not(:hover):not(:active):not([open]) > .toolbarbutton-menubutton-dropmarker::before, #nav-bar .toolbarbutton-1:not(:hover):not(:active):not([open]) > .toolbarbutton-menubutton-dropmarker::before,
#nav-bar .toolbaritem-combined-buttons > .toolbarbutton-1:-moz-any(:not(:hover):not([open]),[disabled]) + .toolbarbutton-1:-moz-any(:not(:hover):not([open]),[disabled])::before { #nav-bar .toolbaritem-combined-buttons > .toolbarbutton-1:-moz-any(:not(:hover):not([open]),[disabled=true]) + .toolbarbutton-1:-moz-any(:not(:hover):not([open]),[disabled=true])::before {
content: ""; content: "";
display: -moz-box; display: -moz-box;
width: 1px; width: 1px;
@ -610,12 +610,12 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
border-bottom-left-radius: 0; border-bottom-left-radius: 0;
} }
#nav-bar .toolbarbutton-1:not([disabled]):-moz-any(:hover,[open]) > .toolbarbutton-menubutton-button > .toolbarbutton-icon, #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any(:hover,[open]) > .toolbarbutton-menubutton-button > .toolbarbutton-icon,
#nav-bar .toolbarbutton-1:not([disabled]):hover > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon, #nav-bar .toolbarbutton-1:not([disabled=true]):hover > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon,
#nav-bar .toolbarbutton-1:not([disabled]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-icon, #nav-bar .toolbarbutton-1:not([disabled=true]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-icon,
#nav-bar .toolbarbutton-1:not([disabled]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-text, #nav-bar .toolbarbutton-1:not([disabled=true]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-text,
#nav-bar .toolbarbutton-1:not([disabled]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-badge-container, #nav-bar .toolbarbutton-1:not([disabled=true]):not([checked]):not([open]):not(:active):hover > .toolbarbutton-badge-container,
@conditionalForwardWithUrlbar@ > .toolbarbutton-1:-moz-any([disabled],:not([open]):not([disabled]):not(:active)) > .toolbarbutton-icon { @conditionalForwardWithUrlbar@ > .toolbarbutton-1:-moz-any([disabled=true],:not([open]):not([disabled=true]):not(:active)) > .toolbarbutton-icon {
background-image: linear-gradient(hsla(0,0%,100%,.6), hsla(0,0%,100%,.1)); background-image: linear-gradient(hsla(0,0%,100%,.6), hsla(0,0%,100%,.1));
border-color: hsla(210,54%,20%,.15) hsla(210,54%,20%,.2) hsla(210,54%,20%,.25); border-color: hsla(210,54%,20%,.15) hsla(210,54%,20%,.2) hsla(210,54%,20%,.25);
box-shadow: 0 1px hsla(0,0%,100%,.3) inset, box-shadow: 0 1px hsla(0,0%,100%,.3) inset,
@ -623,20 +623,20 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
0 0 2px hsla(210,54%,20%,.1); 0 0 2px hsla(210,54%,20%,.1);
} }
#nav-bar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):not([open]):not(:active):hover > .toolbarbutton-icon, #nav-bar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):not([open]):not(:active):hover > .toolbarbutton-icon,
#nav-bar .toolbarbutton-1:not([buttonover]):not([open]):not(:active):hover > .toolbarbutton-menubutton-dropmarker:not([disabled]) > .dropmarker-icon, #nav-bar .toolbarbutton-1:not([buttonover]):not([open]):not(:active):hover > .toolbarbutton-menubutton-dropmarker:not([disabled=true]) > .dropmarker-icon,
@conditionalForwardWithUrlbar@ > #forward-button:not([open]):not(:active):not([disabled]):hover > .toolbarbutton-icon { @conditionalForwardWithUrlbar@ > #forward-button:not([open]):not(:active):not([disabled=true]):hover > .toolbarbutton-icon {
border-color: hsla(210,54%,20%,.3) hsla(210,54%,20%,.35) hsla(210,54%,20%,.4); border-color: hsla(210,54%,20%,.3) hsla(210,54%,20%,.35) hsla(210,54%,20%,.4);
background-color: hsla(210,48%,96%,.75); background-color: hsla(210,48%,96%,.75);
box-shadow: 0 0 1px hsla(210,54%,20%,.03), box-shadow: 0 0 1px hsla(210,54%,20%,.03),
0 0 2px hsla(210,54%,20%,.1); 0 0 2px hsla(210,54%,20%,.1);
} }
#nav-bar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover:active > .toolbarbutton-icon, #nav-bar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover:active > .toolbarbutton-icon,
#nav-bar .toolbarbutton-1[open] > .toolbarbutton-menubutton-dropmarker:not([disabled]) > .dropmarker-icon, #nav-bar .toolbarbutton-1[open] > .toolbarbutton-menubutton-dropmarker:not([disabled=true]) > .dropmarker-icon,
#nav-bar .toolbarbutton-1:not([disabled]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-icon, #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-icon,
#nav-bar .toolbarbutton-1:not([disabled]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-text, #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-text,
#nav-bar .toolbarbutton-1:not([disabled]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-badge-container { #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-badge-container {
background-image: linear-gradient(hsla(0,0%,100%,.6), hsla(0,0%,100%,.1)); background-image: linear-gradient(hsla(0,0%,100%,.6), hsla(0,0%,100%,.1));
background-color: hsla(210,54%,20%,.15); background-color: hsla(210,54%,20%,.15);
border-color: hsla(210,54%,20%,.3) hsla(210,54%,20%,.35) hsla(210,54%,20%,.4); border-color: hsla(210,54%,20%,.3) hsla(210,54%,20%,.35) hsla(210,54%,20%,.4);
@ -649,7 +649,7 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
transition: none; transition: none;
} }
#nav-bar .toolbarbutton-1:-moz-any(:hover,[open]) > .toolbarbutton-menubutton-dropmarker:not([disabled]) > .dropmarker-icon { #nav-bar .toolbarbutton-1:-moz-any(:hover,[open]) > .toolbarbutton-menubutton-dropmarker:not([disabled=true]) > .dropmarker-icon {
-moz-border-start-color: hsla(210,54%,20%,.35); -moz-border-start-color: hsla(210,54%,20%,.35);
} }
@ -667,11 +667,11 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
padding: 0 3px; padding: 0 3px;
} }
#TabsToolbar .toolbarbutton-1:not([disabled]):hover, #TabsToolbar .toolbarbutton-1:not([disabled=true]):hover,
#TabsToolbar .toolbarbutton-1[open], #TabsToolbar .toolbarbutton-1[open],
#TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover, #TabsToolbar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):hover,
.tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled]):hover, .tabbrowser-arrowscrollbox > .scrollbutton-up:not([disabled=true]):hover,
.tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled]):hover { .tabbrowser-arrowscrollbox > .scrollbutton-down:not([disabled=true]):hover {
background-image: linear-gradient(rgba(255,255,255,0), rgba(255,255,255,.5)), background-image: linear-gradient(rgba(255,255,255,0), rgba(255,255,255,.5)),
linear-gradient(transparent, rgba(0,0,0,.25) 30%), linear-gradient(transparent, rgba(0,0,0,.25) 30%),
linear-gradient(transparent, rgba(0,0,0,.25) 30%); linear-gradient(transparent, rgba(0,0,0,.25) 30%);

View File

@ -25,29 +25,33 @@ ANDROID=$(ANDROID_SDK)/../../tools/android
TARGET= $(notdir $(ANDROID_SDK)) TARGET= $(notdir $(ANDROID_SDK))
PACKAGE_DEPS = \ PACKAGE_DEPS = \
build.xml \
res/layout/main.xml \
AndroidManifest.xml \
src/org/mozilla/geckoviewexample/GeckoViewExample.java \
assets/libxul.so \ assets/libxul.so \
build.xml \
src/org/mozilla/geckoviewexample/GeckoViewExample.java \
$(CURDIR)/res/layout/main.xml \
$(CURDIR)/AndroidManifest.xml \
$(NULL) $(NULL)
res/layout/main.xml: $(srcdir)/main.xml $(CURDIR)/res/layout/main.xml: $(srcdir)/main.xml
$(NSINSTALL) $(srcdir)/main.xml res/layout/ $(NSINSTALL) $(srcdir)/main.xml res/layout/
AndroidManifest.xml: $(srcdir)/AndroidManifest.xml $(CURDIR)/AndroidManifest.xml: $(srcdir)/AndroidManifest.xml
$(NSINSTALL) $(srcdir)/AndroidManifest.xml . $(NSINSTALL) $(srcdir)/AndroidManifest.xml $(CURDIR)
src/org/mozilla/geckoviewexample/GeckoViewExample.java: $(srcdir)/GeckoViewExample.java src/org/mozilla/geckoviewexample/GeckoViewExample.java: $(srcdir)/GeckoViewExample.java
$(NSINSTALL) $(srcdir)/GeckoViewExample.java src/org/mozilla/geckoviewexample/ $(NSINSTALL) $(srcdir)/GeckoViewExample.java src/org/mozilla/geckoviewexample/
assets/libxul.so: $(DIST)/geckoview_library/geckoview_assets.zip assets/libxul.so: $(DIST)/geckoview_library/geckoview_assets.zip FORCE
$(UNZIP) -o $(DIST)/geckoview_library/geckoview_assets.zip $(UNZIP) -o $(DIST)/geckoview_library/geckoview_assets.zip
build.xml: build.xml:
$(ANDROID) create project --name GeckoViewExample --target $(TARGET) --path $(CURDIR) --activity GeckoViewExample --package org.mozilla.geckoviewexample $(ANDROID) create project --name GeckoViewExample --target $(TARGET) --path $(CURDIR) --activity GeckoViewExample --package org.mozilla.geckoviewexample
$(ANDROID) update project --target $(TARGET) --path $(CURDIR) --library $(DEPTH)/mobile/android/geckoview_library $(ANDROID) update project --target $(TARGET) --path $(CURDIR) --library $(DEPTH)/mobile/android/geckoview_library
$(RM) $(CURDIR)/res/layout/main.xml
$(NSINSTALL) $(srcdir)/main.xml res/layout/
$(RM) $(CURDIR)/AndroidManifest.xml
$(NSINSTALL) $(srcdir)/AndroidManifest.xml $(CURDIR)
echo jar.libs.dir=libs >> project.properties echo jar.libs.dir=libs >> project.properties
package: $(PACKAGE_DEPS) package: $(PACKAGE_DEPS) FORCE
ant debug ant debug

View File

@ -138,6 +138,7 @@ public class HomeBanner extends LinearLayout
public void run() { public void run() {
mTextView.setText(text); mTextView.setText(text);
setVisibility(VISIBLE); setVisibility(VISIBLE);
GeckoAppShell.sendEventToGecko(GeckoEvent.createBroadcastEvent("HomeBanner:Shown", (String) getTag()));
// Animate the banner if it is currently active. // Animate the banner if it is currently active.
if (mActive) { if (mActive) {

View File

@ -42,13 +42,11 @@ public class testHomeBanner extends UITest {
* Note: This test does not remove the message after it is done. * Note: This test does not remove the message after it is done.
*/ */
private void addBannerTest() { private void addBannerTest() {
addBannerMessage(); // Load about:home and make sure the onshown handler is called.
// Load about:home again, and make sure the onshown handler is called.
Actions.EventExpecter eventExpecter = getActions().expectGeckoEvent("TestHomeBanner:MessageShown"); Actions.EventExpecter eventExpecter = getActions().expectGeckoEvent("TestHomeBanner:MessageShown");
addBannerMessage();
NavigationHelper.enterAndLoadUrl("about:home"); NavigationHelper.enterAndLoadUrl("about:home");
// TODO: Add shown event passing from Java: bug 974723 eventExpecter.blockForEvent();
// eventExpecter.blockForEvent();
// Verify that the banner is visible with the correct text. // Verify that the banner is visible with the correct text.
mAboutHome.assertBannerText(TEXT); mAboutHome.assertBannerText(TEXT);

View File

@ -33,7 +33,7 @@ include $(topsrcdir)/config/rules.mk
_ABS_DIST = $(abspath $(DIST)) _ABS_DIST = $(abspath $(DIST))
package: $(properties_deps) package: $(properties_deps) FORCE
# Make directory for the zips # Make directory for the zips
$(MKDIR) -p $(_ABS_DIST)/geckoview_library $(MKDIR) -p $(_ABS_DIST)/geckoview_library

View File

@ -69,7 +69,10 @@ let HomeBanner = (function () {
text: message.text, text: message.text,
iconURI: message.iconURI iconURI: message.iconURI
}); });
};
let _handleShown = function(id) {
let message = _messages[id];
if (message.onshown) if (message.onshown)
message.onshown(); message.onshown();
}; };
@ -93,13 +96,17 @@ let HomeBanner = (function () {
_handleGet(); _handleGet();
break; break;
case "HomeBanner:Shown":
_handleShown(data);
break;
case "HomeBanner:Click": case "HomeBanner:Click":
_handleClick(data); _handleClick(data);
break; break;
case "HomeBanner:Dismiss": case "HomeBanner:Dismiss":
_handleDismiss(data); _handleDismiss(data);
break; break;
} }
}, },
@ -119,6 +126,7 @@ let HomeBanner = (function () {
// observers to listen for requests from the Java UI. // observers to listen for requests from the Java UI.
if (Object.keys(_messages).length == 1) { if (Object.keys(_messages).length == 1) {
Services.obs.addObserver(this, "HomeBanner:Get", false); Services.obs.addObserver(this, "HomeBanner:Get", false);
Services.obs.addObserver(this, "HomeBanner:Shown", false);
Services.obs.addObserver(this, "HomeBanner:Click", false); Services.obs.addObserver(this, "HomeBanner:Click", false);
Services.obs.addObserver(this, "HomeBanner:Dismiss", false); Services.obs.addObserver(this, "HomeBanner:Dismiss", false);
@ -149,6 +157,7 @@ let HomeBanner = (function () {
// If there are no more messages, remove the observers. // If there are no more messages, remove the observers.
if (Object.keys(_messages).length == 0) { if (Object.keys(_messages).length == 0) {
Services.obs.removeObserver(this, "HomeBanner:Get"); Services.obs.removeObserver(this, "HomeBanner:Get");
Services.obs.removeObserver(this, "HomeBanner:Shown");
Services.obs.removeObserver(this, "HomeBanner:Click"); Services.obs.removeObserver(this, "HomeBanner:Click");
Services.obs.removeObserver(this, "HomeBanner:Dismiss"); Services.obs.removeObserver(this, "HomeBanner:Dismiss");
} }

View File

@ -23,6 +23,7 @@ loader.lazyGetter(this, "CssLogic", () => require("devtools/styleinspector/css-l
let TRANSITION_CLASS = "moz-styleeditor-transitioning"; let TRANSITION_CLASS = "moz-styleeditor-transitioning";
let TRANSITION_DURATION_MS = 500; let TRANSITION_DURATION_MS = 500;
let TRANSITION_BUFFER_MS = 1000;
let TRANSITION_RULE = "\ let TRANSITION_RULE = "\
:root.moz-styleeditor-transitioning, :root.moz-styleeditor-transitioning * {\ :root.moz-styleeditor-transitioning, :root.moz-styleeditor-transitioning * {\
transition-duration: " + TRANSITION_DURATION_MS + "ms !important; \ transition-duration: " + TRANSITION_DURATION_MS + "ms !important; \
@ -751,10 +752,10 @@ let StyleSheetActor = protocol.ActorClass({
this._transitionRefCount++; this._transitionRefCount++;
// Set up clean up and commit after transition duration (+10% buffer) // Set up clean up and commit after transition duration (+buffer)
// @see _onTransitionEnd // @see _onTransitionEnd
this.window.setTimeout(this._onTransitionEnd.bind(this), this.window.setTimeout(this._onTransitionEnd.bind(this),
Math.floor(TRANSITION_DURATION_MS * 1.1)); TRANSITION_DURATION_MS + TRANSITION_BUFFER_MS);
}, },
/** /**

View File

@ -579,6 +579,9 @@ LoadExtensionDirectories(nsINIParser &parser,
void void
nsXREDirProvider::LoadExtensionBundleDirectories() nsXREDirProvider::LoadExtensionBundleDirectories()
{ {
if (!mozilla::Preferences::GetBool("extensions.defaultProviders.enabled", true))
return;
if (mProfileDir && !gSafeMode) { if (mProfileDir && !gSafeMode) {
nsCOMPtr<nsIFile> extensionsINI; nsCOMPtr<nsIFile> extensionsINI;
mProfileDir->Clone(getter_AddRefs(extensionsINI)); mProfileDir->Clone(getter_AddRefs(extensionsINI));