Skip to content

Commit

Permalink
Scroll behavior component (#1107)
Browse files Browse the repository at this point in the history
* Naive first step to refactor out scroll logic into separate component

* Move a bunch of event logic to `scroll_component` from `Scroll`

* Add method to coordinate painting with `scroll_component`

* Move a bunch of lifecycle logic to `scroll_component` from `Scroll`

* Documentation pass on `scroll_component`

* Rename `Scroll` to `AbsoluteScroll` & add scroll functionality to `List`

* Add ability to change layout axis for `List` with builder fn

* Scroll behavior component changelog

* Pass `BarHoveredState` by value and add impl Default for ScrollComponent

* `ScrollComponent` review changes

* Add some missing information to `ScrollComponent` documentation

* `ScrollContainer` review take 2

* Changes from #1057

* ScrollComponent clippy

* Remove List changes (updated to master) & fix Scroll regression

* Add missing doc comments

* Be a bit more careful about event consuming

* Fix dup changelog entry & doc comment misspelling
  • Loading branch information
ForLoveOfCats authored Sep 6, 2020
1 parent a24c82f commit f0105b9
Show file tree
Hide file tree
Showing 5 changed files with 553 additions and 381 deletions.
3 changes: 2 additions & 1 deletion AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ Kaiyin Zhong
Kaur Kuut
Leopold Luley
Andrey Kabylin
Robert Wittams
Garrett Risley
Robert Wittams
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ You can find its changes [documented below](#060---2020-06-01).
- Export `Image` and `ImageData` by default. ([#1011] by [@covercash2])
- Re-export `druid_shell::Scalable` under `druid` namespace. ([#1075] by [@ForLoveOfCats])
- `TextBox` now supports ctrl and shift hotkeys. ([#1076] by [@vkahl])
- `ScrollComponent` for ease of adding consistent, customized, scrolling behavior to a widget. ([#1107] by [@ForLoveOfCats])
- Selection text color to textbox. ([#1093] by [@sysint64])
- `BoxConstraints::UNBOUNDED` constant. ([#1126] by [@danieldulaney])
- Close requests from the shell can now be intercepted ([#1118] by [@jneem])
Expand Down Expand Up @@ -396,6 +397,7 @@ Last release without a changelog :(
[#1093]: https://github.com/linebender/druid/pull/1093
[#1100]: https://github.com/linebender/druid/pull/1100
[#1103]: https://github.com/linebender/druid/pull/1103
[#1107]: https://github.com/linebender/druid/pull/1107
[#1118]: https://github.com/linebender/druid/pull/1118
[#1119]: https://github.com/linebender/druid/pull/1119
[#1120]: https://github.com/linebender/druid/pull/1120
Expand Down
1 change: 1 addition & 0 deletions druid/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ pub mod lens;
mod localization;
mod menu;
mod mouse;
pub mod scroll_component;
#[cfg(not(target_arch = "wasm32"))]
#[cfg(test)]
mod tests;
Expand Down
Loading

0 comments on commit f0105b9

Please sign in to comment.