Summary: | Refactor drag start codepaths to plumb a DragItem to client layers | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Wenson Hsieh <wenson_hsieh> | ||||||||
Component: | WebCore Misc. | Assignee: | Wenson Hsieh <wenson_hsieh> | ||||||||
Status: | RESOLVED FIXED | ||||||||||
Severity: | Normal | CC: | bdakin, buildbot, cdumez, dbates, japhet, megan_gardner, rniwa, thorton | ||||||||
Priority: | P2 | ||||||||||
Version: | WebKit Nightly Build | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Unspecified | ||||||||||
Attachments: |
|
Description
Wenson Hsieh
2017-06-26 07:52:29 PDT
Created attachment 313841 [details]
First pass
Created attachment 313858 [details]
Attempt to fix Windows build
Comment on attachment 313858 [details] Attempt to fix Windows build View in context: https://bugs.webkit.org/attachment.cgi?id=313858&action=review It's a bit scary to expose DragItem like this to WebKit/WebKit2 but I guess there isn't a good alternative here. r=me. > Source/WebKit2/Shared/WebCoreArgumentCoders.h:541 > +#if ENABLE(DRAG_SUPPORT) > +template<> struct ArgumentCoder<WebCore::DragItem> { Modern coding style is to implement encode/decode in WebCore right next to the actual data type. Comment on attachment 313858 [details] Attempt to fix Windows build View in context: https://bugs.webkit.org/attachment.cgi?id=313858&action=review > Source/WebKit2/Shared/WebCoreArgumentCoders.cpp:2235 > + encoder << hasIndicatorData; > + if (hasIndicatorData) > + encoder << item.image.indicatorData().value(); It's a bit strange to not include the image data but only the indicator data. We should probably add a FIXME here. Created attachment 313925 [details]
Patch for landing
Comment on attachment 313858 [details] Attempt to fix Windows build View in context: https://bugs.webkit.org/attachment.cgi?id=313858&action=review >> Source/WebKit2/Shared/WebCoreArgumentCoders.cpp:2235 >> + encoder << item.image.indicatorData().value(); > > It's a bit strange to not include the image data but only the indicator data. > We should probably add a FIXME here. I added a FIXME earlier in this function that references wkbug.com/173815, which tracks the rest of the DragItems refactoring. >> Source/WebKit2/Shared/WebCoreArgumentCoders.h:541 >> +template<> struct ArgumentCoder<WebCore::DragItem> { > > Modern coding style is to implement encode/decode in WebCore right next to the actual data type. Got it -- fixed! Comment on attachment 313925 [details] Patch for landing Committed r218837: <http://trac.webkit.org/changeset/218837> |