summaryrefslogtreecommitdiffstats
path: root/examples/geometry
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-06-08 20:16:46 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-06-08 20:16:46 +0200
commit5c8cfb411ed0a9a6e55bd1193cd7e97252e63d28 (patch)
treeb4f6ae33729d3ddc0d8c529a54f401fec305f00a /examples/geometry
parent34451bff185d8875f55747ee97ed746828e30f40 (diff)
downloadiced-5c8cfb411ed0a9a6e55bd1193cd7e97252e63d28.tar.gz
iced-5c8cfb411ed0a9a6e55bd1193cd7e97252e63d28.tar.bz2
iced-5c8cfb411ed0a9a6e55bd1193cd7e97252e63d28.zip
Take `Rectangle` by value in `Cursor` API
Diffstat (limited to 'examples/geometry')
-rw-r--r--examples/geometry/src/main.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/geometry/src/main.rs b/examples/geometry/src/main.rs
index 1f949d10..29f78ea1 100644
--- a/examples/geometry/src/main.rs
+++ b/examples/geometry/src/main.rs
@@ -62,7 +62,7 @@ mod rainbow {
let color_v = [0.75, 0.0, 0.5, 1.0];
let posn_center = {
- if let Some(cursor_position) = cursor.position_in(&bounds) {
+ if let Some(cursor_position) = cursor.position_in(bounds) {
[cursor_position.x, cursor_position.y]
} else {
[bounds.width / 2.0, bounds.height / 2.0]