diff options
| author | 2023-03-09 19:05:38 +0100 | |
|---|---|---|
| committer | 2023-03-09 19:05:38 +0100 | |
| commit | caf2836b1b15bff6e8a2ea72441d67f297eb8707 (patch) | |
| tree | 0ffa0d1d604780999892b88de85ee93e3ed7d539 /examples/events | |
| parent | 11b2c3bbe31a43e73a61b9bd9f022233f302ae27 (diff) | |
| parent | 424ac8177309440bbd8efe0dd9f7622cb10807ce (diff) | |
| download | iced-caf2836b1b15bff6e8a2ea72441d67f297eb8707.tar.gz iced-caf2836b1b15bff6e8a2ea72441d67f297eb8707.tar.bz2 iced-caf2836b1b15bff6e8a2ea72441d67f297eb8707.zip  | |
Merge pull request #1748 from iced-rs/feature/software-renderer
Software renderer, runtime renderer fallback, and core consolidation
Diffstat (limited to 'examples/events')
| -rw-r--r-- | examples/events/Cargo.toml | 1 | ||||
| -rw-r--r-- | examples/events/src/main.rs | 9 | 
2 files changed, 5 insertions, 5 deletions
diff --git a/examples/events/Cargo.toml b/examples/events/Cargo.toml index 8c56e471..15ffc0af 100644 --- a/examples/events/Cargo.toml +++ b/examples/events/Cargo.toml @@ -7,4 +7,3 @@ publish = false  [dependencies]  iced = { path = "../..", features = ["debug"] } -iced_native = { path = "../../native" } diff --git a/examples/events/src/main.rs b/examples/events/src/main.rs index 1b97018e..7f3a5e1d 100644 --- a/examples/events/src/main.rs +++ b/examples/events/src/main.rs @@ -1,12 +1,13 @@  use iced::alignment;  use iced::executor; +use iced::subscription;  use iced::widget::{button, checkbox, container, text, Column};  use iced::window; +use iced::Event;  use iced::{      Alignment, Application, Command, Element, Length, Settings, Subscription,      Theme,  }; -use iced_native::Event;  pub fn main() -> iced::Result {      Events::run(Settings { @@ -17,13 +18,13 @@ pub fn main() -> iced::Result {  #[derive(Debug, Default)]  struct Events { -    last: Vec<iced_native::Event>, +    last: Vec<Event>,      enabled: bool,  }  #[derive(Debug, Clone)]  enum Message { -    EventOccurred(iced_native::Event), +    EventOccurred(Event),      Toggled(bool),      Exit,  } @@ -70,7 +71,7 @@ impl Application for Events {      }      fn subscription(&self) -> Subscription<Message> { -        iced_native::subscription::events().map(Message::EventOccurred) +        subscription::events().map(Message::EventOccurred)      }      fn view(&self) -> Element<Message> {  | 
