From 860f949846bbe03e5daeae725bc245fe6ad0da6a Mon Sep 17 00:00:00 2001 From: Wenhua Zhao Date: Sun, 29 Nov 2020 05:42:06 +0000 Subject: [PATCH] Do not overwrite cursor for app view --- src/cursor.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/cursor.c b/src/cursor.c index 74927512..4890c9ce 100644 --- a/src/cursor.c +++ b/src/cursor.c @@ -147,7 +147,7 @@ process_cursor_motion(struct server *server, uint32_t time) double sx, sy; struct wlr_seat *wlr_seat = server->seat.seat; struct wlr_surface *surface = NULL; - int view_area; + int view_area = LAB_DECO_NONE; char *cursor_name = NULL; struct view *view = desktop_view_at(server, server->seat.cursor->x, server->seat.cursor->y, @@ -188,7 +188,9 @@ process_cursor_motion(struct server *server, uint32_t time) cursor_name = "bottom_right_corner"; break; case 0: - cursor_name = view_area == LAB_DECO_NONE ? NULL: XCURSOR_DEFAULT; + if (view_area != LAB_DECO_NONE) { + cursor_name = XCURSOR_DEFAULT; + } break; } }