Ticket #4988 (closed Bug: fixed)

Opened 5 years ago

Last modified 4 years ago

Safari breaks when pasting with forcePasteAsPlainText = true

Reported by: fredck Owned by: alfonsoml
Priority: Normal Milestone: CKEditor 3.2
Component: Core : Pasting Version: 3.1
Keywords: Safari Confirmed Review+ Cc: diego@…

Description

When pasting with Safari and forcePasteAsPlainText = true in the settings, the browser breaks and shutdown completely.

Confirmed with Safari 3.2.2 Win, and also reported here.

Attachments

4988.patch (1.2 KB) - added by alfonsoml 4 years ago.
Proposed patch

Change History

comment:1 Changed 5 years ago by fredck

WFM with Chrome 4.

comment:2 Changed 5 years ago by dcaravana

  • Cc diego@… added

Confirmed also in Safari 4.0.4 Mac but without the nasty crash, simply it doesn't work (if you insist and try to paste more the one time, one or more textareas for each paste appears inside the editor).

comment:3 Changed 5 years ago by dcaravana

And, yes, it works in Chrome 4 Mac (it seems a Safari-only problem, apart from webkit).

comment:4 Changed 5 years ago by garry.yao

WFM with Safari4/Win.

comment:5 Changed 5 years ago by garry.yao

  • Priority changed from High to Normal

WFM also with Safari3/Win, seems for me a Mac-Safari-only problem.

comment:6 Changed 5 years ago by dcaravana

Yes, I confirm that the bug doesn't affect Safari 4.0.4 WIN, but does affect the same Safari version on Mac.

comment:7 Changed 4 years ago by starnox

Confirmed in Safari 4.0.4/Mac OS 10.6.2.

Single paste results in a blank space being inserted. Further pastes result in textareas appearing within the editor.

comment:8 Changed 4 years ago by fredck

This one may be related to #5095, which is an internal browser bug.

comment:9 Changed 4 years ago by fredck

  • Milestone changed from CKEditor 3.2 to CKEditor 3.3

Changed 4 years ago by alfonsoml

Proposed patch

comment:10 Changed 4 years ago by alfonsoml

  • Owner set to alfonsoml
  • Keywords Review? added
  • Status changed from new to assigned

In Webkit it's possible to get the content of the clipboard as plain text without any hack, so the patch uses that approach.

I've included also a change in the registration of the event that fixes #5095 as that might make easier to review all the code.

And after applying the patch it seems that #5144 is also fixed, although that bug is a little elusive and sometimes seems to work (or maybe it's problems with the cache)

comment:11 Changed 4 years ago by fredck

  • Keywords Review+ added; Review? removed
  • Milestone changed from CKEditor 3.3 to CKEditor 3.2

Great job! Feel free to close #5144 also (please add changelog entries for both tickets).

comment:12 Changed 4 years ago by fredck

#5095 can be closed as well.

comment:13 Changed 4 years ago by alfonsoml

  • Status changed from assigned to closed
  • Resolution set to fixed

Fixed with [5118]

Note: See TracTickets for help on using tickets.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy