pub fn handle_scroll(
        &mut self,
        port: &mut Viewport,
        ctx: &mut EventCtx,
        event: &Event,
        env: &Env,
    ) {
        if !ctx.is_handled() {
            if let Event::Wheel(mouse) = event {
                if port.pan_by(mouse.wheel_delta) {
                    ctx.request_paint();
                    ctx.set_handled();
                    self.reset_scrollbar_fade(|d| ctx.request_timer(d), env);
                }
            }
        }
    }
/// Applies mousewheel scrolling if the event has not already been handled
Applies mousewheel scrolling if the event has not already been handled
Applies mousewheel scrolling if the event has not already been handled
pub fn handle_scroll(
        &mut self,
        port: &mut Viewport,
        ctx: &mut EventCtx,
        event: &Event,
        env: &Env,
    ) {
        if !ctx.is_handled() {
            if let Event::Wheel(mouse) = event {
                if port.pan_by(mouse.wheel_delta) {
                    ctx.request_paint();
                    ctx.set_handled();
                    self.reset_scrollbar_fade(|d| ctx.request_timer(d), env);
                }
            }
        }
    }
pub fn handle_scroll ( & mut self , port : & mut Viewport , ctx : & mut EventCtx , event : & Event , env : & Env , ) { if ! ctx . is_handled ( ) { if let Event :: Wheel ( mouse ) = event { if port . pan_by ( mouse . wheel_delta ) { ctx . request_paint ( ) ; ctx . set_handled ( ) ; self . reset_scrollbar_fade ( | d | ctx . request_timer ( d ) , env ) ; } } } }
Applies mousewheel scrolling if the event has not already been handled
Applies mousewheel scrolling if the event has not already been handled
&mut self
port
&mut Viewport
ctx
&mut EventCtx
event
&Event
env
&Env
&mut self
port
&mut Viewport
ctx
&mut EventCtx
event
&Event
env
&Env