summaryrefslogtreecommitdiffstats
path: root/examples/url_handler
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-03-04 05:37:11 +0100
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-03-04 05:37:11 +0100
commit3a0d34c0240f4421737a6a08761f99d6f8140d02 (patch)
treec9a4a6b8e9c1db1b8fcd05bc98e3f131d5ef4bd5 /examples/url_handler
parentc54409d1711e1f615c7ea4b02c082954e340632a (diff)
downloadiced-3a0d34c0240f4421737a6a08761f99d6f8140d02.tar.gz
iced-3a0d34c0240f4421737a6a08761f99d6f8140d02.tar.bz2
iced-3a0d34c0240f4421737a6a08761f99d6f8140d02.zip
Create `iced_widget` subcrate and re-organize the whole codebase
Diffstat (limited to 'examples/url_handler')
-rw-r--r--examples/url_handler/Cargo.toml1
-rw-r--r--examples/url_handler/src/main.rs10
2 files changed, 4 insertions, 7 deletions
diff --git a/examples/url_handler/Cargo.toml b/examples/url_handler/Cargo.toml
index 63c7ec27..4dcff92d 100644
--- a/examples/url_handler/Cargo.toml
+++ b/examples/url_handler/Cargo.toml
@@ -7,4 +7,3 @@ publish = false
[dependencies]
iced = { path = "../.." }
-iced_native = { path = "../../native" }
diff --git a/examples/url_handler/src/main.rs b/examples/url_handler/src/main.rs
index 3257b519..f63fa06a 100644
--- a/examples/url_handler/src/main.rs
+++ b/examples/url_handler/src/main.rs
@@ -1,12 +1,10 @@
+use iced::event::{Event, MacOS, PlatformSpecific};
use iced::executor;
+use iced::subscription;
use iced::widget::{container, text};
use iced::{
Application, Command, Element, Length, Settings, Subscription, Theme,
};
-use iced_native::{
- event::{MacOS, PlatformSpecific},
- Event,
-};
pub fn main() -> iced::Result {
App::run(Settings::default())
@@ -19,7 +17,7 @@ struct App {
#[derive(Debug, Clone)]
enum Message {
- EventOccurred(iced_native::Event),
+ EventOccurred(Event),
}
impl Application for App {
@@ -52,7 +50,7 @@ impl Application for App {
}
fn subscription(&self) -> Subscription<Message> {
- iced_native::subscription::events().map(Message::EventOccurred)
+ subscription::events().map(Message::EventOccurred)
}
fn view(&self) -> Element<Message> {