add ThreadNote::set_scroll_offset
Signed-off-by: kernelkind <kernelkind@gmail.com>
This commit is contained in:
@@ -23,6 +23,7 @@ pub struct ThreadNode {
|
|||||||
pub prev: ParentState,
|
pub prev: ParentState,
|
||||||
pub have_all_ancestors: bool,
|
pub have_all_ancestors: bool,
|
||||||
pub list: VirtualList,
|
pub list: VirtualList,
|
||||||
|
pub set_scroll_offset: Option<f32>,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone)]
|
#[derive(Clone)]
|
||||||
@@ -132,8 +133,14 @@ impl ThreadNode {
|
|||||||
prev: parent,
|
prev: parent,
|
||||||
have_all_ancestors: false,
|
have_all_ancestors: false,
|
||||||
list: VirtualList::new(),
|
list: VirtualList::new(),
|
||||||
|
set_scroll_offset: None,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn with_offset(mut self, offset: f32) -> Self {
|
||||||
|
self.set_scroll_offset = Some(offset);
|
||||||
|
self
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Default)]
|
#[derive(Default)]
|
||||||
|
|||||||
Reference in New Issue
Block a user