Changeset 5880


Ignore:
Timestamp:
09/14/2010 04:16:29 PM (5 years ago)
Author:
Saare
Message:

#6075: [FF] Newly created links didn't fill in information on edit.

Location:
CKEditor/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • CKEditor/trunk/CHANGES.html

    r5879 r5880  
    8282                <li><a href="http://dev.ckeditor.com/ticket/5218">#5218</a> : [FF] Copy/paste of an image from same domain changed URL to relative URL.</li>
    8383                <li><a href="http://dev.ckeditor.com/ticket/6265">#6265</a> : Popup window properties were visible in the link dialog's target tab when nothing was selected.</li>
     84                <li><a href="http://dev.ckeditor.com/ticket/6075">#6075</a> : [FF] Newly created links didn't fill in information on edit.</li>
    8485                <li>Updated the following language files:<ul>
    8586                        <li><a href="http://dev.ckeditor.com/ticket/6246">#6246</a> : Chinese Simplified;</li>
  • CKEditor/trunk/_source/plugins/link/plugin.js

    r5812 r5880  
    177177        getSelectedLink : function( editor )
    178178        {
    179                 var range;
    180179                try
    181180                {
    182                         range  = editor.getSelection().getRanges( true )[ 0 ];
     181                        var selection = editor.getSelection();
     182                        if ( selection.getType() == CKEDITOR.SELECTION_ELEMENT )
     183                        {
     184                                var selectedElement = selection.getSelectedElement();
     185                                if ( selectedElement.is( 'a' ) )
     186                                        return selectedElement;
     187                        }
     188
     189                        var range = selection.getRanges( true )[ 0 ];
    183190                        range.shrink( CKEDITOR.SHRINK_TEXT );
    184191                        var root = range.getCommonAncestor();
Note: See TracChangeset for help on using the changeset viewer.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy