#[non_exhaustive]pub enum Event<'a> {
DataOffer {
id: ExtDataControlOfferV1,
},
Selection {
id: Option<ExtDataControlOfferV1>,
},
Finished,
PrimarySelection {
id: Option<ExtDataControlOfferV1>,
},
}
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
DataOffer
introduce a new ext_data_control_offer
The data_offer event introduces a new ext_data_control_offer object, which will subsequently be used in either the ext_data_control_device.selection event (for the regular clipboard selections) or the ext_data_control_device.primary_selection event (for the primary clipboard selections). Immediately following the ext_data_control_device.data_offer event, the new data_offer object will send out ext_data_control_offer.offer events to describe the MIME types it offers.
Fields
Selection
advertise new selection
The selection event is sent out to notify the client of a new ext_data_control_offer for the selection for this device. The ext_data_control_device.data_offer and the ext_data_control_offer.offer events are sent out immediately before this event to introduce the data offer object. The selection event is sent to a client when a new selection is set. The ext_data_control_offer is valid until a new ext_data_control_offer or NULL is received. The client must destroy the previous selection ext_data_control_offer, if any, upon receiving this event. Regardless, the previous selection will be ignored once a new selection ext_data_control_offer is received.
The first selection event is sent upon binding the ext_data_control_device object.
Fields
Finished
this data control is no longer valid
This data control object is no longer valid and should be destroyed by the client.
PrimarySelection
advertise new primary selection
The primary_selection event is sent out to notify the client of a new ext_data_control_offer for the primary selection for this device. The ext_data_control_device.data_offer and the ext_data_control_offer.offer events are sent out immediately before this event to introduce the data offer object. The primary_selection event is sent to a client when a new primary selection is set. The ext_data_control_offer is valid until a new ext_data_control_offer or NULL is received. The client must destroy the previous primary selection ext_data_control_offer, if any, upon receiving this event. Regardless, the previous primary selection will be ignored once a new primary selection ext_data_control_offer is received.
If the compositor supports primary selection, the first primary_selection event is sent upon binding the ext_data_control_device object.
Fields
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Event<'a>
impl<'a> !RefUnwindSafe for Event<'a>
impl<'a> Send for Event<'a>
impl<'a> Sync for Event<'a>
impl<'a> Unpin for Event<'a>
impl<'a> !UnwindSafe for Event<'a>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.