Fix set_custom_mouse_cursor changing to incorrect cursor shape
[Docs] Add class ref for Input::set_default_cursor_shape
This commit is contained in:
@ -2311,7 +2311,7 @@ void OS_Windows::set_custom_mouse_cursor(const RES &p_cursor, CursorShape p_shap
|
||||
|
||||
cursors[p_shape] = CreateIconIndirect(&iconinfo);
|
||||
|
||||
if (p_shape == CURSOR_ARROW) {
|
||||
if (p_shape == cursor_shape) {
|
||||
SetCursor(cursors[p_shape]);
|
||||
}
|
||||
|
||||
@ -2328,8 +2328,10 @@ void OS_Windows::set_custom_mouse_cursor(const RES &p_cursor, CursorShape p_shap
|
||||
} else {
|
||||
// Reset to default system cursor
|
||||
cursors[p_shape] = NULL;
|
||||
|
||||
CursorShape c = cursor_shape;
|
||||
cursor_shape = CURSOR_MAX;
|
||||
set_cursor_shape(p_shape);
|
||||
set_cursor_shape(c);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user