Closed Bug 663345 Opened 13 years ago Closed 13 years ago

Add onLocationChange2 to web progress listeners (port applicable parts of bug 311007)

Categories

(SeaMonkey :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX
seamonkey2.4

People

(Reporter: philip.chee, Assigned: philip.chee)

References

Details

Attachments

(1 file, 1 obsolete file)

From Firefox Bug 311007 Add onLocationChange2 which distinguishes between same-document and different-document location changes to web progress listeners.

We are now getting the following errors on trunk:

Error: 'JavaScript component does not have a method named: "onLocationChange2"' when calling method: [nsIWebProgressListener2::onLocationChange2] = NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED
Source file: jar:file:///C:/T1/hg/objdir-sm/mozilla/dist/seamonkey/omni.jar!/components/nsSessionStore.js
Line: 2503
 ----------
Error: 'JavaScript component does not have a method named: "onLocationChange2"' when calling method: [nsIWebProgressListener2::onLocationChange2] = NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED
Source file: jar:file:///C:/T1/hg/objdir-sm/mozilla/dist/seamonkey/omni.jar!/components/nsSessionStore.js
Line: 2668
 ----------
Error: 'JavaScript component does not have a method named: "onLocationChange2"' when calling method: [nsIWebProgressListener2::onLocationChange2] = NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED
Source file: chrome://global/content/bindings/browser.xml
Attached patch Patch v1.0 Proposed fix. (obsolete) — Splinter Review
> +++ b/suite/common/downloads/uploadProgress.js
I haven't tested this bit because I don't have a FTP server to upload to.
Attachment #538474 - Flags: review?(neil)
(In reply to comment #1)
> I haven't tested this bit because I don't have a FTP server to upload to.
Web browser persist doesn't send location changes anyway, only state, progress and status changes.
Comment on attachment 538474 [details] [diff] [review]
Patch v1.0 Proposed fix.

Would you mind changing this the other way around i.e. rename the existing location change handlers and put in dummy forwards for the old names?
Attachment #538474 - Flags: review?(neil) → review-
> Would you mind changing this the other way around i.e. rename the existing 
> location change handlers and put in dummy forwards for the old names?
Fixed.
Attachment #538474 - Attachment is obsolete: true
Attachment #538552 - Flags: superreview?(neil)
Attachment #538552 - Flags: review?(neil)
I haven't checked whether they are actually cases that need to be adapted... What about browser/nsBrowserStatusHandler.js, mailnews/compose/MsgComposeCommands.js and common/bindings/notification.xml?
Summary: Add onLocationChange2 to web progress listeners. → Add onLocationChange2 to web progress listeners (port applicable parts of bug 311007)
Well the first cut I did was to filter only for code that implements nsIWebProgressListener2 and my patches include notification.xml
Attachment #538552 - Flags: superreview?(neil)
Attachment #538552 - Flags: superreview+
Attachment #538552 - Flags: review?(neil)
Attachment #538552 - Flags: review+
hrm newsgroups indicate this may be causing updates not to work.

Can we get that fixed next?
Pushe to comm-central
http://hg.mozilla.org/comm-central/rev/2b1706a6c9f1
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.4
Needs to be backed out now that the relevant patch from Bug 311007 has been backed out.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Patchset backed out:
http://hg.mozilla.org/comm-central/rev/eca67f146803
Status: REOPENED → RESOLVED
Closed: 13 years ago13 years ago
Depends on: 311007
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: