Browse Source

removed label drag listener when mouse leave is fired

Emanuele Marchi 11 years ago
parent
commit
6827b0e27d

+ 5 - 0
build/js/bootstrap-switch.js

@@ -377,6 +377,11 @@
               }
             };
           })(this),
+          "mouseleave.bootstrapSwitch": (function(_this) {
+            return function(e) {
+              return _this.$label.trigger("mouseup.bootstrapSwitch");
+            };
+          })(this),
           "click.bootstrapSwitch": (function(_this) {
             return function(e) {
               e.preventDefault();

File diff suppressed because it is too large
+ 0 - 0
build/js/bootstrap-switch.min.js


+ 3 - 0
src/coffee/bootstrap-switch.coffee

@@ -275,6 +275,9 @@
           @$div.css "margin-left", ""
           @$wrapper.addClass "#{@name}-animate" if @options.animate
 
+        "mouseleave.bootstrapSwitch": (e) =>
+          @$label.trigger "mouseup.bootstrapSwitch"
+
         "click.bootstrapSwitch": (e) =>
           e.preventDefault()
           e.stopImmediatePropagation()

Some files were not shown because too many files changed in this diff