Skip to content

Commit

Permalink
Merge pull request iced-rs#2420 from myuujiku/master
Browse files Browse the repository at this point in the history
Fix: grabbing `image::Viewer` from outside the widget
  • Loading branch information
hecrj committed May 3, 2024
2 parents aae8e4f + 8efd32c commit fe240a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion widget/src/image/viewer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ where
event::Status::Captured
}
Event::Mouse(mouse::Event::ButtonPressed(mouse::Button::Left)) => {
let Some(cursor_position) = cursor.position() else {
let Some(cursor_position) = cursor.position_over(bounds) else {
return event::Status::Ignored;
};

Expand Down

0 comments on commit fe240a9

Please sign in to comment.