RESOLVED FIXED 209531
Avoid querying pasteboard strings while dragging content over a potential drop target
https://bugs.webkit.org/show_bug.cgi?id=209531
Summary Avoid querying pasteboard strings while dragging content over a potential dro...
Wenson Hsieh
Reported 2020-03-24 22:51:15 PDT
Refactor some code running in the web process, such that it doesn’t need to ask for pasteboard data prior to drop (or paste).
Attachments
Patch (15.46 KB, patch)
2020-03-24 23:04 PDT, Wenson Hsieh
thorton: review+
Patch for landing (15.72 KB, patch)
2020-03-25 07:41 PDT, Wenson Hsieh
no flags
Wenson Hsieh
Comment 1 2020-03-24 22:51:49 PDT
Wenson Hsieh
Comment 2 2020-03-24 23:04:23 PDT
Tim Horton
Comment 3 2020-03-24 23:12:30 PDT
Comment on attachment 394471 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=394471&action=review > Source/WebCore/ChangeLog:15 > + This is incompatible with some changes in the near future which will prevent the web content process from any > + reading data from the pasteboard, if a paste or drop action has not yet been performed. To address this issue, "any reading data"?
Ryosuke Niwa
Comment 4 2020-03-24 23:44:19 PDT
Comment on attachment 394471 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=394471&action=review > Source/WebCore/platform/PlatformPasteboard.h:102 > WEBCORE_EXPORT Vector<String> typesSafeForDOMToReadAndWrite(const String& origin) const; > + WEBCORE_EXPORT bool containsDOMSafeStringForType(const String&) const; For consistency, I suggest we call this containsStringSafeForDOMToReadForType
Wenson Hsieh
Comment 5 2020-03-25 07:19:44 PDT
Comment on attachment 394471 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=394471&action=review >> Source/WebCore/ChangeLog:15 >> + reading data from the pasteboard, if a paste or drop action has not yet been performed. To address this issue, > > "any reading data"? Oops — fixed! >> Source/WebCore/platform/PlatformPasteboard.h:102 >> + WEBCORE_EXPORT bool containsDOMSafeStringForType(const String&) const; > > For consistency, I suggest we call this containsStringSafeForDOMToReadForType Sounds good — changed to containsStringSafeForDOMToReadForType.
Wenson Hsieh
Comment 6 2020-03-25 07:41:43 PDT
Created attachment 394494 [details] Patch for landing
EWS
Comment 7 2020-03-25 08:05:58 PDT
Committed r258980: <https://trac.webkit.org/changeset/258980> All reviewed patches have been landed. Closing bug and clearing flags on attachment 394494 [details].
Note You need to log in before you can comment on or make changes to this bug.