[][src]Struct smithay_client_toolkit::primary_selection::PrimarySelectionDevice

pub struct PrimarySelectionDevice { /* fields omitted */ }

Handle to support primary selection on a given seat.

This type provides you with copy/paste actions. It is associated with a seat upon creation.

Implementations

impl PrimarySelectionDevice[src]

pub fn init_for_seat(
    manager: &PrimarySelectionDeviceManager,
    seat: &WlSeat
) -> Self
[src]

Create the PrimarySelectionDevice helper for this seat.

pub fn set_selection(
    &self,
    source: &Option<PrimarySelectionSource>,
    serial: u32
)
[src]

Provide a primary selection source as the new content for the primary selection.

Correspond to traditional copy/paste behavior. Setting the source to None will clear the selection.

pub fn with_selection<F: FnOnce(Option<&PrimarySelectionOffer>) -> T, T>(
    &self,
    f: F
) -> T
[src]

Access the PrimarySelectionOffer currently associated with the primary selection buffer.

Trait Implementations

impl Drop for PrimarySelectionDevice[src]

Auto Trait Implementations

impl !RefUnwindSafe for PrimarySelectionDevice

impl Send for PrimarySelectionDevice

impl Sync for PrimarySelectionDevice

impl Unpin for PrimarySelectionDevice

impl !UnwindSafe for PrimarySelectionDevice

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.