summaryrefslogtreecommitdiffstats
path: root/native/src/renderer/null.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2019-12-03 06:48:29 +0100
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2019-12-03 06:49:31 +0100
commit31e3b6fbcb06bd5e1e5773a7c2febd0cb0092819 (patch)
tree338f236209ece14ff75991ae93ec1695a96b57a3 /native/src/renderer/null.rs
parent6b25b4df2219460882f3d3c57da03d2e930e9d82 (diff)
downloadiced-31e3b6fbcb06bd5e1e5773a7c2febd0cb0092819.tar.gz
iced-31e3b6fbcb06bd5e1e5773a7c2febd0cb0092819.tar.bz2
iced-31e3b6fbcb06bd5e1e5773a7c2febd0cb0092819.zip
Unify logic by introducing `scrollable::Scrollbar`
Diffstat (limited to 'native/src/renderer/null.rs')
-rw-r--r--native/src/renderer/null.rs15
1 files changed, 5 insertions, 10 deletions
diff --git a/native/src/renderer/null.rs b/native/src/renderer/null.rs
index 2ce150c0..da0e5159 100644
--- a/native/src/renderer/null.rs
+++ b/native/src/renderer/null.rs
@@ -61,17 +61,13 @@ impl text::Renderer for Null {
}
impl scrollable::Renderer for Null {
- fn scrollbar_bounds(_bounds: Rectangle) -> Rectangle {
- Default::default()
- }
-
- fn scroller_bounds(
+ fn scrollbar(
+ &self,
_bounds: Rectangle,
_content_bounds: Rectangle,
- _scrollbar_bounds: Rectangle,
_offset: u32,
- ) -> Rectangle {
- Default::default()
+ ) -> Option<scrollable::Scrollbar> {
+ None
}
fn draw(
@@ -81,8 +77,7 @@ impl scrollable::Renderer for Null {
_content_bounds: Rectangle,
_is_mouse_over: bool,
_is_mouse_over_scrollbar: bool,
- _scrollbar_bounds: Rectangle,
- _scroller_bounds: Rectangle,
+ _scrollbar: Option<scrollable::Scrollbar>,
_offset: u32,
_content: Self::Output,
) {