Commit 920567ed authored by Akikonata's avatar Akikonata

fixed bug

parent f76a3351
......@@ -8,7 +8,8 @@ KM.registerToolbarUI( 'layout', function ( name ) {
items: me.getLayoutStyleItems() || [],
itemStyles: [],
value: me.getLayoutStyleItems(),
autowidthitem: []
autowidthitem: [],
enabledRecord: false
},
$combox = null;
if ( options.items.length == 0 ) {
......
......@@ -24,6 +24,7 @@ KM.registerToolbarUI( 'saveto', function ( name ) {
options.autowidthitem.push( $.wordCountAdaptive( text ), true );
} );
//实例化
$combox = $.kmuibuttoncombobox( options ).css( 'zIndex', me.getOptions( 'zIndex' ) + 1 );
comboboxWidget = $combox.kmui();
......@@ -39,15 +40,8 @@ KM.registerToolbarUI( 'saveto', function ( name ) {
if ( $combox.parent().length === 0 ) {
$combox.appendTo( me.$container.find( '.kmui-dialog-container' ) );
}
var combox = $combox.kmui();
combox.traverseItems( function ( label, value ) {
if ( me.queryCommandState( value ) == -1 ) {
combox.disableItemByLabel( label )
} else {
combox.enableItemByLabel( label )
}
} )
} ).on( 'aftercomboboxselect', function () {
this.setLabelWithDefaultValue();
} );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment