forked from AuroraMiddleware/gtk
wayland: Add a dummy implementation of gdk_drag_context_set_hotspot
This just records the hotspot coordinates. Still to do: apply the hotspot when updating the drag window.
This commit is contained in:
parent
475f6e09b1
commit
3b4bfba37d
@ -48,6 +48,8 @@ struct _GdkWaylandDragContext
|
||||
uint32_t serial;
|
||||
gdouble x;
|
||||
gdouble y;
|
||||
gint hot_x;
|
||||
gint hot_y;
|
||||
};
|
||||
|
||||
struct _GdkWaylandDragContextClass
|
||||
@ -299,6 +301,15 @@ gdk_wayland_drag_context_get_drag_window (GdkDragContext *context)
|
||||
return GDK_WAYLAND_DRAG_CONTEXT (context)->dnd_window;
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_wayland_drag_context_set_hotspot (GdkDragContext *context,
|
||||
gint hot_x,
|
||||
gint hot_y)
|
||||
{
|
||||
GDK_WAYLAND_DRAG_CONTEXT (context)->hot_x = hot_x;
|
||||
GDK_WAYLAND_DRAG_CONTEXT (context)->hot_y = hot_y;
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_wayland_drag_context_class_init (GdkWaylandDragContextClass *klass)
|
||||
{
|
||||
@ -317,6 +328,7 @@ gdk_wayland_drag_context_class_init (GdkWaylandDragContextClass *klass)
|
||||
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;
|
||||
context_class->set_hotspot = gdk_wayland_drag_context_set_hotspot;
|
||||
}
|
||||
|
||||
GdkDragProtocol
|
||||
|
Loading…
Reference in New Issue
Block a user