Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve window cursor usability #7968

Closed
wants to merge 1 commit into from

Conversation

lewiszlw
Copy link
Member

@lewiszlw lewiszlw commented Mar 8, 2023

Objective

  • Let user can use pattern like below when creating window
...
cursor: Cursor {
    hit_test: true,
    ..default()
},
...
  • make hit_test default false

@james7132 james7132 added C-Bug An unexpected or incorrect behavior A-Windowing Platform-agnostic interface layer to run your app in labels Mar 8, 2023
@james7132
Copy link
Member

The physical_position field was deliberately made private in #7297. This seems like a regression there.

@lewiszlw
Copy link
Member Author

lewiszlw commented Mar 8, 2023

If not set physical_position field public, users can't create Cursor by themselves. I thought CursorBuilder will be a bit heavy, but the solution depends on you.

@lewiszlw
Copy link
Member Author

lewiszlw commented Mar 8, 2023

Maybe we can add comment to warn users not modify physical_position field directly.

@LiamGallagher737
Copy link
Member

I think we should add a Cursor::new(grab_mode, visible, hit_test, icon) method, currently if someone wants to modify the cursor of a window they have to construct it with Cursor::default() and then modify the field they want to change.

Example of someone experiencing this issue.
https://discord.com/channels/691052431525675048/1083143550738386984

@lewiszlw
Copy link
Member Author

lewiszlw commented Mar 9, 2023

Closing in favor of #7988.

@lewiszlw lewiszlw closed this Mar 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Windowing Platform-agnostic interface layer to run your app in C-Bug An unexpected or incorrect behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants