-
-
Notifications
You must be signed in to change notification settings - Fork 21k
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
InputEventMouseButton global_position becomes broken when window is resized #88460
Labels
Milestone
Comments
Please upload a project, to help with testing this and identifying the exact problem
|
@AThousandShips, sure, no problem. |
Happens since... v4.0.beta13.official [caacade]. Hence likely a regression from #69598. cc @Sauermann |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Tested versions
System information
MacOS 14.1.1 - Vulkan API 1.2.231 - Forward+ - Apple M1 Max
Issue description
Following methods return "system" mouse position values:
InputEventMouseButton.global_position
(left, pressed)While "scaled" mouse position values are returned by:
InputEventMouseMotion.global_position
CanvasItem.get_global_mouse_position
This happens only after resizing (or maximizing) a window.
Steps to reproduce
Display -> Window -> Stretch:
Scene with a control node. Override
_gui_input
method and logInputEventMouseMotion
andInputEventMouseButton
events together withget_global_mouse_position
result.Before resizing a window (InputEventMouseButtonB is the same as others):
After resizing a window (InputEventMouseButtonB is ~2x larger than others):
Where:
CanvasItem.get_global_mouse_position
InputEventMouseButton.global_position
(left, pressed)InputEventMouseMotion.global_position
Minimal reproduction project (MRP)
The text was updated successfully, but these errors were encountered: