setting textbox.oninput has no effect

RESOLVED WORKSFORME

Status

()

defect
RESOLVED WORKSFORME
17 years ago
3 months ago

People

(Reporter: jruderman, Unassigned)

Tracking

Trunk
x86
All
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Reporter

Description

17 years ago
Setting textbox.oninput in a script has no effect.  Using
addEventListener("input", ...) instead makes it work.  It works fine with
onchange, so I'm guessing this isn't intentional.
Reporter

Comment 1

17 years ago
Posted file testcase
Reporter

Updated

14 years ago
Assignee: saari → events
QA Contact: desale → ian

Comment 2

13 years ago
This also happens is XUL Runner 1.8.0.4 on OS X.
Assignee: events → nobody
QA Contact: ian → events

Comment 3

10 years ago
This is still an issue. Webkit has been receiving a lot of work on the 'input' event lately. Fixing this would help match Opera and Safari's support.
OS: Windows XP → All
I wonder how complicated it would be to fix this and if it can be done before final release? 

Another consequence of this issue (as I suspect) is that it's impossible to detect support for "input" event, using good old `setAttribute` check:

var el = document.createElement('input');
el.setAttribute('oninput', '');
'oninput' in el; // false

Note that detecting something like "change" event (as well as plethora of others) works just fine using this approach.

Comment 5

9 years ago
Looks like this extends to the newly added invalid event from the contraint validation API also. 

Using the setAttribute check as Juriy mentions above returns a false negative in FF4 beta5.

Comment 6

8 years ago
Perhaps I'm misusing the test case, but this seems to work fine in Firefox 6.

All three boxes behave the same. Whatever I type in a box is immediately visible in the "oninput" box, and shows in "onchange" when I tab out of it.

Shall I close this?
Things seem to be working fine for me now too in "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:9.0a1) Gecko/20110902 Firefox/9.0a1".

Comment 8

8 years ago
"worksforme" because the exact revision that fixed this is uncertain.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WORKSFORME
Component: Event Handling → User events and focus handling
You need to log in before you can comment on or make changes to this bug.