Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

ensure change event is still fired

  • Loading branch information...
commit 888d8f480bfc557614ccf31e98e2fb2192be555d 1 parent 62c426d
@bronson authored
Showing with 7 additions and 2 deletions.
  1. +7 −2 jquery.miniColors.js
View
9 jquery.miniColors.js
@@ -180,7 +180,8 @@ if(jQuery) (function($) {
input.data('huePicker', selector.find('.miniColors-huePicker'));
input.data('colorPicker', selector.find('.miniColors-colorPicker'));
input.data('mousebutton', 0);
-
+ var oldValue = input.val();
+
$('BODY').append(selector);
selector.fadeIn(100);
@@ -208,7 +209,11 @@ if(jQuery) (function($) {
}
if( $(event.target).parents().andSelf().hasClass('miniColors') ) return;
-
+
+ if(input.val() != oldValue) {
+ input.trigger('change');
+ }
+
hide(input);
});
Please sign in to comment.
Something went wrong with that request. Please try again.