pub trait DataDeviceHandler: Sized {
    // Required methods
    fn enter(
        &mut self,
        conn: &Connection,
        qh: &QueueHandle<Self>,
        data_device: &WlDataDevice,
    );
    fn leave(
        &mut self,
        conn: &Connection,
        qh: &QueueHandle<Self>,
        data_device: &WlDataDevice,
    );
    fn motion(
        &mut self,
        conn: &Connection,
        qh: &QueueHandle<Self>,
        data_device: &WlDataDevice,
    );
    fn selection(
        &mut self,
        conn: &Connection,
        qh: &QueueHandle<Self>,
        data_device: &WlDataDevice,
    );
    fn drop_performed(
        &mut self,
        conn: &Connection,
        qh: &QueueHandle<Self>,
        data_device: &WlDataDevice,
    );
}
Expand description

Handler trait for DataDevice events.

The functions defined in this trait are called as DataDevice events are received from the compositor.

Required Methods§

source

fn enter( &mut self, conn: &Connection, qh: &QueueHandle<Self>, data_device: &WlDataDevice, )

The data device pointer has entered a surface at the provided location

source

fn leave( &mut self, conn: &Connection, qh: &QueueHandle<Self>, data_device: &WlDataDevice, )

The drag and drop pointer has left the surface and the session ends. The offer will be destroyed unless it was previously dropped. In the case of a dropped offer, the client must destroy it manually after it is finished.

source

fn motion( &mut self, conn: &Connection, qh: &QueueHandle<Self>, data_device: &WlDataDevice, )

Drag and Drop motion.

source

fn selection( &mut self, conn: &Connection, qh: &QueueHandle<Self>, data_device: &WlDataDevice, )

Advertises a new selection.

source

fn drop_performed( &mut self, conn: &Connection, qh: &QueueHandle<Self>, data_device: &WlDataDevice, )

Drop performed. After the next data offer action event, data may be able to be received, unless the action is “ask”.

Object Safety§

This trait is not object safe.

Implementors§