Use prop instead of attr for changing 'selected' state

Bug: 68998
Change-Id: I4f9231dde31e570e45c4af9e635d7bd9144a7db0
This commit is contained in:
Santhosh Thottingal
2014-08-25 17:13:08 +05:30
parent ccd83b1f84
commit dec7b34f1a

View File

@@ -447,7 +447,7 @@
if ( font !== 'system' ) { if ( font !== 'system' ) {
$fontOption = $( '<option>' ).attr( 'value', font ).text( font ); $fontOption = $( '<option>' ).attr( 'value', font ).text( font );
$fontSelector.append( $fontOption ); $fontSelector.append( $fontOption );
$fontOption.attr( 'selected', savedFont === font ); $fontOption.prop( 'selected', savedFont === font );
} }
} ); } );
@@ -459,7 +459,7 @@
.val( 'system' ) .val( 'system' )
.attr( 'data-i18n', 'ext-uls-webfonts-system-font' ); .attr( 'data-i18n', 'ext-uls-webfonts-system-font' );
$fontSelector.append( $systemFont ); $fontSelector.append( $systemFont );
$systemFont.attr( 'selected', savedFont === 'system' || !savedFont ); $systemFont.prop( 'selected', savedFont === 'system' || !savedFont );
// Possible ids: // Possible ids:
// uls-ui-font-selector-label // uls-ui-font-selector-label