Add gdk_drag_context_get_drag_window

This makes gdk_wayland_drag_context_get_dnd_window
backend-independent API and adds an implementation
for X11.
This commit is contained in:
Matthias Clasen
2015-12-01 23:33:53 -05:00
parent d46b67dc79
commit fff8297a50
6 changed files with 76 additions and 0 deletions

View File

@ -293,6 +293,12 @@ gdk_wayland_drag_context_init (GdkWaylandDragContext *context_wayland)
context->actions = GDK_ACTION_COPY | GDK_ACTION_MOVE;
}
static GdkWindow *
gdk_wayland_drag_context_get_drag_window (GdkDragContext *context)
{
return GDK_WAYLAND_DRAG_CONTEXT (context)->dnd_window;
}
static void
gdk_wayland_drag_context_class_init (GdkWaylandDragContextClass *klass)
{
@ -310,6 +316,7 @@ gdk_wayland_drag_context_class_init (GdkWaylandDragContextClass *klass)
context_class->drop_finish = gdk_wayland_drag_context_drop_finish;
context_class->drop_status = gdk_wayland_drag_context_drop_status;
context_class->get_selection = gdk_wayland_drag_context_get_selection;
context_class->get_drag_window = gdk_wayland_drag_context_get_drag_window;
}
GdkDragProtocol