X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=_source%2Fplugins%2Fimage%2Fdialogs%2Fimage.js;h=496827bc190d4646e14620450d789e60c6d47be5;hb=fb481ba0a7d298e3e7b9034fcb9f2afdc6e8e796;hp=8902f9b3c0d5f4035659e946add277373cd1d8d9;hpb=e73319a12b56100b29ef456fd74114fe5519e01c;p=ckeditor.git
diff --git a/_source/plugins/image/dialogs/image.js b/_source/plugins/image/dialogs/image.js
index 8902f9b..496827b 100644
--- a/_source/plugins/image/dialogs/image.js
+++ b/_source/plugins/image/dialogs/image.js
@@ -1,5 +1,5 @@
/*
-Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
+Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
*/
@@ -266,7 +266,6 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
btnLockSizesId = numbering( 'btnLockSizes' ),
btnResetSizeId = numbering( 'btnResetSize' ),
imagePreviewLoaderId = numbering( 'ImagePreviewLoader' ),
- imagePreviewBoxId = numbering( 'ImagePreviewBox' ),
previewLinkId = numbering( 'previewLink' ),
previewImageId = numbering( 'previewImage' );
@@ -290,8 +289,8 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
this.addLink = false;
var editor = this.getParentEditor(),
- sel = this.getParentEditor().getSelection(),
- element = sel.getSelectedElement(),
+ sel = editor.getSelection(),
+ element = sel && sel.getSelectedElement(),
link = element && element.getAscendant( 'a' );
//Hide loader.
@@ -847,11 +846,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
element.setStyle( 'border-style', 'solid' );
}
else if ( !value && this.isChanged() )
- {
- element.removeStyle( 'border-width' );
- element.removeStyle( 'border-style' );
- element.removeStyle( 'border-color' );
- }
+ element.removeStyle( 'border' );
if ( !internalCommit && type == IMAGE )
element.removeAttribute( 'border' );
@@ -1077,7 +1072,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
style : 'width:95%;',
html : '
' + CKEDITOR.tools.htmlEncode( editor.lang.common.preview ) +'
'+
'
'+
- '
'+
+ ''+
''+
'' +
( editor.config.image_previewText ||
|
|