"Paste and Match Style" should fire paste events
Created attachment 59541 [details] patch
Comment on attachment 59541 [details] patch clearing the flag. I need to fix up DumpRenderTree. The pasteboard doesn't get totally blown away when setting data on the ClipboardData object in later tests.
Created attachment 59610 [details] patch I'm not totally sure this is the best way to clear the pasteboard in between tests, but it seems to work.
Committed revision 61771.
Comment on attachment 59610 [details] patch I don’t understand why the RetainPtr and RefPtr are needed. Two other thoughts: 1) Use a named editor command PasteAsPlainText for this and eliminate the method entirely. We'd add this to the WEBCORE_COMMAND macro section of the file. This could help us in the future when reimplementing for WebKit2. 2) We should consider removing _pasteAsPlainTextWithPasteboard and readSelectionFromPasteboard. I'm not sure why these methods exist.
(In reply to comment #5) > (From update of attachment 59610 [details]) > I don’t understand why the RetainPtr and RefPtr are needed. This is what's done in the paste selector. When the paste event fires, maybe the WebView could go away. I'm not sure. > > Two other thoughts: > > 1) Use a named editor command PasteAsPlainText for this and eliminate the method entirely. We'd add this to the WEBCORE_COMMAND macro section of the file. This could help us in the future when reimplementing for WebKit2. Good idea! > > 2) We should consider removing _pasteAsPlainTextWithPasteboard and readSelectionFromPasteboard. I'm not sure why these methods exist. I'll investigate this.
Created attachment 59700 [details] updated fix Here's a patch that removes those unused methods and uses the WebCore command system for pasteAsPlainText.
Updated fix in revision 61794.