Bug 1254865 - remote-browser.xml's browser-child.js should not send a sync message on load
Here’s how I think I want to do this:
For disableglobalhistory, I think we want this to be known and set ASAP
so that we don’t accidentally load things into history that we don’t
want. So let’s send that down with the CreateWindow message.
If the parent opens the new browser, then we also need to send down the disableglobalhistory attribute state.
Send an async message ASAP after binding to the frame element regarding whether or not to use global history.
For initPopup, I think that can go down as a message after the parent has received Browser:Init.
Send async message down after Browser:Init comes in with autocomplete popup state
Have browser-child.js receive autocomplete popup state
Testing? Might need to write a mochitest-chrome test for the
disableglobalhistory thing I just added… There are probably some tests
for autocomplete.
Done! Patches up, waiting on review and try builds to come back.
Hrm, some test failures...
links: [
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%7D",
"title": null,
"frecency": 400,
"lastVisitDate": 1458846436356786,
"type": "history",
"baseDomain": "mochi.test"
},
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458846440374",
"title": "",
"frecency": 200,
"lastVisitDate": 1458846440424504,
"type": "history"
},
{
"url":
"http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setRedCookie%22%3Atrue%7D",
"title": null,
"frecency": 200,
"lastVisitDate": 1458846439491296,
"type": "history"
},
{
"url":
"http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setGreenCookie%22%3Atrue%7D",
"title": null,
"frecency": 200,
"lastVisitDate": 1458846439323235,
"type": "history"
},
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red_scroll.html",
"title": null,
"frecency": 100,
"lastVisitDate": 1458846440214518,
"type": "history"
},
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22wait%22%3A30000%7D",
"title": null,
"frecency": 100,
"lastVisitDate": 1458846440098505,
"type": "history"
},
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22wait%22%3A2002%7D",
"title": null,
"frecency": 100,
"lastVisitDate": 1458846439775091,
"type": "history"
},
{
"url": "http://example.com/",
"title": "mochitest index /",
"frecency": 100,
"lastVisitDate": 1458846435260328,
"type": "history",
"baseDomain": "example.com"
},
{
"url": "http://www.example.com/",
"title": "mochitest index /",
"frecency": 100,
"lastVisitDate": 1458846435130426,
"type": "history"
},
{
"url": "http://example.com/redirected",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846439968848,
"type": "history"
},
{
"url": "http://www.example.com/2",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846439893551,
"type": "history"
},
{
"url": "http://www.example.com/1",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846439750603,
"type": "history"
},
{
"url": "http://www.example.com/0",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846439726366,
"type": "history"
},
{
"url": "http://example.com/1",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846439639556,
"type": "history"
},
{
"url": "http://mochi.test:8888/browser/browser/base/content/test/general/authenticate.sjs?user=anyone",
"title": null,
"frecency": 0,
"lastVisitDate": 1458846439124153,
"type": "history"
},
{
"url": "http://example.com/2",
"title": "404 Not Found",
"frecency": 0,
"lastVisitDate": 1458846438841313,
"type": "history"
}
]
Pinned links: []
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%7D
Is
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%7D
blocked? false pinned?: false
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458846440374
SITE: mochi.test and sites.has: true
Evaluating
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setRedCookie%22%3Atrue%7D
SITE: mochi.test and sites.has: true
Evaluating
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setGreenCookie%22%3Atrue%7D
SITE: mochi.test and sites.has: true
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red_scroll.html
SITE: mochi.test and sites.has: true
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22wait%22%3A30000%7D
SITE: mochi.test and sites.has: true
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22wait%22%3A2002%7D
SITE: mochi.test and sites.has: true
Evaluating http://example.com/
Is http://example.com/ blocked? false pinned?: false
Evaluating http://www.example.com/
SITE: example.com and sites.has: true
Evaluating http://example.com/redirected
SITE: example.com and sites.has: true
Evaluating http://www.example.com/2
SITE: example.com and sites.has: true
Evaluating http://www.example.com/1
SITE: example.com and sites.has: true
Evaluating http://www.example.com/0
SITE: example.com and sites.has: true
Evaluating http://example.com/1
SITE: example.com and sites.has: true
Evaluating http://mochi.test:8888/browser/browser/base/content/test/general/authenticate.sjs?user=anyone
SITE: mochi.test and sites.has: true
Evaluating http://example.com/2
SITE: example.com and sites.has: true
From without the patch:
Holy fuck here are our links: [
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458847544471",
"title": "",
"frecency": 200,
"lastVisitDate": 1458847544512450,
"type": "history",
"baseDomain": "mochi.test"
},
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red_scroll.html",
"title": null,
"frecency": 100,
"lastVisitDate": 1458847544326607,
"type": "history"
},
{
"url":
"http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setRedCookie%22%3Atrue%7D",
"title": null,
"frecency": 100,
"lastVisitDate": 1458847543583004,
"type": "history"
},
{
"url":
"http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setGreenCookie%22%3Atrue%7D",
"title": null,
"frecency": 100,
"lastVisitDate": 1458847543300521,
"type": "history"
}
]
Pinned links: []
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458847544471
Is
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458847544471
blocked? false pinned?: false
Evaluating http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red_scroll.html
SITE: mochi.test and sites.has: true
Evaluating
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setRedCookie%22%3Atrue%7D
SITE: mochi.test and sites.has: true
Evaluating
http://mochi.test:8888/browser/toolkit/components/thumbnails/test/thumbnails_background.sjs?%7B%22setGreenCookie%22%3Atrue%7D
SITE: mochi.test and sites.has: true
Filtered links: [
{
"url": "http://mochi.test:8888/browser/toolkit/components/thumbnails/test/background_red.html?1458847544471",
"title": "",
"frecency": 200,
"lastVisitDate": 1458847544512450,
"type": "history",
"baseDomain": "mochi.test"
}
]
Ah, okay. We had some browsers out there that didn’t have
disableglobalhistory set to true, and they should have. Gonna try to
identify them all now.