pub trait Scrollable {
// Required methods
fn message_scroll_state(&mut self) -> &mut ScrollState;
fn task_scroll_state(&mut self) -> &mut ScrollState;
// Provided methods
fn scroll_up(&mut self, amount: usize) { ... }
fn scroll_down(&mut self, amount: usize) { ... }
fn auto_scroll_to_bottom(&mut self) { ... }
fn scroll_tasks_up(&mut self, amount: usize) { ... }
fn scroll_tasks_down(&mut self, amount: usize) { ... }
}Expand description
Interface for scrollable components
Required Methods§
Sourcefn message_scroll_state(&mut self) -> &mut ScrollState
fn message_scroll_state(&mut self) -> &mut ScrollState
Get a mutable reference to the message scroll state
Sourcefn task_scroll_state(&mut self) -> &mut ScrollState
fn task_scroll_state(&mut self) -> &mut ScrollState
Get a mutable reference to the task scroll state
Provided Methods§
Sourcefn scroll_down(&mut self, amount: usize)
fn scroll_down(&mut self, amount: usize)
Scroll message view down by amount
Sourcefn auto_scroll_to_bottom(&mut self)
fn auto_scroll_to_bottom(&mut self)
Auto scroll messages to bottom
Sourcefn scroll_tasks_up(&mut self, amount: usize)
fn scroll_tasks_up(&mut self, amount: usize)
Scroll task list up by amount
Sourcefn scroll_tasks_down(&mut self, amount: usize)
fn scroll_tasks_down(&mut self, amount: usize)
Scroll task list down by amount