summaryrefslogtreecommitdiffstats
path: root/examples/bezier_tool
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2020-04-29 20:58:59 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2020-04-29 20:58:59 +0200
commit5d12e194f45b4a01034f3f52fae16c10bc0192dd (patch)
treeb2f566770daa8cf0206c92328b8b31074a79b8ab /examples/bezier_tool
parent70f86f998b6db102d5b77f756750414efd53aa9e (diff)
downloadiced-5d12e194f45b4a01034f3f52fae16c10bc0192dd.tar.gz
iced-5d12e194f45b4a01034f3f52fae16c10bc0192dd.tar.bz2
iced-5d12e194f45b4a01034f3f52fae16c10bc0192dd.zip
Rename `Cursor::*_position` methods in `canvas`
Diffstat (limited to 'examples/bezier_tool')
-rw-r--r--examples/bezier_tool/src/main.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/bezier_tool/src/main.rs b/examples/bezier_tool/src/main.rs
index 6473db75..3cecd058 100644
--- a/examples/bezier_tool/src/main.rs
+++ b/examples/bezier_tool/src/main.rs
@@ -110,7 +110,7 @@ mod bezier {
bounds: Rectangle,
cursor: Cursor,
) -> Option<Curve> {
- let cursor_position = cursor.internal_position(&bounds)?;
+ let cursor_position = cursor.position_in(&bounds)?;
match event {
Event::Mouse(mouse_event) => match mouse_event {
@@ -210,7 +210,7 @@ mod bezier {
fn draw(&self, bounds: Rectangle, cursor: Cursor) -> Geometry {
let mut frame = Frame::new(bounds.size());
- if let Some(cursor_position) = cursor.internal_position(&bounds) {
+ if let Some(cursor_position) = cursor.position_in(&bounds) {
match *self {
Pending::One { from } => {
let line = Path::line(from, cursor_position);