Opened 15 years ago

Closed 9 years ago

#1674 closed Bug (wontfix)

Double Click Select link in Firefox does not register as a link selected

Reported by: Mike Owned by:
Priority: Normal Milestone:
Component: General Version: FCKeditor 2.5.1
Keywords: Cc:


In Firefox, if you select a link by double clicking on it, the MoveToAncestorNode() or hasAncestorNode() functions do not return the anchor. If the same selection is made by selecting normally (dragging the selection), it registers just fine. Example: if you double click a link to select it, the "Unlink" button is disabled, but should be enabled. I have found the following code fixes this problem:

new code
var range = FCK.EditorWindow.getSelection().getRangeAt(0);
if (!range.collapsed && range.startContainer == range.endContainer && range.startOffset - range.endOffset <= 1 && range.startContainer.hasChildNodes())

selectedElement = range.startContainer.childNodes[range.startOffset];

Putting somewhere in the GetSelectedElement() function will probably fix both HasAncestorNode() and MoveToAncestorNode() for Anchors, but not sure if it will break anything else.

I am seeing this behavior in Firefox on Windows XP Pro SP2.

Change History (5)

comment:1 in reply to:  description Changed 15 years ago by Mike

Replying to mephraim:

Another note: This behavior is also exhibited when an anchor is inserted (with the Insert/Edit Anchor button), then when the fake image is selected by clicking on it, then clicking the Insert/Edit Anchor button again, it does not find the anchor and does not load the name in the dialog.

comment:2 Changed 15 years ago by Wojciech Olchawa

Keywords: Confirmed added

Confirmed in FF. Works with IE.

comment:3 Changed 15 years ago by Wojciech Olchawa

Version: FCKeditor 2.5.1

comment:4 Changed 12 years ago by mysterygog

When is the time for coming? I wonder.

comment:5 Changed 9 years ago by Piotrek Koszuliński

Resolution: wontfix
Status: confirmedclosed


Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy