Guide API
Skip to main content

apply_scroll

Function apply_scroll 

Source
pub fn apply_scroll<L: ListViewer + ?Sized>(
    this: &mut L,
    h: Option<i32>,
    v: Option<i32>,
    ctx: &mut Context<'_>,
)
Expand description

The body of the scroll-bar-changed read-sync, called by the pump (the read broker) after it resolves both bars and reads their values.

The horizontal-bar branch refreshes the cached indent; the vertical-bar branch runs focus_item_num on the bar’s value. Reading both each sync is harmless — the vertical-bar write-back is a no-op in steady state.