Bug 1547351 - Set renderroot of extension popup on browser element r=mattwoodrow
authorDoug Thayer <dothayer@mozilla.com>
Tue, 14 May 2019 16:58:40 +0000
changeset 532963 888907b9ffc32bbe63f0966a77c4fc8cfa2e7d52
parent 532962 8a9694ac64f199178bea35d73467d23ed7a44feb
child 532964 cb6320b272f90d23a044a22d6ee738f7e6bf9d24
push id11276
push userrgurzau@mozilla.com
push dateMon, 20 May 2019 13:11:24 +0000
treeherdermozilla-beta@847755a7c325 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1547351
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1547351 - Set renderroot of extension popup on browser element r=mattwoodrow I'm not sure when/if this stopped working, but it appears the -moz-stack display of the stack element doesn't send us through the admittedly brittle pathways that allow us to create nsDisplayRenderRoots. This brittleness is a consequence of copying the use of the "layer" attribute and is discussed in the core document splitting bug. It's outside the scope of this bug to fix that. Differential Revision: https://phabricator.services.mozilla.com/D31006
browser/components/extensions/ExtensionPopups.jsm
--- a/browser/components/extensions/ExtensionPopups.jsm
+++ b/browser/components/extensions/ExtensionPopups.jsm
@@ -234,17 +234,16 @@ class BasePopup {
     }
   }
 
   createBrowser(viewNode, popupURL = null) {
     let document = viewNode.ownerDocument;
 
     let stack = document.createXULElement("stack");
     stack.setAttribute("class", "webextension-popup-stack");
-    stack.setAttribute("renderroot", "content");
 
     let browser = document.createXULElement("browser");
     browser.setAttribute("type", "content");
     browser.setAttribute("disableglobalhistory", "true");
     browser.setAttribute("transparent", "true");
     browser.setAttribute("class", "webextension-popup-browser");
     browser.setAttribute("webextension-view-type", "popup");
     browser.setAttribute("tooltip", "aHTMLTooltip");
@@ -252,16 +251,17 @@ class BasePopup {
     browser.setAttribute("autocompletepopup", "PopupAutoComplete");
     browser.setAttribute("selectmenulist", "ContentSelectDropdown");
     browser.setAttribute("selectmenuconstrained", "false");
     browser.sameProcessAsFrameLoader = this.extension.groupFrameLoader;
 
     if (this.extension.remote) {
       browser.setAttribute("remote", "true");
       browser.setAttribute("remoteType", E10SUtils.EXTENSION_REMOTE_TYPE);
+      browser.setAttribute("renderroot", "content");
     }
 
     // We only need flex sizing for the sake of the slide-in sub-views of the
     // main menu panel, so that the browser occupies the full width of the view,
     // and also takes up any extra height that's available to it.
     browser.setAttribute("flex", "1");
     stack.setAttribute("flex", "1");