Bug 191481 - REGRESSION(r223264): [GTK] Unable to drag documents on Google Drive
Summary: REGRESSION(r223264): [GTK] Unable to drag documents on Google Drive
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: UI Events (show other bugs)
Version: WebKit Local Build
Hardware: PC Linux
: P2 Normal
Assignee: Michael Catanzaro
URL:
Keywords: Regression
Depends on:
Blocks: 178214
  Show dependency treegraph
 
Reported: 2018-11-09 12:33 PST by Beau Adkins
Modified: 2018-11-13 13:18 PST (History)
5 users (show)

See Also:


Attachments
WIP patch (2.90 KB, patch)
2018-11-11 08:50 PST, Michael Catanzaro
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Beau Adkins 2018-11-09 12:33:38 PST
After r223264, you can no longer drag and drop documents on the Google Drive home screen that shows all your documents. I bisected it down to this revision, but after reviewing the change, I just can't see how this change is actually breaking anything. From my reading, it should only have any actual effect on Mac. As far as a GTK build is concerned, it looks like it just adds an unused member to a few mouse event classes.
Comment 1 Chris Dumez 2018-11-10 19:05:29 PST
The issue is likely that MousrEvent.buttons is exposed to the Web but unimplemented on GTK. It should either get implemented in GTK or unexposed for this port.
Comment 2 Michael Catanzaro 2018-11-11 08:01:52 PST
Thanks for investigating, Chris!
Comment 3 Michael Catanzaro 2018-11-11 08:49:45 PST
Hm, looks like WebEventFactory::createWebMouseEvent in Source/WebKit/Shared/gtk/WebEventFactory.cpp is already passing the pressed mouse buttons into the WebMouseEvent constructor. So that looks fine.

The PlatformMouseEvent constructors are not doing so. I'm attaching a patch to fix these constructors as a starting point, but it's not enough to fix Google Drive. Further investigation will be required as to why it's still not working.
Comment 4 Michael Catanzaro 2018-11-11 08:50:16 PST
Created attachment 354506 [details]
WIP patch
Comment 5 Build Bot 2018-11-11 08:52:17 PST
Attachment 354506 [details] did not pass style-queue:


ERROR: Source/WebCore/ChangeLog:8:  You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible.  [changelog/nonewtests] [5]
Total errors found: 1 in 2 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 6 Michael Catanzaro 2018-11-11 08:52:39 PST
(In reply to Michael Catanzaro from comment #3)
> Hm, looks like WebEventFactory::createWebMouseEvent in
> Source/WebKit/Shared/gtk/WebEventFactory.cpp is already passing the pressed
> mouse buttons into the WebMouseEvent constructor. So that looks fine.

It was implemented in r230988, a good time after r223264, but still a while back.
Comment 7 Beau Adkins 2018-11-13 10:23:18 PST
Thanks Michael,

Backporting this patch into the 2.20 branch that I am working off of does indeed restore drag/drop functionality for Google Drive.

I guess this ticket should be closed as invalid.
Comment 8 Michael Catanzaro 2018-11-13 12:51:41 PST
No, because it's broken in trunk with or without my patch.
Comment 9 Beau Adkins 2018-11-13 13:18:09 PST
Michael,

Ok. Just to clarify, as it might help:

I am running off of the 2.20 branch. The drag/drop on Google Drive was broken there. But when I merged in 230988 to the 2.20 branch, everything is working now. This is WITHOUT merging in your attachment to this ticket though.

So maybe there was another commit after the 2.20 branch or after 230988 that rebroke it?