summaryrefslogtreecommitdiffstats
path: root/examples/custom_quad
diff options
context:
space:
mode:
Diffstat (limited to 'examples/custom_quad')
-rw-r--r--examples/custom_quad/Cargo.toml3
-rw-r--r--examples/custom_quad/src/main.rs11
2 files changed, 7 insertions, 7 deletions
diff --git a/examples/custom_quad/Cargo.toml b/examples/custom_quad/Cargo.toml
index 39154786..f097c2dd 100644
--- a/examples/custom_quad/Cargo.toml
+++ b/examples/custom_quad/Cargo.toml
@@ -6,5 +6,4 @@ edition = "2021"
publish = false
[dependencies]
-iced = { path = "../.." }
-iced_native = { path = "../../native" }
+iced = { path = "../..", features = ["advanced"] }
diff --git a/examples/custom_quad/src/main.rs b/examples/custom_quad/src/main.rs
index 6509887c..4b300116 100644
--- a/examples/custom_quad/src/main.rs
+++ b/examples/custom_quad/src/main.rs
@@ -1,9 +1,10 @@
//! This example showcases a drawing a quad.
mod quad {
- use iced_native::layout::{self, Layout};
- use iced_native::renderer;
- use iced_native::widget::{self, Widget};
- use iced_native::{Color, Element, Length, Point, Rectangle, Size};
+ use iced::advanced::layout::{self, Layout};
+ use iced::advanced::renderer;
+ use iced::advanced::widget::{self, Widget};
+ use iced::mouse;
+ use iced::{Color, Element, Length, Rectangle, Size};
pub struct CustomQuad {
size: f32,
@@ -48,7 +49,7 @@ mod quad {
_theme: &Renderer::Theme,
_style: &renderer::Style,
layout: Layout<'_>,
- _cursor_position: Point,
+ _cursor: mouse::Cursor,
_viewport: &Rectangle,
) {
renderer.fill_quad(