aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
authorpml68 <contact@pml68.dev>2025-04-15 01:34:09 +0200
committerpml68 <contact@pml68.dev>2025-04-15 01:34:30 +0200
commitf30be43decc099f9f18cc28507cbd474d7fffc1c (patch)
tree962d63ba27dbfa0a08a75f3ed2f28a98987aabad /src/lib.rs
parentfeat: add `backdrop` method to dialog (diff)
downloadiced_dialog-f30be43decc099f9f18cc28507cbd474d7fffc1c.tar.gz
refactor!: move backdrop_color into `Style` struct
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 19cfd96..3c59699 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -30,6 +30,7 @@ where
/// [`Button`]: https://docs.rs/iced/0.13.1/iced/widget/struct.Button.html
pub fn button<'a, Message, Theme, Renderer>(
content: &'a str,
+ message: Message,
) -> Button<'a, Message, Theme, Renderer>
where
Theme: 'a + iced_widget::button::Catalog + text::Catalog,
@@ -41,6 +42,7 @@ where
.line_height(text::LineHeight::Absolute(core::Pixels(20.0)))
.align_x(Horizontal::Center),
)
+ .on_press(message)
.height(32)
.width(core::Length::Fill)
}