summaryrefslogtreecommitdiffstats
path: root/native/src/widget/toggler.rs
diff options
context:
space:
mode:
authorLibravatar Casper Storm <casper.storm@lich.io>2022-12-13 09:31:57 +0100
committerLibravatar Casper Storm <casper.storm@lich.io>2022-12-13 09:31:57 +0100
commit2e6d90f141217bad83eacd392562c13d7485881f (patch)
treebaa2c507076073aed4fd24abc9c7a7949d85c039 /native/src/widget/toggler.rs
parentba95042fff378213f5029b2b164d79e768482a47 (diff)
parent02182eea45537c9eb5b2bddfdff822bb8a3d143d (diff)
downloadiced-2e6d90f141217bad83eacd392562c13d7485881f.tar.gz
iced-2e6d90f141217bad83eacd392562c13d7485881f.tar.bz2
iced-2e6d90f141217bad83eacd392562c13d7485881f.zip
Merge branch 'master' into feat/slider-orientation
Diffstat (limited to 'native/src/widget/toggler.rs')
-rw-r--r--native/src/widget/toggler.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/native/src/widget/toggler.rs b/native/src/widget/toggler.rs
index 7893f78c..37cafd92 100644
--- a/native/src/widget/toggler.rs
+++ b/native/src/widget/toggler.rs
@@ -260,9 +260,9 @@ where
let is_mouse_over = bounds.contains(cursor_position);
let style = if is_mouse_over {
- theme.hovered(self.style, self.is_active)
+ theme.hovered(&self.style, self.is_active)
} else {
- theme.active(self.style, self.is_active)
+ theme.active(&self.style, self.is_active)
};
let border_radius = bounds.height as f32 / BORDER_RADIUS_RATIO;
@@ -278,7 +278,7 @@ where
renderer.fill_quad(
renderer::Quad {
bounds: toggler_background_bounds,
- border_radius,
+ border_radius: border_radius.into(),
border_width: 1.0,
border_color: style
.background_border
@@ -302,7 +302,7 @@ where
renderer.fill_quad(
renderer::Quad {
bounds: toggler_foreground_bounds,
- border_radius,
+ border_radius: border_radius.into(),
border_width: 1.0,
border_color: style
.foreground_border