Index: /CKEditor/branches/versions/3.5.x/CHANGES.html =================================================================== --- /CKEditor/branches/versions/3.5.x/CHANGES.html (revision 6144) +++ /CKEditor/branches/versions/3.5.x/CHANGES.html (revision 6145) @@ -48,4 +48,5 @@
Index: /CKEditor/branches/versions/3.5.x/_source/plugins/dialog/plugin.js =================================================================== --- /CKEditor/branches/versions/3.5.x/_source/plugins/dialog/plugin.js (revision 6144) +++ /CKEditor/branches/versions/3.5.x/_source/plugins/dialog/plugin.js (revision 6145) @@ -189,4 +189,32 @@ } , editor ).definition; + + var tabsToRemove = {}; + // Cache tabs that should be removed. + if ( !( 'removeDialogContents' in editor._ ) && editor.config.removeDialogContents ) + { + var removeContents = editor.config.removeDialogContents.split( ';' ); + + for ( i = 0; i < removeContents.length; i++ ) + { + var parts = removeContents[ i ].split( ':' ); + if ( parts.length == 2 ) + { + var removeDialogName = parts[ 0 ]; + if ( !tabsToRemove[ removeDialogName ] ) + tabsToRemove[ removeDialogName ] = []; + tabsToRemove[ removeDialogName ].push( parts[ 1 ] ); + } + } + editor._.removeDialogContents = tabsToRemove; + } + + // Remove tabs of this dialog. + if ( editor._.removeDialogContents && ( tabsToRemove = editor._.removeDialogContents[ dialogName ] ) ) + { + for ( i = 0; i < tabsToRemove.length; i++ ) + definition.removeContents( tabsToRemove[ i ] ); + } + // Initialize load, show, hide, ok and cancel events. if ( definition.onLoad ) @@ -3011,5 +3039,18 @@ * @example * config.dialog_buttonsOrder = 'rtl'; -*/ + */ + +/** + * The dialog contents to removed. It's a string composed by dialog name and tab name with a colon between them. + * Separate each pair with semicolon (see example). + * Note: All names are case-sensitive. + * Note: Be cautious when specifying dialog tabs that are mandatory, like "info", dialog functionality might be broken because of this! + * @name CKEDITOR.config.removeDialogContents + * @type String + * @since 3.5 + * @default '' + * @example + * config.removeDialogContents = 'flash:advanced;Image:Link'; + */ /**