apply_anchor

Function apply_anchor 

Source
pub fn apply_anchor<K: VirtualizerKey>(
    v: &mut Virtualizer<K>,
    anchor: &ScrollAnchor<K>,
    key_to_index: impl FnMut(&K) -> Option<usize>,
) -> bool
Expand description

Applies a previously captured anchor by adjusting the scroll offset.

The adapter must provide a key_to_index mapping for the current dataset.

Returns true when the anchor was successfully applied.