зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1415307 - Stop sampling background colour in DOMContentLoaded. r=rbarker
Bug 1297850 removed the only consumer of the background colour on the Java side, so this can go as well. MozReview-Commit-ID: DJwrUVUHZ1t --HG-- extra : rebase_source : be2b5068c57878ff556d1af16eb1df5d5a8779aa
This commit is contained in:
Родитель
ab0cefe88a
Коммит
e99464f25e
|
@ -4080,18 +4080,6 @@ Tab.prototype = {
|
|||
if (target != this.browser.contentDocument)
|
||||
return;
|
||||
|
||||
// Sample the background color of the page and pass it along. (This is used to draw the
|
||||
// checkerboard.) Right now we don't detect changes in the background color after this
|
||||
// event fires; it's not clear that doing so is worth the effort.
|
||||
var backgroundColor = null;
|
||||
try {
|
||||
let { contentDocument, contentWindow } = this.browser;
|
||||
let computedStyle = contentWindow.getComputedStyle(contentDocument.body);
|
||||
backgroundColor = computedStyle.backgroundColor;
|
||||
} catch (e) {
|
||||
// Ignore. Catching and ignoring exceptions here ensures that Talos succeeds.
|
||||
}
|
||||
|
||||
let docURI = target.documentURI;
|
||||
let errorType = "";
|
||||
if (docURI.startsWith("about:certerror")) {
|
||||
|
@ -4135,7 +4123,6 @@ Tab.prototype = {
|
|||
GlobalEventDispatcher.sendRequest({
|
||||
type: "Content:DOMContentLoaded",
|
||||
tabID: this.id,
|
||||
bgColor: backgroundColor,
|
||||
errorType: errorType,
|
||||
metadata: this.metatags,
|
||||
});
|
||||
|
|
Загрузка…
Ссылка в новой задаче