Struct smithay::wayland::seat::AxisFrame[][src]

pub struct AxisFrame { /* fields omitted */ }
Expand description

A frame of pointer axis events.

Can be used with the builder pattern, e.g.:

AxisFrame::new()
    .source(AxisSource::Wheel)
    .discrete(Axis::Vertical, 6)
    .value(Axis::Vertical, 30, time)
    .stop(Axis::Vertical);

Implementations

Create a new frame of axis events

Specify the source of the axis events

This event is optional, if no source is known, you can ignore this call. Only one source event is allowed per frame.

Using the AxisSource::Finger requires a stop event to be send, when the user lifts off the finger (not necessarily in the same frame).

Specify discrete scrolling steps additionally to the computed value.

This event is optional and gives the client additional information about the nature of the axis event. E.g. a scroll wheel might issue separate steps, while a touchpad may never issue this event as it has no steps.

The actual scroll value. This event is the only required one, but can also be send multiple times. The values off one frame will be accumulated by the client.

Notification of stop of scrolling on an axis.

This event is required for sources of the AxisSource::Finger type and otherwise optional.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Convert 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. Read more

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait. Read more

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s. Read more

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s. Read more

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait. Read more

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.