Changeset 3048
- Timestamp:
- 02/11/09 14:41:52 (4 years ago)
- Location:
- CKEditor/trunk
- Files:
-
- 8 edited
-
_samples/api_dialog.html (modified) (1 diff)
-
_source/core/config.js (modified) (1 diff)
-
_source/core/dom/element.js (modified) (1 diff)
-
_source/core/htmlparser/element.js (modified) (2 diffs)
-
_source/plugins/dialogui/plugin.js (modified) (1 diff)
-
_source/plugins/fakeobjects/plugin.js (modified) (1 diff)
-
_source/plugins/pagebreak/plugin.js (modified) (2 diffs)
-
_source/plugins/toolbar/plugin.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
CKEditor/trunk/_samples/api_dialog.html
r3020 r3048 57 57 // Remove the "Link Type" combo and the "Browser 58 58 // Server" button from the "info" tab. 59 infoTab.remove( ' protocol' );59 infoTab.remove( 'linkType' ); 60 60 infoTab.remove( 'browse' ); 61 61 -
CKEditor/trunk/_source/core/config.js
r3047 r3048 147 147 * config.plugins = 'basicstyles,button,htmldataprocessor,toolbar,wysiwygarea'; 148 148 */ 149 plugins : 'basicstyles,button,elementspath,horizontalrule,htmldataprocessor,keystrokes,newpage,pagebreak,removeformat,smiley, sourcearea,table,specialchar,tab,toolbar,wysiwygarea',149 plugins : 'basicstyles,button,elementspath,horizontalrule,htmldataprocessor,keystrokes,newpage,pagebreak,removeformat,smiley,link,sourcearea,table,specialchar,tab,toolbar,wysiwygarea', 150 150 151 151 /** -
CKEditor/trunk/_source/core/dom/element.js
r3047 r3048 686 686 }, 687 687 688 copyAttributes : function( target, skip ) 689 { 690 skip || ( skip = {} ); 691 var attributes = this.$.attributes ; 692 693 for ( var n = 0 ; n < attributes.length ; n++ ) 694 { 695 var attr = attributes[n] ; 696 697 if ( attr.specified ) 698 { 699 var attrName = attr.nodeName ; 700 if ( attrName in skip ) 701 continue ; 702 703 var attrValue = this.getAttribute( attrName ); 704 if ( !attrValue ) 705 attrValue = attr.nodeValue ; 706 707 target.setAttribute( attrName, attrValue ); 708 } 709 } 710 711 if ( this.$.style.cssText !== '' ) 712 target.$.style.cssText = this.$.style.cssText ; 713 }, 714 688 715 /** 689 716 * Shows this element (display it). -
CKEditor/trunk/_source/core/htmlparser/element.js
r3043 r3048 67 67 }; 68 68 69 var ckeAttrRegex = /^_cke/, 70 ckeClassRegex = /(^|\s+)cke_[^\s]*/g; 71 69 72 CKEDITOR.htmlParser.element.prototype = 70 73 { … … 131 134 { 132 135 // Ignore all attributes starting with "_cke". 133 if ( !/^_cke/.test( a ) ) 134 attribsArray.push( [ a, this.attributes[ a ] ] ); 136 if ( ckeAttrRegex.test( a ) ) 137 continue; 138 139 // Ignore all cke_* CSS classes. 140 if ( a.toLowerCase() == 'class' ) 141 { 142 this.attributes[ a ] = CKEDITOR.tools.ltrim( this.attributes[ a ].replace( ckeClassRegex, '' ) ); 143 if ( this.attributes[ a ] == '' ) 144 continue; 145 } 146 147 attribsArray.push( [ a, this.attributes[ a ] ] ); 135 148 } 136 149 -
CKEditor/trunk/_source/plugins/dialogui/plugin.js
r3044 r3048 884 884 { 885 885 this.select(); 886 }, 887 888 /** 889 * Sets the value of this text input object. 890 * @param {Object} value The new value. 891 * @returns {CKEDITOR.ui.dialog.textInput} The current UI element. 892 * @example 893 * uiElement.setValue( 'Blamo' ); 894 */ 895 setValue : function( value ) 896 { 897 value = value || ''; 898 return CKEDITOR.ui.dialog.uiElement.prototype.setValue.call( this, value ); 886 899 } 887 900 }, commonPrototype, true ); -
CKEditor/trunk/_source/plugins/fakeobjects/plugin.js
r3043 r3048 6 6 CKEDITOR.plugins.add( 'fakeobjects' ); 7 7 8 CKEDITOR.editor.prototype.createFakeElement = function( realElement, className )8 CKEDITOR.editor.prototype.createFakeElement = function( realElement, className, realElementType ) 9 9 { 10 return this.document.createElement( 'img', 11 { 12 attributes : 13 { 14 'class' : className, 15 src : CKEDITOR.getUrl( 'images/spacer.gif' ), 16 _cke_realelement : encodeURIComponent( realElement.getOuterHtml() ) 17 } 18 }); 10 var attributes = 11 { 12 'class' : className, 13 src : CKEDITOR.getUrl( 'images/spacer.gif' ), 14 _cke_realelement : encodeURIComponent( realElement.getOuterHtml() ) 15 }; 16 if ( realElementType ) 17 attributes._cke_real_element_type = realElementType; 18 19 return this.document.createElement( 'img', { attributes : attributes } ); 19 20 }; 21 22 CKEDITOR.editor.prototype.restoreRealElement = function( fakeElement ) 23 { 24 var html = decodeURIComponent( fakeElement.getAttribute( '_cke_realelement' ) ), 25 realElement = CKEDITOR.dom.element.createFromHtml( html, this.document ); 26 27 if ( fakeElement.$.style.width ) 28 realElement.setStyle( 'width', fakeElement.$.style.width ); 29 if ( fakeElement.$.style.height ) 30 realElement.setStyle( 'height', fakeElement.$.style.height ); 31 32 return realElement; 33 }; -
CKEditor/trunk/_source/plugins/pagebreak/plugin.js
r3043 r3048 50 50 if ( div.getStyle( 'page-break-after' ) == 'always' && !/[^\s\u00A0]/.test( div.getText() ) ) 51 51 { 52 editor.createFakeElement( div, 'cke_pagebreak' ).replace( div );52 editor.createFakeElement( div, 'cke_pagebreak', 'div' ).replace( div ); 53 53 } 54 54 } … … 66 66 67 67 // Creates the fake image used for this element. 68 breakObject = editor.createFakeElement( breakObject, 'cke_pagebreak' );68 breakObject = editor.createFakeElement( breakObject, 'cke_pagebreak', 'div' ); 69 69 70 70 var ranges = editor.getSelection().getRanges(); -
CKEditor/trunk/_source/plugins/toolbar/plugin.js
r3047 r3048 212 212 'Subscript', 'Superscript', '-', 213 213 'SelectAll', 'RemoveFormat', '-', 214 'Link', 'Unlink', 'Anchor', '-', 214 215 'Table', 'Smiley', 'HorizontalRule', 'SpecialChar', 'PageBreak' 215 216 ]
Note: See TracChangeset
for help on using the changeset viewer.
