Don't trigger unnecessary change events.

This commit is contained in:
Thomas Tanghus 2012-04-21 23:51:30 +02:00
parent 16fc4dfd1a
commit 56e064bd09

View file

@ -31,7 +31,9 @@
} else {
self.element.val(tmp);
}
self.element.trigger('change'); // Changes wasn't saved when only using the dropdown.
if(self.element.val().trim() != '') {
self.element.trigger('change'); // Changes wasn't saved when only using the dropdown.
}
});
this.element.bind( "keydown", function( event ) {
if ( event.keyCode === $.ui.keyCode.TAB &&