mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 746380 - Use URI of nsIChannel on state change. r=mfinkle a=blocking-fennec
This commit is contained in:
parent
c1ed652b3c
commit
28356cfc3e
@ -2044,11 +2044,6 @@ Tab.prototype = {
|
||||
return;
|
||||
}
|
||||
|
||||
let browser = BrowserApp.getBrowserForWindow(aWebProgress.DOMWindow);
|
||||
let uri = "";
|
||||
if (browser)
|
||||
uri = browser.currentURI.spec;
|
||||
|
||||
// Check to see if we restoring the content from a previous presentation (session)
|
||||
// since there should be no real network activity
|
||||
let restoring = aStateFlags & Ci.nsIWebProgressListener.STATE_RESTORING;
|
||||
@ -2056,6 +2051,10 @@ Tab.prototype = {
|
||||
|
||||
// true if the page loaded successfully (i.e., no 404s or other errors)
|
||||
let success = false;
|
||||
let uri = "";
|
||||
try {
|
||||
uri = aRequest.QueryInterface(Components.interfaces.nsIChannel).originalURI.spec;
|
||||
} catch (e) { }
|
||||
try {
|
||||
success = aRequest.QueryInterface(Components.interfaces.nsIHttpChannel).requestSucceeded;
|
||||
} catch (e) { }
|
||||
|
Loading…
Reference in New Issue
Block a user