mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-26 13:41:07 +00:00
wayland: Use display from GdkDragContext device
It will be useless to check the source window on the destination side, it's at the moment always NULL. Fetch the display from the device instead, which will be set for every GdkDragContext.
This commit is contained in:
parent
4162fccaa2
commit
e43ec48e83
@ -382,7 +382,11 @@ _gdk_wayland_drop_context_new (GdkDevice *device,
|
||||
void
|
||||
gdk_wayland_drop_context_update_targets (GdkDragContext *context)
|
||||
{
|
||||
GdkDisplay *display = gdk_window_get_display (context->source_window);
|
||||
GdkDisplay *display;
|
||||
GdkDevice *device;
|
||||
|
||||
device = gdk_drag_context_get_device (context);
|
||||
display = gdk_device_get_display (device);
|
||||
g_list_free (context->targets);
|
||||
context->targets = g_list_copy (gdk_wayland_selection_get_targets (display));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user