X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_source%2Fplugins%2Frichcombo%2Fplugin.js;h=76523bc1ca692037567fa06fd52535ff8d89f5b5;hp=bcc5777bf28254ac34d52c6a4ba5e798ab3db206;hb=614511639979907ceb0da3614122a4d8eb963ad4;hpb=039a051ccf3901311661022a30afd60fc38130c9 diff --git a/_source/plugins/richcombo/plugin.js b/_source/plugins/richcombo/plugin.js index bcc5777..76523bc 100644 --- a/_source/plugins/richcombo/plugin.js +++ b/_source/plugins/richcombo/plugin.js @@ -106,11 +106,7 @@ CKEDITOR.ui.richCombo = CKEDITOR.tools.createClass( return; } - if ( !_.committed ) - { - _.list.commit(); - _.committed = 1; - } + !_.committed && this.commit(); var value = this.getValue(); if ( value ) @@ -244,7 +240,7 @@ CKEDITOR.ui.richCombo = CKEDITOR.tools.createClass( if ( me.className ) this.element.getFirst().removeClass( me.className + '_panel' ); - me.setState( CKEDITOR.TRISTATE_OFF ); + me.setState( me.modes && me.modes[ editor.mode ] ? CKEDITOR.TRISTATE_OFF : CKEDITOR.TRISTATE_DISABLED ); me._.on = 0; @@ -350,6 +346,7 @@ CKEDITOR.ui.richCombo = CKEDITOR.tools.createClass( commit : function() { this._.list.commit(); + this._.committed = 1; }, setState : function( state )