mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-08 14:03:49 +00:00
Backed out changeset 034e2e79ecfa (bug 1617254) for causing build bustages CLOSED TREE
This commit is contained in:
parent
c31aa68fb4
commit
6b488deed0
@ -21,7 +21,7 @@ addAccessibleTask(
|
||||
ok(iframeDocAcc, "IFRAME document accessible is present");
|
||||
(gIsRemoteIframe ? isnot : is)(
|
||||
browser.browsingContext.currentWindowGlobal.osPid,
|
||||
browser.browsingContext.children[0].currentWindowGlobal.osPid,
|
||||
browser.browsingContext.getChildren()[0].currentWindowGlobal.osPid,
|
||||
`Content and IFRAME documents are in ${
|
||||
gIsRemoteIframe ? "separate processes" : "same process"
|
||||
}.`
|
||||
|
@ -58,35 +58,35 @@ addAccessibleTask(
|
||||
if (gIsRemoteIframe) {
|
||||
isnot(
|
||||
getOsPid(browser.browsingContext),
|
||||
getOsPid(browser.browsingContext.children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0]),
|
||||
`Content and IFRAME documents are in separate processes.`
|
||||
);
|
||||
isnot(
|
||||
getOsPid(browser.browsingContext),
|
||||
getOsPid(browser.browsingContext.children[0].children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0].getChildren()[0]),
|
||||
`Content and nested IFRAME documents are in separate processes.`
|
||||
);
|
||||
isnot(
|
||||
getOsPid(browser.browsingContext.children[0]),
|
||||
getOsPid(browser.browsingContext.children[0].children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0].getChildren()[0]),
|
||||
`IFRAME and nested IFRAME documents are in separate processes.`
|
||||
);
|
||||
} else {
|
||||
is(
|
||||
getOsPid(browser.browsingContext),
|
||||
getOsPid(browser.browsingContext.children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0]),
|
||||
`Content and IFRAME documents are in same processes.`
|
||||
);
|
||||
if (gFissionBrowser) {
|
||||
isnot(
|
||||
getOsPid(browser.browsingContext.children[0]),
|
||||
getOsPid(browser.browsingContext.children[0].children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0].getChildren()[0]),
|
||||
`IFRAME and nested IFRAME documents are in separate processes.`
|
||||
);
|
||||
} else {
|
||||
is(
|
||||
getOsPid(browser.browsingContext),
|
||||
getOsPid(browser.browsingContext.children[0].children[0]),
|
||||
getOsPid(browser.browsingContext.getChildren()[0].getChildren()[0]),
|
||||
`Content and nested IFRAME documents are in same processes.`
|
||||
);
|
||||
}
|
||||
|
@ -7629,7 +7629,7 @@ var gPageStyleMenu = {
|
||||
let actor = global.getActor("PageStyle");
|
||||
actor.sendAsyncMessage(message, data);
|
||||
|
||||
contextsToVisit.push(...currentContext.children);
|
||||
contextsToVisit.push(...currentContext.getChildren());
|
||||
}
|
||||
},
|
||||
|
||||
@ -8457,7 +8457,7 @@ function ReportFalseDeceptiveSite() {
|
||||
});
|
||||
}
|
||||
|
||||
contextsToVisit.push(...currentContext.children);
|
||||
contextsToVisit.push(...currentContext.getChildren());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -387,7 +387,7 @@ async function loadPageInfo(browsingContext, imageElement, browser) {
|
||||
addImage(item);
|
||||
}
|
||||
selectImage();
|
||||
contextsToVisit.push(...currContext.children);
|
||||
contextsToVisit.push(...currContext.getChildren());
|
||||
}
|
||||
|
||||
/* Call registered overlay init functions */
|
||||
|
@ -39,7 +39,7 @@ add_task(async function checkReturnToAboutHome() {
|
||||
info("Clicking the go back button on about:certerror");
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
let locationChangePromise = BrowserTestUtils.waitForLocationChange(
|
||||
gBrowser,
|
||||
@ -114,7 +114,7 @@ add_task(async function checkReturnToPreviousPage() {
|
||||
info("Clicking the go back button on about:certerror");
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let pageShownPromise = BrowserTestUtils.waitForContentEvent(
|
||||
@ -159,7 +159,7 @@ add_task(async function checkAdvancedDetails() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let message = await SpecialPowers.spawn(bc, [], async function() {
|
||||
@ -246,7 +246,7 @@ add_task(async function checkAdvancedDetailsForHSTS() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let message = await SpecialPowers.spawn(bc, [], async function() {
|
||||
@ -335,7 +335,7 @@ add_task(async function checkUnknownIssuerLearnMoreLink() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let href = await SpecialPowers.spawn(bc, [], async function() {
|
||||
@ -356,7 +356,7 @@ add_task(async function checkCautionClass() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
await SpecialPowers.spawn(bc, [useFrame], async function(subFrame) {
|
||||
@ -397,7 +397,7 @@ add_task(async function checkViewCertificate() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let loaded = BrowserTestUtils.waitForNewTab(gBrowser, null, true);
|
||||
@ -462,7 +462,7 @@ add_task(async function checkBadStsCertHeadline() {
|
||||
|
||||
let bc = browser.browsingContext;
|
||||
if (useFrame) {
|
||||
bc = bc.children[0];
|
||||
bc = bc.getChildren()[0];
|
||||
}
|
||||
|
||||
let titleContent = await SpecialPowers.spawn(bc, [], async function() {
|
||||
@ -493,7 +493,7 @@ add_task(async function checkSandboxedIframe() {
|
||||
let tab = await openErrorPage(BAD_CERT, useFrame, sandboxed);
|
||||
let browser = tab.linkedBrowser;
|
||||
|
||||
let bc = browser.browsingContext.children[0];
|
||||
let bc = browser.browsingContext.getChildren()[0];
|
||||
await SpecialPowers.spawn(bc, [], async function() {
|
||||
let doc = content.document;
|
||||
let titleText = doc.querySelector(".title-text");
|
||||
|
@ -139,7 +139,7 @@ add_task(async function() {
|
||||
|
||||
let browsingContext = gBrowser.selectedBrowser.browsingContext;
|
||||
if (test.frameIndex != null) {
|
||||
browsingContext = browsingContext.children[test.frameIndex];
|
||||
browsingContext = browsingContext.getChildren()[test.frameIndex];
|
||||
}
|
||||
|
||||
await new Promise(r => {
|
||||
|
@ -188,7 +188,7 @@ add_task(async function test_alt_click_in_frame() {
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#linkToExample",
|
||||
{ altKey: true },
|
||||
gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
);
|
||||
|
||||
// Wait for all downloads to be added to the download list.
|
||||
|
@ -31,7 +31,7 @@ add_task(async function test_toplevel_frame_permission() {
|
||||
});
|
||||
|
||||
// Show a plugin notification from the iframe's actor:
|
||||
let { currentWindowGlobal } = browser.browsingContext.children[0];
|
||||
let { currentWindowGlobal } = browser.browsingContext.getChildren()[0];
|
||||
let actor = currentWindowGlobal.getActor("Plugin");
|
||||
const kHost = Cc["@mozilla.org/plugin/host;1"].getService(
|
||||
Ci.nsIPluginHost
|
||||
|
@ -63,7 +63,9 @@ add_task(async function test() {
|
||||
is(securityInfo, null, "Found no security info");
|
||||
|
||||
// Get the info of the frame, which is HTTPS.
|
||||
securityInfo = await browser.browsingContext.children[0].currentWindowGlobal.getSecurityInfo();
|
||||
securityInfo = await browser.browsingContext
|
||||
.getChildren()[0]
|
||||
.currentWindowGlobal.getSecurityInfo();
|
||||
securityInfo.QueryInterface(Ci.nsITransportSecurityInfo);
|
||||
ok(securityInfo, "Found some security info");
|
||||
ok(securityInfo.succeededCertChain, "Has a succeeded cert chain");
|
||||
|
@ -16,7 +16,7 @@ var gTests = [
|
||||
desc: "getUserMedia audio+video",
|
||||
run: async function checkAudioVideo() {
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -73,7 +73,7 @@ var gTests = [
|
||||
desc: "getUserMedia audio+video: stop sharing",
|
||||
run: async function checkStopSharing() {
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -148,7 +148,7 @@ var gTests = [
|
||||
"getUserMedia audio+video: reloading the frame removes all sharing UI",
|
||||
run: async function checkReloading() {
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -209,7 +209,7 @@ var gTests = [
|
||||
desc: "getUserMedia audio+video: reloading the frame removes prompts",
|
||||
run: async function checkReloadingRemovesPrompts() {
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -247,7 +247,7 @@ var gTests = [
|
||||
// The WebRTC UI should still show both video and audio indicators.
|
||||
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -289,7 +289,7 @@ var gTests = [
|
||||
// Check that requesting a new device from a different frame
|
||||
// doesn't override sharing UI.
|
||||
let frame2BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[1]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[1]
|
||||
: undefined;
|
||||
|
||||
observerPromise = expectObserverCalled(
|
||||
@ -358,7 +358,7 @@ var gTests = [
|
||||
// second frame, then reload the second frame. After each step, we'll check
|
||||
// the UI is in the correct state.
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
@ -398,7 +398,7 @@ var gTests = [
|
||||
await checkSharingUI({ video: true, audio: false });
|
||||
|
||||
let frame2BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[1]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[1]
|
||||
: undefined;
|
||||
|
||||
observerPromise = expectObserverCalled(
|
||||
@ -463,7 +463,7 @@ var gTests = [
|
||||
"getUserMedia audio+video: reloading the top level page removes all sharing UI",
|
||||
run: async function checkReloading() {
|
||||
let frame1BC = gShouldObserveSubframes
|
||||
? gBrowser.selectedBrowser.browsingContext.children[0]
|
||||
? gBrowser.selectedBrowser.browsingContext.getChildren()[0]
|
||||
: undefined;
|
||||
|
||||
let observerPromise = expectObserverCalled(
|
||||
|
@ -378,7 +378,7 @@ async function getMediaCaptureState() {
|
||||
function gatherBrowsingContexts(aBrowsingContext) {
|
||||
let list = [aBrowsingContext];
|
||||
|
||||
let children = aBrowsingContext.children;
|
||||
let children = aBrowsingContext.getChildren();
|
||||
for (let child of children) {
|
||||
list.push(...gatherBrowsingContexts(child));
|
||||
}
|
||||
|
@ -42,7 +42,7 @@ add_task(async function test_sitespecific_iframe_global_zoom() {
|
||||
is(loadedURL, TEST_IFRAME_URL, "got the load event for the iframe");
|
||||
|
||||
let frameZoom = await SpecialPowers.spawn(
|
||||
gBrowser.selectedBrowser.browsingContext.children[0],
|
||||
gBrowser.selectedBrowser.browsingContext.getChildren()[0],
|
||||
[],
|
||||
async () => {
|
||||
await ContentTaskUtils.waitForCondition(() => {
|
||||
@ -94,7 +94,7 @@ add_task(async function test_sitespecific_global_zoom_enlarge() {
|
||||
is(ZoomManager.getZoomForBrowser(tabBrowser), 0.8, "Local zoom is increased");
|
||||
|
||||
let frameZoom = await SpecialPowers.spawn(
|
||||
gBrowser.selectedBrowser.browsingContext.children[0],
|
||||
gBrowser.selectedBrowser.browsingContext.getChildren()[0],
|
||||
[],
|
||||
async () => {
|
||||
await ContentTaskUtils.waitForCondition(() => {
|
||||
|
@ -35,7 +35,7 @@ function gatherActors(browsingContext) {
|
||||
list.push({ actor, result: null });
|
||||
}
|
||||
|
||||
let children = browsingContext.children;
|
||||
let children = browsingContext.getChildren();
|
||||
for (let child of children) {
|
||||
list.push(...gatherActors(child));
|
||||
}
|
||||
|
@ -247,8 +247,9 @@ add_task(async function testFind() {
|
||||
let { top, left } = rectData[5].rectsAndTexts.rectList[0];
|
||||
await extension.unload();
|
||||
|
||||
let subFrameBrowsingContext =
|
||||
gBrowser.selectedBrowser.browsingContext.children[0].children[1];
|
||||
let subFrameBrowsingContext = gBrowser.selectedBrowser.browsingContext
|
||||
.getChildren()[0]
|
||||
.getChildren()[1];
|
||||
let result = await SpecialPowers.spawn(
|
||||
subFrameBrowsingContext,
|
||||
[],
|
||||
@ -330,8 +331,9 @@ add_task(async function testRemoveHighlighting() {
|
||||
await extension.awaitMessage("test:find:WebExtensionFinished");
|
||||
await extension.unload();
|
||||
|
||||
let subFrameBrowsingContext =
|
||||
gBrowser.selectedBrowser.browsingContext.children[0].children[1];
|
||||
let subFrameBrowsingContext = gBrowser.selectedBrowser.browsingContext
|
||||
.getChildren()[0]
|
||||
.getChildren()[1];
|
||||
let result = await SpecialPowers.spawn(
|
||||
subFrameBrowsingContext,
|
||||
[],
|
||||
|
@ -141,7 +141,7 @@ add_task(
|
||||
BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#test-create-new-tab-from-mouse-click-subframe",
|
||||
{ ctrlKey: true, metaKey: true },
|
||||
tab.linkedBrowser.browsingContext.children[0]
|
||||
tab.linkedBrowser.browsingContext.getChildren()[0]
|
||||
);
|
||||
},
|
||||
expectedWebNavProps: {
|
||||
@ -159,7 +159,7 @@ add_task(
|
||||
BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#test-create-new-window-from-mouse-click-subframe",
|
||||
{ shiftKey: true },
|
||||
tab.linkedBrowser.browsingContext.children[0]
|
||||
tab.linkedBrowser.browsingContext.getChildren()[0]
|
||||
);
|
||||
},
|
||||
expectedWebNavProps: {
|
||||
@ -177,7 +177,7 @@ add_task(
|
||||
BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#test-create-new-tab-from-targetblank-click-subframe",
|
||||
{},
|
||||
tab.linkedBrowser.browsingContext.children[0]
|
||||
tab.linkedBrowser.browsingContext.getChildren()[0]
|
||||
);
|
||||
},
|
||||
expectedWebNavProps: {
|
||||
|
@ -499,7 +499,7 @@ async function openContextMenuInFrame(selector = "body", frameIndex = 0) {
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
selector,
|
||||
{ type: "contextmenu" },
|
||||
gBrowser.selectedBrowser.browsingContext.children[frameIndex]
|
||||
gBrowser.selectedBrowser.browsingContext.getChildren()[frameIndex]
|
||||
);
|
||||
await popupShownPromise;
|
||||
return contentAreaContextMenu;
|
||||
|
@ -24,7 +24,7 @@ add_task(async function test_iframe_autocomplete() {
|
||||
true
|
||||
);
|
||||
let browser = tab.linkedBrowser;
|
||||
let iframeBC = browser.browsingContext.children[1];
|
||||
let iframeBC = browser.browsingContext.getChildren()[1];
|
||||
await openPopupForSubframe(browser, iframeBC, "#street-address");
|
||||
|
||||
// Highlight the first item in the list. We want to verify
|
||||
@ -115,7 +115,7 @@ add_task(async function test_iframe_autocomplete_preferences() {
|
||||
true
|
||||
);
|
||||
let browser = tab.linkedBrowser;
|
||||
let iframeBC = browser.browsingContext.children[1];
|
||||
let iframeBC = browser.browsingContext.getChildren()[1];
|
||||
await openPopupForSubframe(browser, iframeBC, "#organization");
|
||||
|
||||
await expectWarningText(browser, "Also autofills address, email");
|
||||
|
@ -173,7 +173,7 @@ add_task(async function test_submit_untouched_creditCard_form_iframe() {
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: CREDITCARD_FORM_IFRAME_URL },
|
||||
async function(browser) {
|
||||
let iframeBC = browser.browsingContext.children[0];
|
||||
let iframeBC = browser.browsingContext.getChildren()[0];
|
||||
await openPopupForSubframe(browser, iframeBC, "form #cc-name");
|
||||
EventUtils.synthesizeKey("VK_DOWN", {});
|
||||
EventUtils.synthesizeKey("VK_RETURN", {});
|
||||
|
@ -613,7 +613,8 @@ exports.RootActor = protocol.ActorClassWithSpec(rootSpec, {
|
||||
// a different type, we can just get the children directly from
|
||||
// the BrowsingContext.
|
||||
return (
|
||||
parentBrowsingContext.children
|
||||
parentBrowsingContext
|
||||
.getChildren()
|
||||
// For now, we only return the "remote frames".
|
||||
// i.e. the frames which are in a distinct process compared to their parent document
|
||||
.filter(browsingContext => {
|
||||
@ -646,7 +647,7 @@ exports.RootActor = protocol.ActorClassWithSpec(rootSpec, {
|
||||
}
|
||||
pool.manage(frameDescriptor);
|
||||
frames.push(frameDescriptor);
|
||||
contextsToWalk.push(...currentContext.children);
|
||||
contextsToWalk.push(...currentContext.getChildren());
|
||||
}
|
||||
// Do not destroy the pool before transfering ownership to the newly created
|
||||
// pool, so that we do not accidently destroy actors that are still in use.
|
||||
|
@ -423,7 +423,6 @@ void BrowsingContext::Detach(bool aFromIPC) {
|
||||
Children* children = nullptr;
|
||||
if (mParent) {
|
||||
children = &mParent->mChildren;
|
||||
BrowsingContext_Binding::ClearCachedChildrenValue(mParent);
|
||||
} else {
|
||||
children = &mGroup->Toplevels();
|
||||
}
|
||||
@ -434,7 +433,6 @@ void BrowsingContext::Detach(bool aFromIPC) {
|
||||
if (!mChildren.IsEmpty()) {
|
||||
mGroup->CacheContexts(mChildren);
|
||||
mChildren.Clear();
|
||||
BrowsingContext_Binding::ClearCachedChildrenValue(this);
|
||||
}
|
||||
|
||||
{
|
||||
@ -523,7 +521,6 @@ void BrowsingContext::CacheChildren(bool aFromIPC) {
|
||||
|
||||
mGroup->CacheContexts(mChildren);
|
||||
mChildren.Clear();
|
||||
BrowsingContext_Binding::ClearCachedChildrenValue(this);
|
||||
|
||||
if (!aFromIPC && XRE_IsContentProcess()) {
|
||||
auto cc = ContentChild::GetSingleton();
|
||||
@ -545,7 +542,6 @@ void BrowsingContext::RestoreChildren(Children&& aChildren, bool aFromIPC) {
|
||||
}
|
||||
|
||||
mChildren.AppendElements(aChildren);
|
||||
BrowsingContext_Binding::ClearCachedChildrenValue(this);
|
||||
|
||||
if (!aFromIPC && XRE_IsContentProcess()) {
|
||||
auto cc = ContentChild::GetSingleton();
|
||||
|
@ -653,8 +653,6 @@ class BrowsingContext : public nsISupports, public nsWrapperCache {
|
||||
|
||||
RefPtr<BrowsingContextGroup> mGroup;
|
||||
RefPtr<BrowsingContext> mParent;
|
||||
// Note: BrowsingContext_Binding::ClearCachedChildrenValue must be called any
|
||||
// time this array is mutated to keep the JS-exposed reflection in sync.
|
||||
Children mChildren;
|
||||
nsCOMPtr<nsIDocShell> mDocShell;
|
||||
|
||||
|
@ -106,7 +106,7 @@ add_task(async function() {
|
||||
|
||||
await removeFrame(browser, "frame2");
|
||||
|
||||
is(browsingContext1.children.indexOf(browsingContext2), -1);
|
||||
is(browsingContext1.getChildren().indexOf(browsingContext2), -1);
|
||||
|
||||
// TODO(farre): Handle browsingContext removal [see Bug 1486719].
|
||||
todo_isnot(browsingContext2.parent, browsingContext1);
|
||||
@ -190,7 +190,7 @@ add_task(async function() {
|
||||
"BF cached BC's have same id"
|
||||
);
|
||||
is(
|
||||
win.docShell.browsingContext.children[0],
|
||||
win.docShell.browsingContext.getChildren()[0],
|
||||
frameBC,
|
||||
"BF cached BC's should still be a child of its parent"
|
||||
);
|
||||
|
@ -20,8 +20,7 @@ interface BrowsingContext {
|
||||
|
||||
readonly attribute BrowsingContext top;
|
||||
|
||||
[Cached, Frozen, Pure]
|
||||
readonly attribute sequence<BrowsingContext> children;
|
||||
sequence<BrowsingContext> getChildren();
|
||||
|
||||
readonly attribute nsIDocShell? docShell;
|
||||
|
||||
|
@ -399,7 +399,7 @@ However, if any of the frames on the page are running in their own process, they
|
||||
let actor = global.getActor("PageInfo");
|
||||
actor.sendAsyncMessage("PageInfo:getInfoForFrame", { someArgument: 123 });
|
||||
|
||||
contextsToVisit.push(...currentContext.children);
|
||||
contextsToVisit.push(...currentContext.getChildren());
|
||||
}
|
||||
|
||||
The original ``"PageInfo:info"`` message listener will need to be updated, too. Any responses from the ``PageInfoChild`` actor will end up being passed to the ``receiveMessage`` method of the ``PageInfoParent`` actor. It will be necessary to pass that information along to the interested party (in this case, the dialog code which is showing the table of interesting Page Info).
|
||||
|
@ -16,7 +16,3 @@ support-files =
|
||||
support-files =
|
||||
test_visual_viewport_in_oopif.html
|
||||
visual_viewport_in_child.html
|
||||
[browser_select_popup_position_in_out_of_process_iframe.js]
|
||||
support-files =
|
||||
!/gfx/layers/apz/test/mochitest/apz_test_native_event_utils.js
|
||||
!/browser/base/content/test/forms/head.js
|
||||
|
@ -60,7 +60,7 @@ async function openPage(shouldClick) {
|
||||
await BrowserTestUtils.loadURI(browser, PAGE_URL);
|
||||
await BrowserTestUtils.browserLoaded(browser);
|
||||
|
||||
let frameBC = browser.browsingContext.children[0];
|
||||
let frameBC = browser.browsingContext.getChildren()[0];
|
||||
if (shouldClick) {
|
||||
await BrowserTestUtils.synthesizeMouse("body", 2, 2, {}, frameBC);
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ class ReftestFissionParent extends JSWindowActorParent {
|
||||
}
|
||||
}
|
||||
|
||||
for (let context of browsingContext.children) {
|
||||
for (let context of browsingContext.getChildren()) {
|
||||
this.tellChildrenToFlushRenderingRecursive(context, ignoreThrottledAnimations, promises);
|
||||
}
|
||||
}
|
||||
@ -39,7 +39,7 @@ class ReftestFissionParent extends JSWindowActorParent {
|
||||
}
|
||||
}
|
||||
|
||||
for (let context of browsingContext.children) {
|
||||
for (let context of browsingContext.getChildren()) {
|
||||
this.tellChildrenToUpdateLayerTreeRecursive(context, promises);
|
||||
}
|
||||
}
|
||||
|
@ -99,10 +99,12 @@ add_task(async function mouse_in_iframe() {
|
||||
5,
|
||||
10,
|
||||
{},
|
||||
browser.browsingContext.children[0]
|
||||
browser.browsingContext.getChildren()[0]
|
||||
);
|
||||
|
||||
let details = await getLastEventDetails(browser.browsingContext.children[0]);
|
||||
let details = await getLastEventDetails(
|
||||
browser.browsingContext.getChildren()[0]
|
||||
);
|
||||
is(details, "two", "synthesizeMouse");
|
||||
|
||||
await BrowserTestUtils.synthesizeMouse(
|
||||
@ -110,9 +112,9 @@ add_task(async function mouse_in_iframe() {
|
||||
5,
|
||||
10,
|
||||
{},
|
||||
browser.browsingContext.children[1]
|
||||
browser.browsingContext.getChildren()[1]
|
||||
);
|
||||
details = await getLastEventDetails(browser.browsingContext.children[1]);
|
||||
details = await getLastEventDetails(browser.browsingContext.getChildren()[1]);
|
||||
is(details, "four", "synthesizeMouse");
|
||||
|
||||
gBrowser.removeTab(tab);
|
||||
|
@ -346,7 +346,7 @@ class AutoScrollChild extends JSWindowActorChild {
|
||||
let data = msg.data;
|
||||
switch (msg.name) {
|
||||
case "Autoscroll:MaybeStart":
|
||||
for (let child of this.browsingContext.children) {
|
||||
for (let child of this.browsingContext.getChildren()) {
|
||||
if (data.browsingContextId == child.id) {
|
||||
this.startScroll({
|
||||
screenX: data.screenX,
|
||||
|
@ -267,7 +267,7 @@ var PermitUnloader = {
|
||||
roots.push(windowGlobal);
|
||||
}
|
||||
|
||||
contextsToWalk.push(...currentContext.children);
|
||||
contextsToWalk.push(...currentContext.getChildren());
|
||||
}
|
||||
|
||||
return roots;
|
||||
|
@ -55,7 +55,7 @@ class PopupBlocker {
|
||||
let popupCountForGlobal =
|
||||
this._allBlockedPopupCounts.get(windowGlobal) || 0;
|
||||
totalBlockedPopups += popupCountForGlobal;
|
||||
contextsToVisit.push(...currentBC.children);
|
||||
contextsToVisit.push(...currentBC.getChildren());
|
||||
}
|
||||
|
||||
return totalBlockedPopups;
|
||||
@ -112,7 +112,7 @@ class PopupBlocker {
|
||||
}
|
||||
}
|
||||
|
||||
contextsToVisit.push(...currentBC.children);
|
||||
contextsToVisit.push(...currentBC.getChildren());
|
||||
}
|
||||
|
||||
return result;
|
||||
|
@ -71,7 +71,7 @@ add_task(async function test_iframe_in_http_autofill() {
|
||||
await formFilled;
|
||||
|
||||
let [username, password] = await SpecialPowers.spawn(
|
||||
gBrowser.selectedBrowser.browsingContext.children[0],
|
||||
gBrowser.selectedBrowser.browsingContext.getChildren()[0],
|
||||
[],
|
||||
async function() {
|
||||
let doc = this.content.document;
|
||||
|
@ -40,7 +40,7 @@ add_task(async function test_context_menu_iframe_fill() {
|
||||
browser,
|
||||
"#form-basic-password",
|
||||
() => true,
|
||||
browser.browsingContext.children[0]
|
||||
browser.browsingContext.getChildren()[0]
|
||||
);
|
||||
|
||||
let popupMenu = document.getElementById("fill-login-popup");
|
||||
@ -48,7 +48,7 @@ add_task(async function test_context_menu_iframe_fill() {
|
||||
// Stores the original value of username
|
||||
function promiseFrameInputValue(name) {
|
||||
return SpecialPowers.spawn(
|
||||
browser.browsingContext.children[0],
|
||||
browser.browsingContext.getChildren()[0],
|
||||
[name],
|
||||
function(inputname) {
|
||||
return content.document.getElementById(inputname).value;
|
||||
@ -127,7 +127,7 @@ add_task(async function test_context_menu_iframe_sandbox() {
|
||||
);
|
||||
return false;
|
||||
},
|
||||
browser.browsingContext.children[1]
|
||||
browser.browsingContext.getChildren()[1]
|
||||
);
|
||||
let contextMenu = document.getElementById("contentAreaContextMenu");
|
||||
contextMenu.hidePopup();
|
||||
@ -160,7 +160,7 @@ add_task(async function test_context_menu_iframe_sandbox_same_origin() {
|
||||
);
|
||||
return false;
|
||||
},
|
||||
browser.browsingContext.children[2]
|
||||
browser.browsingContext.getChildren()[2]
|
||||
);
|
||||
|
||||
let contextMenu = document.getElementById("contentAreaContextMenu");
|
||||
|
@ -82,7 +82,7 @@ async function submitSomeCrossSiteFrames(locationMode) {
|
||||
);
|
||||
|
||||
let outerFrameBC = firsttab.linkedBrowser.browsingContext;
|
||||
let innerFrameBC = outerFrameBC.children[0];
|
||||
let innerFrameBC = outerFrameBC.getChildren()[0];
|
||||
|
||||
await verifyNotifications(notifyPromise, [
|
||||
"FormProcessed: " + outerFrameBC.id,
|
||||
@ -123,7 +123,7 @@ async function submitSomeCrossSiteFrames(locationMode) {
|
||||
);
|
||||
|
||||
let outerFrameBC2 = secondtab.linkedBrowser.browsingContext;
|
||||
let innerFrameBC2 = outerFrameBC2.children[0];
|
||||
let innerFrameBC2 = outerFrameBC2.getChildren()[0];
|
||||
await verifyNotifications(notifyPromise, [
|
||||
"FormProcessed: " + outerFrameBC2.id,
|
||||
"FormProcessed: " + innerFrameBC2.id,
|
||||
@ -160,7 +160,7 @@ async function submitSomeCrossSiteFrames(locationMode) {
|
||||
);
|
||||
|
||||
let outerFrameBC3 = thirdtab.linkedBrowser.browsingContext;
|
||||
let innerFrameBC3 = outerFrameBC3.children[0];
|
||||
let innerFrameBC3 = outerFrameBC3.getChildren()[0];
|
||||
await verifyNotifications(notifyPromise, [
|
||||
"FormProcessed: " + outerFrameBC3.id,
|
||||
"FormProcessed: " + innerFrameBC3.id,
|
||||
|
@ -110,7 +110,7 @@ function checkAutoCompleteResults(actualValues, expectedValues, hostname, msg) {
|
||||
|
||||
function getIframeBrowsingContext(window, iframeNumber = 0) {
|
||||
let bc = SpecialPowers.wrap(window).windowGlobalChild.browsingContext;
|
||||
return SpecialPowers.unwrap(bc.children[iframeNumber]);
|
||||
return SpecialPowers.unwrap(bc.getChildren()[iframeNumber]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -297,13 +297,13 @@
|
||||
}
|
||||
|
||||
let parentIFrameBC = SpecialPowers.wrap(window).windowGlobalChild
|
||||
.browsingContext.children[0];
|
||||
.browsingContext.getChildren()[0];
|
||||
|
||||
let childIFrame = SpecialPowers.unwrap(parentIFrameBC.children[0]);
|
||||
let childIFrame = SpecialPowers.unwrap(parentIFrameBC.getChildren()[0]);
|
||||
await SpecialPowers.spawn(childIFrame, ["iframe1"], checkIframe);
|
||||
childIFrame = SpecialPowers.unwrap(parentIFrameBC.children[1]);
|
||||
childIFrame = SpecialPowers.unwrap(parentIFrameBC.getChildren()[1]);
|
||||
await SpecialPowers.spawn(childIFrame, ["iframe2"], checkIframe);
|
||||
childIFrame = SpecialPowers.unwrap(parentIFrameBC.children[2]);
|
||||
childIFrame = SpecialPowers.unwrap(parentIFrameBC.getChildren()[2]);
|
||||
await SpecialPowers.spawn(childIFrame, ["iframe3"], checkIframe);
|
||||
});
|
||||
|
||||
|
@ -27,7 +27,7 @@ add_task(async () => {
|
||||
await loadPromise;
|
||||
});
|
||||
|
||||
let iframeBc = browser.browsingContext.children[0];
|
||||
let iframeBc = browser.browsingContext.getChildren()[0];
|
||||
let pipWin = await triggerPictureInPicture(iframeBc, videoID);
|
||||
ok(pipWin, "Got Picture-in-Picture window.");
|
||||
|
||||
|
@ -13,7 +13,7 @@ add_task(async function oopProcessSwap() {
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser: win.gBrowser, url: FILE },
|
||||
async browser => {
|
||||
is(browser.browsingContext.children.length, 0);
|
||||
is(browser.browsingContext.getChildren().length, 0);
|
||||
|
||||
info("creating an in-process frame");
|
||||
let frameId = await SpecialPowers.spawn(
|
||||
@ -31,7 +31,7 @@ add_task(async function oopProcessSwap() {
|
||||
}
|
||||
);
|
||||
|
||||
is(browser.browsingContext.children.length, 1);
|
||||
is(browser.browsingContext.getChildren().length, 1);
|
||||
|
||||
info("navigating to x-process frame");
|
||||
let oopinfo = await SpecialPowers.spawn(
|
||||
@ -68,7 +68,7 @@ add_task(async function oopProcessSwap() {
|
||||
}
|
||||
);
|
||||
|
||||
is(browser.browsingContext.children.length, 1);
|
||||
is(browser.browsingContext.getChildren().length, 1);
|
||||
|
||||
if (Services.prefs.getBoolPref("fission.preserve_browsing_contexts")) {
|
||||
is(
|
||||
@ -98,7 +98,7 @@ add_task(async function oopOriginProcessSwap() {
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser: win.gBrowser, url: COM_DUMMY },
|
||||
async browser => {
|
||||
is(browser.browsingContext.children.length, 0);
|
||||
is(browser.browsingContext.getChildren().length, 0);
|
||||
|
||||
info("creating an in-process frame");
|
||||
let frameId = await SpecialPowers.spawn(
|
||||
@ -116,7 +116,7 @@ add_task(async function oopOriginProcessSwap() {
|
||||
}
|
||||
);
|
||||
|
||||
is(browser.browsingContext.children.length, 1);
|
||||
is(browser.browsingContext.getChildren().length, 1);
|
||||
|
||||
info("navigating to x-process frame");
|
||||
let oopinfo = await SpecialPowers.spawn(
|
||||
@ -153,7 +153,7 @@ add_task(async function oopOriginProcessSwap() {
|
||||
}
|
||||
);
|
||||
|
||||
is(browser.browsingContext.children.length, 1);
|
||||
is(browser.browsingContext.getChildren().length, 1);
|
||||
if (Services.prefs.getBoolPref("fission.preserve_browsing_contexts")) {
|
||||
is(
|
||||
frameId,
|
||||
|
@ -16,7 +16,7 @@ add_task(async function partial_source() {
|
||||
"data:text/html," + source
|
||||
);
|
||||
|
||||
let frameBC = gBrowser.selectedBrowser.browsingContext.children[0];
|
||||
let frameBC = gBrowser.selectedBrowser.browsingContext.getChildren()[0];
|
||||
|
||||
await SpecialPowers.spawn(frameBC, [], () => {
|
||||
let element = content.document.getElementById("other");
|
||||
|
@ -313,7 +313,7 @@ add_task(async function test_hotkey_insubframe() {
|
||||
|
||||
// Focus the editable area within the frame.
|
||||
let browser = gBrowser.selectedBrowser;
|
||||
let frameBC = browser.browsingContext.children[0];
|
||||
let frameBC = browser.browsingContext.getChildren()[0];
|
||||
await SpecialPowers.spawn(frameBC, [], async () => {
|
||||
content.document.body.focus();
|
||||
content.document.defaultView.focus();
|
||||
|
@ -2084,7 +2084,8 @@
|
||||
// Iterate as long as scope in assigned. Note that we use the original
|
||||
// passed in scope, not childScope here.
|
||||
if (scope) {
|
||||
for (let context of browsingContext.children) {
|
||||
let contexts = browsingContext.getChildren();
|
||||
for (let context of contexts) {
|
||||
sendToChildren(context, scope);
|
||||
}
|
||||
}
|
||||
|
@ -164,7 +164,8 @@
|
||||
// Iterate as long as scope in assigned. Note that we use the original
|
||||
// passed in scope, not childScope here.
|
||||
if (scope) {
|
||||
for (let context of browsingContext.children) {
|
||||
let contexts = browsingContext.getChildren();
|
||||
for (let context of contexts) {
|
||||
sendToChildren(context, scope);
|
||||
}
|
||||
}
|
||||
|
@ -938,7 +938,7 @@ var E10SUtils = {
|
||||
let stack = [aBrowser.browsingContext];
|
||||
while (stack.length) {
|
||||
let bc = stack.pop();
|
||||
stack.push(...bc.children);
|
||||
stack.push(...bc.getChildren());
|
||||
if (bc.currentWindowGlobal) {
|
||||
let pid = bc.currentWindowGlobal.osPid;
|
||||
if (pid != tabPid) {
|
||||
|
@ -169,7 +169,8 @@ FinderParent.prototype = {
|
||||
gatherBrowsingContexts(aBrowsingContext) {
|
||||
let list = [aBrowsingContext];
|
||||
|
||||
for (let child of aBrowsingContext.children) {
|
||||
let children = aBrowsingContext.getChildren();
|
||||
for (let child of children) {
|
||||
list.push(...this.gatherBrowsingContexts(child));
|
||||
}
|
||||
|
||||
|
@ -7,7 +7,7 @@ registerCleanupFunction(() => {
|
||||
});
|
||||
|
||||
function check_frame_availability(browser) {
|
||||
return check_availability(browser.browsingContext.children[0]);
|
||||
return check_availability(browser.browsingContext.getChildren()[0]);
|
||||
}
|
||||
|
||||
function check_availability(browser) {
|
||||
|
Loading…
Reference in New Issue
Block a user