Ticket #5345: 5345_2.patch
File 5345_2.patch, 2.6 KB (added by , 14 years ago) |
---|
-
_source/plugins/elementspath/plugin.js
33 33 34 34 init : function( editor ) 35 35 { 36 var config = editor.config, 37 pathFilters = config.elementsPath_filters; 38 39 config.elementsPath_filters = pathFilters instanceof Array ? pathFilters : 40 typeof pathFilters == 'function' ? [ pathFilters ] : []; 41 36 42 var spaceId = 'cke_path_' + editor.name; 37 43 var spaceElement; 38 44 var getSpaceElement = function() … … 206 212 207 213 /** 208 214 * A list of filter functions to determinate whether an element should display in elements path bar. 215 * @name CKEDITOR.config.elementsPath_filters 209 216 * @type Array Array of functions that optionaly return 'false' to prevent the element from displaying. 210 217 * @default [] 211 218 * @example … … 216 223 * return false; 217 224 * }); 218 225 */ 219 CKEDITOR.config.elementsPath_filters = []; -
_source/core/editor.js
230 230 // Load all plugin specific language files in a row. 231 231 CKEDITOR.scriptLoader.load( languageFiles, function() 232 232 { 233 // Add-in all other config options that been defined on CKEDITOR in plugin files. 234 // TODO: Remove this line when we're free of global config definition in all plugins. 235 CKEDITOR.tools.extend( editor.config, CKEDITOR.tools.clone( CKEDITOR.config ) ); 236 233 237 // Initialize all plugins that have the "beforeInit" and "init" methods defined. 234 238 var methods = [ 'beforeInit', 'init', 'afterInit' ]; 235 239 for ( var m = 0 ; m < methods.length ; m++ ) … … 390 394 * var editor = CKEDITOR.instances.editor1; 391 395 * alert( <b>editor.config.theme</b> ); "default" e.g. 392 396 */ 393 this.config = CKEDITOR.tools. prototypedCopy( CKEDITOR.config );397 this.config = CKEDITOR.tools.clone( CKEDITOR.config ); 394 398 395 399 /** 396 400 * Namespace containing UI features related to this editor instance. … … 505 509 if ( this._.filebrowserFn ) 506 510 CKEDITOR.tools.removeFunction( this._.filebrowserFn ); 507 511 508 items = editor.config.elementsPath_filters;509 if ( items )510 {511 for ( index= 0 ; index < items.length ; index++ )512 items[ index ] = null;513 }514 515 512 this.fire( 'destroy' ); 516 513 CKEDITOR.remove( this ); 517 514 CKEDITOR.fire( 'instanceDestroyed', null, this );