RESOLVED FIXED Bug 60840
WebKit2: Smart cut&paste is broken
https://bugs.webkit.org/show_bug.cgi?id=60840
Summary WebKit2: Smart cut&paste is broken
Alexey Proskuryakov
Reported 2011-05-14 11:30:59 PDT
Steps to reproduce: 1. Open e.g. http://www.w3schools.com/tags/tryit.asp?filename=tryhtml_textarea 2. Double click a word 3. Cmd+X Expected results: the word is cut, only one space of the two that were surrounding it remains. Actual results: both spaces remain. All we likely need to do is to set a preference. I'm not sure, but we may not be using "Mac editing behavior" at all in WK2, losing a lot of other important features.
Attachments
proposed fix (1.45 KB, patch)
2011-05-14 12:00 PDT, Alexey Proskuryakov
no flags
Alexey Proskuryakov
Comment 1 2011-05-14 11:31:26 PDT
Alexey Proskuryakov
Comment 2 2011-05-14 12:00:58 PDT
Created attachment 93559 [details] proposed fix No, this doesn't affect editing behavior, only this one feature.
Anders Carlsson
Comment 3 2011-05-14 12:07:17 PDT
Comment on attachment 93559 [details] proposed fix View in context: https://bugs.webkit.org/attachment.cgi?id=93559&action=review > Source/WebKit2/UIProcess/mac/TextCheckerMac.mm:183 > + smartInsertDeleteEnabled = ![[NSUserDefaults standardUserDefaults] objectForKey:WebSmartInsertDeleteEnabled] || [[NSUserDefaults standardUserDefaults] boolForKey:WebSmartInsertDeleteEnabled]; I don't understand the first part here. smartInsertDelete is enabled when [[NSUserDefaults standardUserDefaults] objectForKey:WebSmartInsertDeleteEnabled] returns nil?
Alexey Proskuryakov
Comment 4 2011-05-14 12:28:51 PDT
> I don't understand the first part here. smartInsertDelete is enabled when [[NSUserDefaults standardUserDefaults] objectForKey:WebSmartInsertDeleteEnabled] returns nil? Yes. It should be enabled for users who never touched this preference in context menu. Here is what WebKit1 does in -[WebViewPrivate init]: smartInsertDeleteEnabled = ![[NSUserDefaults standardUserDefaults] objectForKey:WebSmartInsertDeleteEnabled] || [[NSUserDefaults standardUserDefaults] boolForKey:WebSmartInsertDeleteEnabled];
WebKit Commit Bot
Comment 5 2011-05-14 14:23:36 PDT
Comment on attachment 93559 [details] proposed fix Clearing flags on attachment: 93559 Committed r86497: <http://trac.webkit.org/changeset/86497>
WebKit Commit Bot
Comment 6 2011-05-14 14:23:41 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.