New InputSystem GamepadMouseCursor Sample is "upside down"

This took me a while to track down, but (at least on macOS) the GamepadMouseCursor Sample is sending the wrong coordinates to WarpCursorPosition, resulting in the OS cursor (the “hardware” cursor) being moved ‘upside down’ and the OS cursor not indicating the correct position of the Virtual Cursor.

Since it is the Virtual Cursor that sends the actual events (but is invisible), this means that while it LOOKS like the (OS) cursor is hovering a button, you are not hovering the button, and cannot press it.

I’m not allowed to insert a GIF? Check here for a recording → Imgur: The magic of the Internet

I have submitted a bug report: Case #1311064

I spotted another problem with the Gamepad Mouse Cursor Sample

As soon as you fill out a UI / Submit action (and binding) in the InputSystemUIInputModule, the buttons will register OnClick twice. Assuming you bind UI / Submit to Submit [Any], because that includes the Gamepad/SouthButton. (This is the default binding for new projects too)

When using a gamepad to move the Virtual Cursor and to click a button, it will be clicked by the virtual cursor (that is what the GamepadMouseCursorSample is for). But then it will also be clicked by the UI / Submit action. This can be avoided by not mapping UI / Submit, but binding Submit[Any] is a desirable setup.

Though it’s maybe not strictly a bug, I’ve submitted a bug report to make it easy to reproduce. (#1311114)

Is there any way with the new InputSystem where you can have things set up in a clean way with a working UI / Submit and a Virtual Mouse?

I am seeing similar issues with Virtual Mouse Position and Submit/Cancel events. The example Cursor & VirtualMouse CS code seems to have issues locating the parent Canvas. Watching this thread for updates. Additionally the Mouse Position and Virtual Mouse position do not seem to scale to the screen space correctly. Thanks.