summaryrefslogtreecommitdiffstats
path: root/examples/styling
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector@hecrj.dev>2024-09-11 00:30:56 +0200
committerLibravatar GitHub <noreply@github.com>2024-09-11 00:30:56 +0200
commit07c9a2a8a99ecd60c8cd0d1699d1d2c2e4a46c76 (patch)
tree2f244426201bba5be7c3d3d41f237d062ce722a6 /examples/styling
parent770176a4e19ef3db257daa311860b54a4ec14bc1 (diff)
parent6e4970c01a9e42621a0ded340dcdccb4204ab5d2 (diff)
downloadiced-07c9a2a8a99ecd60c8cd0d1699d1d2c2e4a46c76.tar.gz
iced-07c9a2a8a99ecd60c8cd0d1699d1d2c2e4a46c76.tar.bz2
iced-07c9a2a8a99ecd60c8cd0d1699d1d2c2e4a46c76.zip
Merge pull request #2478 from sundaram123krishnan/master
Add Disable Feature to Toggler Widget
Diffstat (limited to 'examples/styling')
-rw-r--r--examples/styling/src/main.rs10
1 files changed, 4 insertions, 6 deletions
diff --git a/examples/styling/src/main.rs b/examples/styling/src/main.rs
index e19d5cf7..534f5e32 100644
--- a/examples/styling/src/main.rs
+++ b/examples/styling/src/main.rs
@@ -77,12 +77,10 @@ impl Styling {
let checkbox = checkbox("Check me!", self.checkbox_value)
.on_toggle(Message::CheckboxToggled);
- let toggler = toggler(
- Some("Toggle me!"),
- self.toggler_value,
- Message::TogglerToggled,
- )
- .spacing(10);
+ let toggler = toggler(self.toggler_value)
+ .label("Toggle me!")
+ .on_toggle(Message::TogglerToggled)
+ .spacing(10);
let content = column![
choose_theme,