Closed Bug 570969 Opened 15 years ago Closed 15 years ago

[f10s] Remove isRootWindow and use currentInnerWindowId instead

Categories

(Firefox for Android Graveyard :: General, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: vingtetun, Assigned: vingtetun)

Details

Attachments

(1 file, 1 obsolete file)

Attached patch Patch (obsolete) — Splinter Review
No description provided.
Attachment #450120 - Flags: review?(mark.finkle)
btw I don't really like: + windowId: aWebProgress.DOMWindow.QueryInterface(Ci.nsIInterfaceRequestor).getInterface(Ci.nsIDOMWindowUtils).currentInnerWindowID, so if you have a better idea it would be nice!
Comment on attachment 450120 [details] [diff] [review] Patch >diff -r d0c2030cc255 chrome/content/bindings/browser.js Change all sendAsyncMessage calls to sendSyncMessage in this file. >diff -r d0c2030cc255 chrome/content/bindings/browser.xml >+ <field name="currentInnerWindowId">null</field> >+ Let's just call it contentWindowId > <field name="_webProgress"><![CDATA[ >+ get DOMWindow() { throw "DOMWindow: Not Remoteable" }, >+ isLoadingDocument: false, Change to: get isLoadingDocument() { throw "isLoadingDocument: Not Remoteable"; }, Change in remote-browser too > case "WebProgress:LocationChange": >- if (json.isRootWindow) { >+ let currentURI = this._browser._ios.newURI(json.location, null, null); >+ >+ args = [ >+ { windowId: json.windowId, browser: this._browser }, >+ {}, >+ currentURI >+ ]; Not sure why, but I like using "locationURI" instead of "currentURI". Change in remote-browser too > ]]></field> You added back _webProgress, but also add back the "webProgress" property. I don't want people to use browser._webProgress >diff -r d0c2030cc255 chrome/content/browser.js > onStateChange: function onStateChange(aWebProgress, aRequest, aStateFlags, aStatus) { > // ignore notification that aren't about the main document (iframes, etc) >- if (aWebProgress.DOMWindow != this._tab.browser.contentWindow) >+ if (aWebProgress.windowId != this._tab.browser.currentInnerWindowId) Change to this._tab.browser.contentWindowId > onLocationChange: function onLocationChange(aWebProgress, aRequest, aLocationURI) { > // ignore notification that aren't about the main document (iframes, etc) >- if (aWebProgress.DOMWindow != this._tab.browser.contentWindow) >+ if (aWebProgress.windowId != this._tab.browser.currentInnerWindowId) Change to this._tab.browser.contentWindowId > this._listener = new ProgressController(this); >- browser.webProgress.addProgressListener(this._listener, flags); >+ browser._webProgress.addProgressListener(this._listener, flags); No, leave this alone.
Attachment #450120 - Flags: review?(mark.finkle) → review-
Attached patch Patch v0.2Splinter Review
This patch address comments and also correct a little bug found during debugging
Assignee: nobody → 21
Attachment #450120 - Attachment is obsolete: true
Attachment #450134 - Flags: review?(mark.finkle)
Comment on attachment 450134 [details] [diff] [review] Patch v0.2 But we still fail tests without changing sendAsyncMessage to sendSyncMessage in bindings/browser.js. r+ with that change. we can figure out why async is failing in a followup.
Attachment #450134 - Flags: review?(mark.finkle) → review+
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: