pub struct ScrollBothBinding {
pub on_scroll: Option<Rc<dyn Fn(Vec2) -> Vec2>>,
pub set_viewport_width: Option<Rc<dyn Fn(f32)>>,
pub set_viewport_height: Option<Rc<dyn Fn(f32)>>,
pub set_content_width: Option<Rc<dyn Fn(f32)>>,
pub set_content_height: Option<Rc<dyn Fn(f32)>>,
pub get_offset_xy: Option<Rc<dyn Fn() -> (f32, f32)>>,
pub set_offset_xy: Option<Rc<dyn Fn(f32, f32)>>,
pub show_scrollbar: bool,
pub tick: Option<Rc<dyn Fn()>>,
pub set_nested_scroll_parent: Option<Rc<dyn Fn(NestedScrollConnection)>>,
}Expand description
Callbacks for a 2D (both-axis) scroll container.
Fields§
§on_scroll: Option<Rc<dyn Fn(Vec2) -> Vec2>>§set_viewport_width: Option<Rc<dyn Fn(f32)>>§set_viewport_height: Option<Rc<dyn Fn(f32)>>§set_content_width: Option<Rc<dyn Fn(f32)>>§set_content_height: Option<Rc<dyn Fn(f32)>>§get_offset_xy: Option<Rc<dyn Fn() -> (f32, f32)>>§set_offset_xy: Option<Rc<dyn Fn(f32, f32)>>§show_scrollbar: bool§tick: Option<Rc<dyn Fn()>>§set_nested_scroll_parent: Option<Rc<dyn Fn(NestedScrollConnection)>>Trait Implementations§
Source§impl Clone for ScrollBothBinding
impl Clone for ScrollBothBinding
Source§impl Debug for ScrollBothBinding
impl Debug for ScrollBothBinding
Auto Trait Implementations§
impl !RefUnwindSafe for ScrollBothBinding
impl !Send for ScrollBothBinding
impl !Sync for ScrollBothBinding
impl !UnwindSafe for ScrollBothBinding
impl Freeze for ScrollBothBinding
impl Unpin for ScrollBothBinding
impl UnsafeUnpin for ScrollBothBinding
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