diff options
author | 2023-09-10 00:34:21 +0200 | |
---|---|---|
committer | 2023-09-10 00:34:21 +0200 | |
commit | b8e5693a3089d728b4f8d4b3b0b7197202ebd732 (patch) | |
tree | 79a9f84f9920525657fbe03d53ce33bab09053d7 /examples/toast | |
parent | 956512338905bac0b156fdaf16fe3c3e07e97a84 (diff) | |
parent | a3489e4af960388e9f73988b88df361022a654a4 (diff) | |
download | iced-b8e5693a3089d728b4f8d4b3b0b7197202ebd732.tar.gz iced-b8e5693a3089d728b4f8d4b3b0b7197202ebd732.tar.bz2 iced-b8e5693a3089d728b4f8d4b3b0b7197202ebd732.zip |
Merge branch 'master' into explicit-text-caching
Diffstat (limited to 'examples/toast')
-rw-r--r-- | examples/toast/Cargo.toml | 3 | ||||
-rw-r--r-- | examples/toast/src/main.rs | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/examples/toast/Cargo.toml b/examples/toast/Cargo.toml index f703572c..113313e2 100644 --- a/examples/toast/Cargo.toml +++ b/examples/toast/Cargo.toml @@ -6,4 +6,5 @@ edition = "2021" publish = false [dependencies] -iced = { path = "../..", features = ["advanced"] } +iced.workspace = true +iced.features = ["advanced"] diff --git a/examples/toast/src/main.rs b/examples/toast/src/main.rs index 50fa885a..8570a38e 100644 --- a/examples/toast/src/main.rs +++ b/examples/toast/src/main.rs @@ -1,10 +1,12 @@ +use iced::event::{self, Event}; use iced::executor; use iced::keyboard; -use iced::subscription::{self, Subscription}; use iced::widget::{ self, button, column, container, pick_list, row, slider, text, text_input, }; -use iced::{Alignment, Application, Command, Element, Event, Length, Settings}; +use iced::{ + Alignment, Application, Command, Element, Length, Settings, Subscription, +}; use toast::{Status, Toast}; @@ -57,7 +59,7 @@ impl Application for App { } fn subscription(&self) -> Subscription<Self::Message> { - subscription::events().map(Message::Event) + event::listen().map(Message::Event) } fn update(&mut self, message: Message) -> Command<Message> { |