Forráskód Böngészése

fixed missing container resize on handleWidth and labelWidth programmatic call

Emanuele Marchi 10 éve
szülő
commit
01ba92b351

+ 2 - 0
dist/js/bootstrap-switch.js

@@ -342,6 +342,7 @@
         }
         this.options.handleWidth = value;
         this._width();
+        this._containerPosition();
         return this.$element;
       };
 
@@ -351,6 +352,7 @@
         }
         this.options.labelWidth = value;
         this._width();
+        this._containerPosition();
         return this.$element;
       };
 

A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/js/bootstrap-switch.min.js


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

@@ -259,6 +259,7 @@ do ($ = window.jQuery, window) ->
 
       @options.handleWidth = value
       @_width()
+      @_containerPosition()
       @$element
 
     labelWidth: (value) ->
@@ -266,6 +267,7 @@ do ($ = window.jQuery, window) ->
 
       @options.labelWidth = value
       @_width()
+      @_containerPosition()
       @$element
 
     baseClass: (value) ->

+ 2 - 0
test/bootstrap-switch.js

@@ -342,6 +342,7 @@
         }
         this.options.handleWidth = value;
         this._width();
+        this._containerPosition();
         return this.$element;
       };
 
@@ -351,6 +352,7 @@
         }
         this.options.labelWidth = value;
         this._width();
+        this._containerPosition();
         return this.$element;
       };
 

Nem az összes módosított fájl került megjelenítésre, mert túl sok fájl változott