[Webkit-unassigned] [Bug 211723] [GTK] Rework drag and drop handling in preparation for GTK4

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue May 12 09:17:18 PDT 2020


https://bugs.webkit.org/show_bug.cgi?id=211723

Adrian Perez <aperez at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |aperez at igalia.com
 Attachment #399122|review?                     |review+
              Flags|                            |

--- Comment #3 from Adrian Perez <aperez at igalia.com> ---
Comment on attachment 399122
  --> https://bugs.webkit.org/attachment.cgi?id=399122
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=399122&action=review

> Source/WebCore/platform/gtk/GtkUtilities.cpp:111
> +        && gdkAction & GDK_ACTION_LINK)

It took me a while to understand why this is done in this way. IMO it's more
idiomatic to use a bitmastk to checl all flags at once: 

  static constexpr auto gdkEveryMask = GDK_ACTION_COPY | GDK_ACTION_MOVE | GDK_ACTION_LINK;
  if ((gdkAction & gdkEveryMask) == gdkEveryMask)
      return DragOperationEvery;

...but it was already written this way before, so feel free to leave it as-is.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200512/8e099d12/attachment.htm>


More information about the webkit-unassigned mailing list