Skip to content
Permalink
Browse files

Merge branch 't/11801b'

  • Loading branch information...
oleq committed Apr 29, 2014
2 parents dc7bcdb + a512067 commit 59a8141235f4ec962331a29349b3c13ff363567c
Showing with 17 additions and 28 deletions.
  1. +2 −0 CHANGES.md
  2. +15 −22 plugins/link/dialogs/link.js
  3. +0 −6 plugins/link/plugin.js
@@ -4,8 +4,10 @@ CKEditor 4 Changelog
## CKEditor 4.4.1

Fixed Issues:

* [#11754](http://dev.ckeditor.com/ticket/11754): Fixed: Infinite loop in Google Chrome when contents contains not closed attributes.
* [#11848](http://dev.ckeditor.com/ticket/11848): Fixed: [`editor.insertElement()`](http://docs.ckeditor.com/#!/api/CKEDITOR.editor-method-insertElement) throwing an exception in IE, when there was no selection in editor.
* [#11801](http://dev.ckeditor.com/ticket/11801): Fixed: Editor anchors unavailable when linking [Enhanced Image](http://ckeditor.com/addon/image2) widget.

Other changes:

@@ -103,9 +103,9 @@
return commitParams.call( this, 'advanced', data );
};


var commonLang = editor.lang.common,
linkLang = editor.lang.link;
linkLang = editor.lang.link,
anchors;

return {
title: linkLang.title,
@@ -258,10 +258,9 @@
id: 'selectAnchorText',
label: linkLang.selectAnchor,
setup: function( data ) {
if ( data.anchors && data.anchors.length > 0 )
this.getElement().show();
else
this.getElement().hide();
anchors = plugin.getEditorAnchors( editor );

this.getElement()[ anchors && anchors.length ? 'show' : 'hide' ]();
},
children: [
{
@@ -281,10 +280,10 @@
this.clear();
this.add( '' );

if ( data.anchors ) {
for ( var i = 0; i < data.anchors.length; i++ ) {
if ( data.anchors[ i ].name )
this.add( data.anchors[ i ].name );
if ( anchors ) {
for ( var i = 0; i < anchors.length; i++ ) {
if ( anchors[ i ].name )
this.add( anchors[ i ].name );
}
}

@@ -315,10 +314,10 @@
this.clear();
this.add( '' );

if ( data.anchors ) {
for ( var i = 0; i < data.anchors.length; i++ ) {
if ( data.anchors[ i ].id )
this.add( data.anchors[ i ].id );
if ( anchors ) {
for ( var i = 0; i < anchors.length; i++ ) {
if ( anchors[ i ].id )
this.add( anchors[ i ].id );
}
}

@@ -334,10 +333,7 @@
}
],
setup: function( data ) {
if ( data.anchors && data.anchors.length > 0 )
this.getElement().show();
else
this.getElement().hide();
this.getElement()[ anchors && anchors.length ? 'show' : 'hide' ]();
}
}
]
@@ -350,10 +346,7 @@
// Focus the first element defined in above html.
focus: true,
setup: function( data ) {
if ( data.anchors && data.anchors.length < 1 )
this.getElement().show();
else
this.getElement().hide();
this.getElement()[ anchors && anchors.length ? 'hide' : 'show' ]();
}
}
],
@@ -535,12 +535,6 @@
retval.advanced = advanced;
}

// Find out whether we have any anchors in the editor.
var anchors = CKEDITOR.plugins.link.getEditorAnchors( editor );

if ( anchors.length )
retval.anchors = anchors;

return retval;
},

0 comments on commit 59a8141

Please sign in to comment.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.