SwipeGestureRecognizer
struct · ferroui-base · v0.5.0
struct SwipeGestureRecognizer
A gesture recognizer that detects swipe gestures and raises the swipe gesture event continuously as the pointer moves.
Members
TYPEto_refcan_horizontally_swipe_propertycan_vertically_swipe_propertythreshold_propertyis_mouse_enabled_propertyis_enabled_propertynewcan_horizontally_swipeset_can_horizontally_swipecan_vertically_swipeset_can_vertically_swipethresholdset_thresholdis_mouse_enabledset_is_mouse_enabledis_enabledset_is_enabled
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<SwipeGestureRecognizer>
Returns a strong reference to this object.
can_horizontally_swipe_property
fn can_horizontally_swipe_property() -> &'static StyledProperty<bool>
Defines the CanHorizontallySwipe property.
can_vertically_swipe_property
fn can_vertically_swipe_property() -> &'static StyledProperty<bool>
Defines the CanVerticallySwipe property.
threshold_property
fn threshold_property() -> &'static StyledProperty<f64>
Defines the Threshold property.
is_mouse_enabled_property
fn is_mouse_enabled_property() -> &'static StyledProperty<bool>
Defines the IsMouseEnabled property.
is_enabled_property
fn is_enabled_property() -> &'static StyledProperty<bool>
Defines the IsEnabled property.
new
fn new() -> Ref<Self>
can_horizontally_swipe
fn can_horizontally_swipe(self: &Self) -> bool
Whether horizontal swipes are tracked.
set_can_horizontally_swipe
fn set_can_horizontally_swipe(self: &Self, value: bool)
can_vertically_swipe
fn can_vertically_swipe(self: &Self) -> bool
Whether vertical swipes are tracked.
set_can_vertically_swipe
fn set_can_vertically_swipe(self: &Self, value: bool)
threshold
fn threshold(self: &Self) -> f64
The minimum pointer movement in pixels before a swipe is recognized. A value of 0 (the default) uses half of the platform's touch tap size.
set_threshold
fn set_threshold(self: &Self, value: f64)
is_mouse_enabled
fn is_mouse_enabled(self: &Self) -> bool
Whether mouse pointer events trigger swipe gestures. Defaults to false; touch and pen are always enabled.
set_is_mouse_enabled
fn set_is_mouse_enabled(self: &Self, value: bool)
is_enabled
fn is_enabled(self: &Self) -> bool
Whether this recognizer responds to pointer events. Defaults to true.
set_is_enabled
fn set_is_enabled(self: &Self, value: bool)
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeGestureRecognizerImplExtFerroObjectImplExtStyledElementImplExtClassDefaultsBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyErasedDestructorIntoEitherDerefUpcast<T>Upcast<SwipeGestureRecognizer>StaticTypeObjectTypeSubclassable<T>DefaultConstructibleFerroObjectImplStyledElementImplGestureRecognizerImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.