godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.38k stars 21.26k forks source link

Adding a Window node disables the default cursor shape of sibling Control nodes #99621

Open cashew-olddew opened 1 day ago

cashew-olddew commented 1 day ago

Tested versions

System information

Windows 10 - Godot v4.3.stable.steam - Vulkan (Forward+)

Issue description

Normally, changing the default cursor shape of a control node will change the cursor shape while hovering that node. However, adding a Window node to the scene will disable that behavior and hovering any control node will only show the default arrow cursor until clicking the node, after which, the nodes start behaving normally again.

This seems to be a focus issue, because setting the window to unfocusable will make the mouse cursor transform normally while hovering control nodes.

Steps to reproduce

  1. Add a button to the scene with the Mouse > Default Cursor Shape property set to Pointing Hand.
  2. Run the game. Hover the button. The cursor should be a pointing hand.
  3. Add a Window node to the scene.
  4. Run the game. Hover the button. The cursor is now the default arrow head.
  5. Click the button. The cursor now transforms into what it is supposed to be: a pointing hand.

Minimal reproduction project (MRP)

MRP.zip

JuLongZhiLu commented 6 hours ago

Thank you for raising the issue. I have reproduced it. I will take some time to investigate this issue.

Sauermann commented 2 hours ago

Related to #93514, #50772 and #88678.