Implement scroll_by operation for scrollable

`scroll_by` allows scrolling an absolute offset
that is applied to the current scrolling position.
This commit is contained in:
lufte 2024-05-10 18:50:10 -03:00 committed by Héctor Ramón Jiménez
parent 44235f0c0b
commit e102e89c6a
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
5 changed files with 157 additions and 36 deletions

View file

@ -459,6 +459,7 @@ pub fn visible_bounds(id: Id) -> Task<Option<Rectangle>> {
_state: &mut dyn widget::operation::Scrollable,
_id: Option<&widget::Id>,
bounds: Rectangle,
_content_bounds: Rectangle,
translation: Vector,
) {
match self.scrollables.last() {