X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=_source%2Fthemes%2Fdefault%2Ftheme.js;h=960ee0b507ccf4c0f43d8ef0ecb4e70581584e79;hb=48b1db88210b4160dce439c6e3e32e14af8c106b;hp=96ff928b48067e0fe83d71e2aae8bc6a64233679;hpb=941b0a9ba4e673e292510d80a5a86806994b8ea6;p=ckeditor.git diff --git a/_source/themes/default/theme.js b/_source/themes/default/theme.js index 96ff928..960ee0b 100644 --- a/_source/themes/default/theme.js +++ b/_source/themes/default/theme.js @@ -1,8 +1,13 @@ /* -Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved. +Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ +/** + * @name CKEDITOR.theme + * @class + */ + CKEDITOR.themes.add( 'default', (function() { function checkSharedSpace( editor, spaceName ) @@ -21,8 +26,10 @@ CKEDITOR.themes.add( 'default', (function() { // Creates an HTML structure that reproduces the editor class hierarchy. var html = - '' + - '' + + '' + + '' + '' + '' + '' + @@ -40,6 +47,10 @@ CKEDITOR.themes.add( 'default', (function() // Get the deeper inner
. container = mainContainer.getChild( [0,0,0,0] ); + // Save a reference to the shared space container. + !editor.sharedSpaces && ( editor.sharedSpaces = {} ); + editor.sharedSpaces[ spaceName ] = container; + // When the editor gets focus, we show the space container, hiding others. editor.on( 'focus', function() { @@ -65,7 +76,7 @@ CKEDITOR.themes.add( 'default', (function() return container; } - return { + return /** @lends CKEDITOR.theme */ { build : function( editor, themePath ) { var name = editor.name, @@ -113,20 +124,22 @@ CKEDITOR.themes.add( 'default', (function() var container = CKEDITOR.dom.element.createFromHtml( [ '' + - '' + - '' + - '' + - '' + - '' + - '' + + '' + editor.lang.editor + '' + + '' + + '' + + '
' , topHtml , '
', contentsHtml, '
' , bottomHtml , '
' + + '' + + '' + + '' + '' + //Hide the container when loading skins, later restored by skin css. '' + @@ -134,8 +147,8 @@ CKEDITOR.themes.add( 'default', (function() '
' + '
' ].join( '' ) ); - container.getChild( [0, 0, 0, 0, 0] ).unselectable(); - container.getChild( [0, 0, 0, 0, 2] ).unselectable(); + container.getChild( [1, 0, 0, 0, 0] ).unselectable(); + container.getChild( [1, 0, 0, 0, 2] ).unselectable(); if ( elementMode == CKEDITOR.ELEMENT_MODE_REPLACE ) container.insertAfter( element ); @@ -164,23 +177,27 @@ CKEDITOR.themes.add( 'default', (function() var baseIdNumber = CKEDITOR.tools.getNextNumber(); var element = CKEDITOR.dom.element.createFromHtml( [ - '