Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
ckeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vanilla ckeditor-3.0.2
[ckeditor.git]
/
_source
/
plugins
/
menu
/
plugin.js
diff --git
a/_source/plugins/menu/plugin.js
b/_source/plugins/menu/plugin.js
index
f65d5db
..
7921fee
100644
(file)
--- a/
_source/plugins/menu/plugin.js
+++ b/
_source/plugins/menu/plugin.js
@@
-67,11
+67,11
@@
CKEDITOR.tools.extend( CKEDITOR.editor.prototype,
{
\r
var menu = this._.subMenu,
\r
item = this.items[ index ],
\r
{
\r
var menu = this._.subMenu,
\r
item = this.items[ index ],
\r
- subItems = item.getItems && item.getItems();
\r
+ subItemDefs = item.getItems && item.getItems();
\r
\r
// If this item has no subitems, we just hide the submenu, if
\r
// available, and return back.
\r
\r
// If this item has no subitems, we just hide the submenu, if
\r
// available, and return back.
\r
- if ( !subItems )
\r
+ if ( !subItemDefs )
\r
{
\r
this._.panel.hideChild();
\r
return;
\r
{
\r
this._.panel.hideChild();
\r
return;
\r
@@
-89,9
+89,14
@@
CKEDITOR.tools.extend( CKEDITOR.editor.prototype,
}
\r
\r
// Add all submenu items to the menu.
\r
}
\r
\r
// Add all submenu items to the menu.
\r
- for ( var itemName in subItems )
\r
+ for ( var subItemName in subItemDefs )
\r
{
\r
{
\r
- menu.add( this.editor.getMenuItem( itemName ) );
\r
+ var subItem = this.editor.getMenuItem( subItemName );
\r
+ if ( subItem )
\r
+ {
\r
+ subItem.state = subItemDefs[ subItemName ];
\r
+ menu.add( subItem );
\r
+ }
\r
}
\r
\r
// Get the element representing the current item.
\r
}
\r
\r
// Get the element representing the current item.
\r