completely icon indicating copy to clipboard operation
completely copied to clipboard

Select & clear text doesn't fire onChange event

Open mattpass opened this issue 12 years ago • 3 comments

If you setText('xyz'), then highlight the text and hit delete or backspace keys it doesn't fire the onChange event.

mattpass avatar Nov 22 '13 17:11 mattpass

Matt, are you sure ? I tried to recreate it and I could not do that. I have written a js fiddle http://jsfiddle.net/NpeMN/ , can you modify the fiddle to make your case ?

lorenzoongithub avatar Nov 22 '13 22:11 lorenzoongithub

Tried your fiddle and same result (in IE10 plus Chrome and Firefox, both latest).

To this this: view your fiddle, select text and hit Delete or Backspace to clear it, onChange doesn't fire.

In essence, clearing initial text doesn't fire the event - but note that it's only regarding initial text. If you retype 'apple' as 'pear' and clear pear it fires on onchange event. However, clearing the initial 'apple' text doesn't.

mattpass avatar Nov 23 '13 11:11 mattpass

@mattpass I think you might have a point here. I will have to take a look

lorenzoongithub avatar Nov 25 '13 21:11 lorenzoongithub