ozone/wayland: Fix drag icon handling

This CL fixes drag&drop icon rendering when running Chromium in compositors
such as Weston and Gnome/Mutter compositor. Without this change, the drag icon
does not show up, despite it seems to work well in other SwayWM compositor,
for example.

The fix consists in only attaching/updating/committing the icon
surface/buffer *after* calling wl_data_device::start_drag(), which
actually sets surface role to `drag_icon` [1]. Additionally, minor
change is done in StartDrag API to avoid unneeded const_cast<>.

[1] https://wayland.freedesktop.org/docs/html/apa.html#protocol-spec-wl_data_device

Bug: 943694, 875164
Change-Id: I2b71378b998fe648cde65fa0e2c234288d1238a8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1531070
Reviewed-by: Maksim Sisov <msisov@igalia.com>
Commit-Queue: Nick Yamane <nickdiego@igalia.com>
Cr-Commit-Position: refs/heads/master@{#642915}
4 files changed