aboutsummaryrefslogtreecommitdiff
path: root/sway/input/cursor.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/input/cursor.c')
-rw-r--r--sway/input/cursor.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index 15a61cbf..a19f0752 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -12,6 +12,7 @@
#include "sway/layers.h"
#include "sway/output.h"
#include "sway/tree/view.h"
+#include "sway/tree/workspace.h"
#include "wlr-layer-shell-unstable-v1-protocol.h"
static struct wlr_surface *layer_surface_at(struct sway_output *output,
@@ -83,6 +84,16 @@ static struct sway_container *container_at_cursor(struct sway_cursor *cursor,
ox, oy, sx, sy))) {
return ws;
}
+ if (ws->sway_workspace->fullscreen) {
+ struct wlr_surface *wlr_surface = ws->sway_workspace->fullscreen->surface;
+ if (wlr_surface_point_accepts_input(wlr_surface, ox, oy)) {
+ *sx = ox;
+ *sy = oy;
+ *surface = wlr_surface;
+ return ws->sway_workspace->fullscreen->swayc;
+ }
+ return NULL;
+ }
if ((*surface = layer_surface_at(output,
&output->layers[ZWLR_LAYER_SHELL_V1_LAYER_TOP],
ox, oy, sx, sy))) {