I was using
http://extjs.com/deploy/dev/examples...le-upload.html
as an example and I randomly found a bug in
http://extjs.com/deploy/dev/examples...UploadField.js
If you select a file, hit reset, then select that same file, it doesn't appear in the form field. After a bit of searching around, I realize the underlying "input type=file" form element wasn't being reset. Since it wasn't reset, when you pick the same file again, the 'onChange' event wasn't being triggered since it was the same!
My fix for it:
Code:
// must reset the actual form in order to properly function
// This fixes the bug: select file, reset, select same file
reset : function() {
Ext.get(this.getFileInputId()).findParentNode("form").reset();
Ext.form.FileUploadField.superclass.reset.call(this);
},
I wasn't sure any other way to find the parent form since the object itself is just the field.