Opened 17 years ago
Closed 17 years ago
#1095 closed Bug (fixed)
Backspace does not work in Opera
Reported by: | Martin Kou | Owned by: | Martin Kou |
---|---|---|---|
Priority: | Must have (possibly next milestone) | Milestone: | Opera Compatibility |
Component: | UI : Enter Key | Version: | SVN (FCKeditor) - Retired |
Keywords: | Confirmed Opera | Cc: | Hallvord R. M. Steen (Opera Software) |
Description
Reproduction procedure:
- Open sample01.html in Opera.
- Place the caret to the end of the document.
- Press backspace a few times.
- The caret jumps around while deleting characters.
The bug does not occur in 2.4.3.
Attachments (1)
Change History (10)
comment:1 Changed 17 years ago by
Component: | General → UI : Enter Key |
---|
comment:2 Changed 17 years ago by
Milestone: | FCKeditor 2.5 → Opera Compatibility |
---|
comment:3 Changed 17 years ago by
I've traced the error to line 230 of classes/fckw3crange.js:
endNode = endNode.splitText( endOffset ) ;
I found that calling TextNode.splitText() in Opera would make the caret jump around inside a block element. This seems like an Opera bug as no other browser would do that.
I've made a very simple test case to demonstrate the problem.
comment:4 Changed 17 years ago by
Status: | new → assigned |
---|
comment:5 Changed 17 years ago by
I've committed to proposed fix in [717], it seems to fix the cursor jumping problem. However, I don't really understand what the function that I've changed (FCKW3CRange._ExecContentsAction) is actually doing, so my changes could possibly cause other bugs.
comment:6 Changed 17 years ago by
Martin, I've reverted [717], including a simpler fix for this ticket. It worked for me here, so if you feel it is ok, you can close this ticket.
_ExecContentsAction is quite a complex function. It runs the deleteContents, extractContents and cloneContents functions, as they have a very similar logic.
Ranges, have nothing to do with the selection, so we should not make selection changes there. At the same time, we must be aware that ranges manipulation may interfere with the selection, and so we should fix it when needed "in the calling code". It has been done for Firefox, so we're just doing the same for Opera now.
comment:7 Changed 17 years ago by
Cc: | Hallvord R. M. Steen (Opera Software) added |
---|
CCing Hallvord, so he can consider Martin's test case.
comment:8 Changed 17 years ago by
Opss... I've just found out that this is a DUP of #571. So, you can close that one too Martin.
comment:9 Changed 17 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Yes, the changes in [718] works well for me. Closing ticket.
Oops... this bug actually occurs in 2.4.3 as well. But the changeset [705] has made it more visible in the samples since it enabled the bug to appear right after the editor is loaded.
Reproduction procedure for all versions: