pub struct WlDataDeviceManager { /* private fields */ }
Expand description
data transfer interface
The wl_data_device_manager is a singleton global object that provides access to inter-client data transfer mechanisms such as copy-and-paste and drag-and-drop. These mechanisms are tied to a wl_seat and this interface lets a client get a wl_data_device corresponding to a wl_seat.
Depending on the version bound, the objects created from the bound wl_data_device_manager object will have different requirements for functioning properly. See wl_data_source.set_actions, wl_data_offer.accept and wl_data_offer.finish for details.
See Event
for the list of possible events.
Implementations§
Source§impl WlDataDeviceManager
impl WlDataDeviceManager
Sourcepub fn create_data_source<D>(self, conn: &mut Connection<D>) -> WlDataSource
pub fn create_data_source<D>(self, conn: &mut Connection<D>) -> WlDataSource
create a new data source
Create a new data source.
Since version 1.
Sourcepub fn create_data_source_with_cb<D>(
self,
conn: &mut Connection<D>,
cb: impl FnMut(EventCtx<'_, D, WlDataSource>) + Send + 'static,
) -> WlDataSource
pub fn create_data_source_with_cb<D>( self, conn: &mut Connection<D>, cb: impl FnMut(EventCtx<'_, D, WlDataSource>) + Send + 'static, ) -> WlDataSource
create a new data source
Create a new data source.
Since version 1.
Sourcepub fn get_data_device<D>(
self,
conn: &mut Connection<D>,
seat: WlSeat,
) -> WlDataDevice
pub fn get_data_device<D>( self, conn: &mut Connection<D>, seat: WlSeat, ) -> WlDataDevice
create a new data device
Create a new data device for a given seat.
Since version 1.
Sourcepub fn get_data_device_with_cb<D>(
self,
conn: &mut Connection<D>,
seat: WlSeat,
cb: impl FnMut(EventCtx<'_, D, WlDataDevice>) + Send + 'static,
) -> WlDataDevice
pub fn get_data_device_with_cb<D>( self, conn: &mut Connection<D>, seat: WlSeat, cb: impl FnMut(EventCtx<'_, D, WlDataDevice>) + Send + 'static, ) -> WlDataDevice
create a new data device
Create a new data device for a given seat.
Since version 1.
Trait Implementations§
Source§impl Borrow<ObjectId> for WlDataDeviceManager
impl Borrow<ObjectId> for WlDataDeviceManager
Source§impl Clone for WlDataDeviceManager
impl Clone for WlDataDeviceManager
Source§fn clone(&self) -> WlDataDeviceManager
fn clone(&self) -> WlDataDeviceManager
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more