Bug 1915739 - Part 6: Add an attribute to the top-level browser chrome element when opening a Taskbar Tab. r=firefox-desktop-core-reviewers ,mossop
Differential Revision: https://phabricator.services.mozilla.com/D234543
This commit is contained in:
@@ -101,6 +101,17 @@ var gBrowserInit = {
|
||||
);
|
||||
toolbarMenubar.setAttribute("data-l10n-attrs", "toolbarname");
|
||||
}
|
||||
// If opening a Taskbar Tab window, add an attribute to the top-level element
|
||||
// to inform window styling.
|
||||
if (window.arguments && window.arguments[1]) {
|
||||
let extraOptions = window.arguments[1];
|
||||
if (
|
||||
extraOptions instanceof Ci.nsIWritablePropertyBag2 &&
|
||||
extraOptions.hasKey("taskbartab")
|
||||
) {
|
||||
window.document.documentElement.setAttribute("taskbartab", "");
|
||||
}
|
||||
}
|
||||
|
||||
// Run menubar initialization first, to avoid CustomTitlebar code picking
|
||||
// up mutations from it and causing a reflow.
|
||||
|
||||
Reference in New Issue
Block a user