File tree Expand file tree Collapse file tree 2 files changed +11
-3
lines changed
Expand file tree Collapse file tree 2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -384,7 +384,11 @@ define(
384384 this . states [ state ] = 1 ;
385385 helper . addStateClasses ( this , state ) ;
386386 var properties = { } ;
387- properties [ state ] = true ;
387+ var statePropertyName = state . replace (
388+ / - ( \w ) / ,
389+ function ( m , c ) { return c . toUpperCase ( ) ; }
390+ ) ;
391+ properties [ statePropertyName ] = true ;
388392 this . setProperties ( properties ) ;
389393 }
390394 } ,
@@ -399,7 +403,11 @@ define(
399403 delete this . states [ state ] ;
400404 helper . removeStateClasses ( this , state ) ;
401405 var properties = { } ;
402- properties [ state ] = false ;
406+ var statePropertyName = state . replace (
407+ / - ( \w ) / ,
408+ function ( m , c ) { return c . toUpperCase ( ) ; }
409+ ) ;
410+ properties [ statePropertyName ] = false ;
403411 this . setProperties ( properties ) ;
404412 }
405413 } ,
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ define(
7373 * @type {Array.<string> }
7474 * @protected
7575 */
76- ignoreStates : Control . prototype . ignoreStates . concat ( 'readOnly ' ) ,
76+ ignoreStates : Control . prototype . ignoreStates . concat ( 'read-only ' ) ,
7777
7878 /**
7979 * 获得应当获取焦点的元素
You can’t perform that action at this time.
0 commit comments