isTrusted undefined on new hashchange event

RESOLVED FIXED

Status

()

Core
Document Navigation
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: John P Baker, Assigned: Justin Lebar (not reading bugmail))

Tracking

({regression})

Trunk
regression
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

6 years ago
My addon contains the following code

handleEvent : function bug420605_handleEvent(aEvent) {
    switch (aEvent.type) {

...

      case "hashchange":
        if (aEvent.isTrusted)
          this.onHashChange(aEvent);
        break;

...

aEvent.isTrusted is now undefined here.

bz in bug 628069 comment #19 replied:
> Hmm.  The classinfo for the new event doesn't include nsIDOMNSEvent.  That's
> true for popstate as well, looks like.

> John, can you please file a followup
> bug on that?
tracking-firefox6: --- → ?
Keywords: regression
(Assignee)

Comment 1

6 years ago
Created attachment 528898 [details] [diff] [review]
Patch v1

I think popstate is fine, because it has DOM_CLASSINFO_EVENT_MAP_ENTRIES.  The
hashchange event had DOM_CLASSINFO_DOCUMENT_MAP_ENTRIES, which was problematic.

Anyway, I added tests for both popstate and hashchange.
Attachment #528898 - Flags: review?(bzbarsky)
Comment on attachment 528898 [details] [diff] [review]
Patch v1

Why the changes to dom/tests/mochitest/bugs/Makefile.in ?
(Assignee)

Comment 3

6 years ago
Oops.  That was an errant hg revert --rev qparent.
(Assignee)

Comment 4

6 years ago
Created attachment 528941 [details] [diff] [review]
Patch v2

Un-removed tests, per comment 2
(Assignee)

Updated

6 years ago
Attachment #528898 - Attachment is obsolete: true
Attachment #528898 - Flags: review?(bzbarsky)
(Assignee)

Updated

6 years ago
Attachment #528941 - Flags: review?(bzbarsky)
Comment on attachment 528941 [details] [diff] [review]
Patch v2

r=me
Attachment #528941 - Flags: review?(bzbarsky) → review+
(Assignee)

Comment 6

6 years ago
http://hg.mozilla.org/mozilla-central/rev/5efc266040c7
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED

Updated

6 years ago
tracking-firefox6: ? → ---

Updated

6 years ago
Assignee: nobody → justin.lebar+bug
You need to log in before you can comment on or make changes to this bug.