Ticket #3564: 3564.patch
File 3564.patch, 6.4 KB (added by , 15 years ago) |
---|
-
_source/lang/en.js
647 647 copy : 'Copyright © $1. All rights reserved.' 648 648 }, 649 649 650 maximize : 'Maximize' 650 maximize : 'Maximize', 651 652 resize : 'Drag to resize' 651 653 }; -
_source/plugins/resize/plugin.js
1 /* 2 Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved. 3 For licensing, see LICENSE.html or http://ckeditor.com/license 4 */ 5 6 CKEDITOR.plugins.add( 'resize', 7 { 8 init : function( editor ) 9 { 10 var config = editor.config; 11 12 function attachResizer() 13 { 14 var bottom = editor.getThemeSpace( 'bottom' ); 15 16 // Add the resize handle. 17 var resizer = CKEDITOR.dom.element.createFromHtml( '<div class="cke_resizer"' + 18 ' title="' + CKEDITOR.tools.htmlEncode( editor.lang.resize ) + '"' + 19 '></div>' ); 20 resizer.appendTo( bottom ); 21 22 // Add event handlers to the resize handle. 23 var origin, 24 startSize, 25 container = editor.getThemeSpace( 'contents' ).getAscendant( 'table' ); 26 function dragHandler( evt ) 27 { 28 var dx = evt.data.$.screenX - origin.x; 29 var dy = evt.data.$.screenY - origin.y; 30 var internalWidth = startSize.width + dx; 31 var internalHeight = startSize.height + dy; 32 33 editor.resize( Math.max( config.resizeMinWidth, Math.min( internalWidth, config.resizeMaxWidth ) ), 34 Math.max( config.resizeMinHeight, Math.min( internalHeight, config.resizeMaxHeight ) ) ); 35 } 36 37 function dragEndHandler ( evt ) 38 { 39 CKEDITOR.document.removeListener( 'mousemove', dragHandler ); 40 CKEDITOR.document.removeListener( 'mouseup', dragEndHandler ); 41 42 if ( editor.document ) 43 { 44 editor.document.removeListener( 'mousemove', dragHandler ); 45 editor.document.removeListener( 'mouseup', dragEndHandler ); 46 } 47 } 48 49 resizer.on( 'mousedown', function( evt ) 50 { 51 startSize = { width : container.$.offsetWidth || 0, height : container.$.offsetHeight || 0 }; 52 origin = { x : evt.data.$.screenX, y : evt.data.$.screenY }; 53 54 CKEDITOR.document.on( 'mousemove', dragHandler ); 55 CKEDITOR.document.on( 'mouseup', dragEndHandler ); 56 57 if ( editor.document ) 58 { 59 editor.document.on( 'mousemove', dragHandler ); 60 editor.document.on( 'mouseup', dragEndHandler ); 61 } 62 } ); 63 64 } 65 66 if ( config.resizeEnabled ) 67 editor.on( 'themeLoaded', attachResizer ); 68 } 69 } ); 70 71 CKEDITOR.config.resizeMinWidth = 100; 72 CKEDITOR.config.resizeMinHeight = 250; 73 CKEDITOR.config.resizeMaxWidth = 3000; 74 CKEDITOR.config.resizeMaxHeight = 3000; 75 CKEDITOR.config.resizeEnabled = true; -
_source/themes/default/theme.js
186 186 var delta = isContentHeight ? 0 : ( outer.$.offsetHeight || 0 ) - ( contents.$.clientHeight || 0 ); 187 187 188 188 // Resize the height. 189 contents.setStyle( 'height', ( height - delta) + 'px' );189 contents.setStyle( 'height', Math.max( ( height - delta ), 0 ) + 'px' ); 190 190 191 191 // Emit a resize event. 192 192 this.fire( 'resize' ); -
_source/skins/office2003/elementspath.css
14 14 .cke_skin_office2003 .cke_path 15 15 { 16 16 padding: 3px 3px 0 3px; 17 display: block; 18 float: left; 19 width: 75%; 17 20 } 18 21 19 22 .cke_skin_office2003 .cke_path a, -
_source/skins/office2003/mainui.css
54 54 white-space: pre; 55 55 background-color: #fff; 56 56 } 57 58 .cke_skin_office2003 .cke_resizer 59 { 60 width: 12px; 61 height: 12px; 62 margin-top: 12px; 63 display: block; 64 float: right; 65 background-image: url(images/resizer.gif); 66 cursor: se-resize; 67 } -
_source/skins/v2/elementspath.css
14 14 .cke_skin_v2 .cke_path 15 15 { 16 16 padding: 3px 3px 0 3px; 17 display: block; 18 float: left; 19 width: 75%; 17 20 } 18 21 19 22 .cke_skin_v2 .cke_path a, -
_source/skins/v2/mainui.css
65 65 /* For IE6+Quirks only */ 66 66 _white-space: normal; 67 67 } 68 69 .cke_skin_v2 .cke_resizer 70 { 71 width: 12px; 72 height: 12px; 73 margin-top: 12px; 74 display: block; 75 float: right; 76 background-image: url(images/resizer.gif); 77 cursor: se-resize; 78 } -
_source/core/config.js
150 150 * config.plugins = 'basicstyles,button,htmldataprocessor,toolbar,wysiwygarea'; 151 151 */ 152 152 153 plugins : 'about,basicstyles,blockquote,button,clipboard,colorbutton,contextmenu,elementspath,enterkey,entities,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,maximize,newpage,pagebreak,pastefromword,pastetext,preview,print,removeformat, save,scayt,smiley,showblocks,sourcearea,stylescombo,table,tabletools,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',153 plugins : 'about,basicstyles,blockquote,button,clipboard,colorbutton,contextmenu,elementspath,enterkey,entities,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,maximize,newpage,pagebreak,pastefromword,pastetext,preview,print,removeformat,resize,save,scayt,smiley,showblocks,sourcearea,stylescombo,table,tabletools,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc', 154 154 155 155 /** 156 156 * List of additional plugins to be loaded. This is a tool setting which