mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 07:56:31 +01:00
Use wlr_cursor_unset_image()
A bit cleaner. References: https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/4209
This commit is contained in:
parent
6f1a3b6652
commit
5411ed4ef0
1 changed files with 2 additions and 2 deletions
|
@ -252,7 +252,7 @@ void cursor_update_image(struct sway_cursor *cursor,
|
||||||
}
|
}
|
||||||
|
|
||||||
static void cursor_hide(struct sway_cursor *cursor) {
|
static void cursor_hide(struct sway_cursor *cursor) {
|
||||||
wlr_cursor_set_image(cursor->cursor, NULL, 0, 0, 0, 0, 0, 0);
|
wlr_cursor_unset_image(cursor->cursor);
|
||||||
cursor->hidden = true;
|
cursor->hidden = true;
|
||||||
wlr_seat_pointer_notify_clear_focus(cursor->seat->wlr_seat);
|
wlr_seat_pointer_notify_clear_focus(cursor->seat->wlr_seat);
|
||||||
}
|
}
|
||||||
|
@ -1068,7 +1068,7 @@ void cursor_set_image(struct sway_cursor *cursor, const char *image,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!image) {
|
if (!image) {
|
||||||
wlr_cursor_set_image(cursor->cursor, NULL, 0, 0, 0, 0, 0, 0);
|
wlr_cursor_unset_image(cursor->cursor);
|
||||||
} else if (!current_image || strcmp(current_image, image) != 0) {
|
} else if (!current_image || strcmp(current_image, image) != 0) {
|
||||||
wlr_cursor_set_xcursor(cursor->cursor, cursor->xcursor_manager, image);
|
wlr_cursor_set_xcursor(cursor->cursor, cursor->xcursor_manager, image);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue