Fix #142871: Two cursors visible when panning over a number button

Resolve regression in [0] where setting the cursor wasn't checking
if a software cursor was used. This would then show the hardware &
software cursors.

[0]: 232b106e64
This commit is contained in:
Campbell Barton
2025-08-10 16:59:57 +10:00
parent 388609e7a7
commit 0a9720a228

View File

@@ -8765,8 +8765,10 @@ GHOST_TSuccess GHOST_SystemWayland::cursor_shape_set(const GHOST_TStandardCursor
display_->wp.cursor_shape_manager, seat->wl.pointer);
}
if (seat->cursor.shape.device) {
wp_cursor_shape_device_v1_set_shape(
seat->cursor.shape.device, seat->pointer.serial, *wl_shape);
if (seat->cursor.is_hardware) {
wp_cursor_shape_device_v1_set_shape(
seat->cursor.shape.device, seat->pointer.serial, *wl_shape);
}
}
/* Set this to make sure we remember which shape we set when unhiding cursors. */
seat->cursor.shape.enum_id = *wl_shape;
@@ -8785,8 +8787,10 @@ GHOST_TSuccess GHOST_SystemWayland::cursor_shape_set(const GHOST_TStandardCursor
display_->wp.cursor_shape_manager, zwp_tablet_tool_v2);
}
if (tablet_tool->shape.device) {
wp_cursor_shape_device_v1_set_shape(
tablet_tool->shape.device, tablet_tool->serial, *wl_shape);
if (seat->cursor.is_hardware) {
wp_cursor_shape_device_v1_set_shape(
tablet_tool->shape.device, tablet_tool->serial, *wl_shape);
}
}
/* Set this to make sure we remember which shape we set when unhiding cursors. */
tablet_tool->shape.enum_id = *wl_shape;