:right-sidebar: True DropControllerMotion =================================================================== .. currentmodule:: gi.repository.Gtk .. class:: DropControllerMotion(**properties: ~typing.Any) :no-contents-entry: Superclasses: :class:`~gi.repository.Gtk.EventController`, :class:`~gi.repository.GObject.Object` ``GtkDropControllerMotion`` is an event controller tracking the pointer during Drag-and-Drop operations. It is modeled after :obj:`~gi.repository.Gtk.EventControllerMotion` so if you have used that, this should feel really familiar. This controller is not able to accept drops, use :obj:`~gi.repository.Gtk.DropTarget` for that purpose. Constructors ------------ .. rst-class:: interim-class .. class:: DropControllerMotion :no-index: .. classmethod:: new() -> ~gi.repository.Gtk.EventController Creates a new event controller that will handle pointer motion events during drag and drop. Methods ------- .. rst-class:: interim-class .. class:: DropControllerMotion :no-index: .. method:: contains_pointer() -> bool Returns if a Drag-and-Drop operation is within the widget ``self`` or one of its children. .. method:: get_drop() -> ~gi.repository.Gdk.Drop | None Returns the ``GdkDrop`` of a current Drag-and-Drop operation over the widget of ``self``\. .. method:: is_pointer() -> bool Returns if a Drag-and-Drop operation is within the widget ``self``\, not one of its children. Properties ---------- .. rst-class:: interim-class .. class:: DropControllerMotion :no-index: .. attribute:: props.contains_pointer :type: bool The type of the None singleton. .. attribute:: props.drop :type: ~gi.repository.Gdk.Drop The type of the None singleton. .. attribute:: props.is_pointer :type: bool The type of the None singleton. Signals ------- .. rst-class:: interim-class .. class:: DropControllerMotion.signals :no-index: .. method:: enter(x: float, y: float) -> None The type of the None singleton. :param x: coordinates of pointer location :param y: coordinates of pointer location .. method:: leave() -> None The type of the None singleton. .. method:: motion(x: float, y: float) -> None The type of the None singleton. :param x: the x coordinate :param y: the y coordinate