pub enum ScrollAlgorithm {
Momentum(MomentumScroller),
HardScroll(HardScroller),
}Expand description
Per-axis scroll algorithm wrapper.
Variants§
Momentum(MomentumScroller)
Inertial scrolling with friction decay.
HardScroll(HardScroller)
Direct delta accumulation without momentum.
Implementations§
Source§impl ScrollAlgorithm
impl ScrollAlgorithm
Sourcepub fn get_position(&self) -> f32
pub fn get_position(&self) -> f32
Returns the current scroll offset for this axis.
Auto Trait Implementations§
impl Freeze for ScrollAlgorithm
impl RefUnwindSafe for ScrollAlgorithm
impl Send for ScrollAlgorithm
impl Sync for ScrollAlgorithm
impl Unpin for ScrollAlgorithm
impl UnsafeUnpin for ScrollAlgorithm
impl UnwindSafe for ScrollAlgorithm
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
Mutably borrows from an owned value. Read more