Permalink
Browse files

Checkboxradio: Theme inheritance via CSS. Don't add btn theme class u…

…nless it a theme has been set.
  • Loading branch information...
jaspermdegroot committed May 14, 2013
1 parent 3650c85 commit cac84d1bb75c30e3bc2c46397447f3123e53e02b
Showing with 3 additions and 5 deletions.
  1. +3 −5 js/widgets/forms/checkboxradio.js
@@ -46,10 +46,6 @@ $.widget( "mobile.checkboxradio", $.mobile.widget, $.extend( {
}
// Establish options
// If there's no selected theme check the data attr
if ( !o.theme ) {
o.theme = "a";
}
o.mini = inheritAttr( input, "mini" ) || o.mini;
// Expose for other methods
@@ -201,7 +197,9 @@ $.widget( "mobile.checkboxradio", $.mobile.widget, $.extend( {
},
_setTheme: function( value ) {
this.label.removeClass( "ui-btn-" + this.options.theme ).addClass( "ui-btn-" + value );
if ( value ) {
this.label.removeClass( "ui-btn-" + this.options.theme ).addClass( "ui-btn-" + value );
}
},
_setMini: function( value ) {

0 comments on commit cac84d1

Please sign in to comment.