aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-04-02 15:48:22 -0400
committerDrew DeVault <sir@cmpwn.com>2018-04-02 15:48:22 -0400
commita94f4d0edcdb54ac59b399df36273555f29ffc7d (patch)
tree2e17c0392a022cee61f0e507a43bad7523859cd9 /include
parent883d8d306c704a4bcc496402b2ce5f67934440c5 (diff)
Always give keyboard focus to the topmost layer
Diffstat (limited to 'include')
-rw-r--r--include/rootston/seat.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/rootston/seat.h b/include/rootston/seat.h
index 0b1dbe2d..0d8e1749 100644
--- a/include/rootston/seat.h
+++ b/include/rootston/seat.h
@@ -4,6 +4,7 @@
#include <wayland-server.h>
#include "rootston/input.h"
#include "rootston/keyboard.h"
+#include "rootston/layers.h"
struct roots_seat {
struct roots_input *input;
@@ -15,6 +16,9 @@ struct roots_seat {
int32_t touch_id;
double touch_x, touch_y;
+ // If the focused layer is set, views cannot receive keyboard focus
+ struct roots_layer_surface *focused_layer;
+
struct wl_list views; // roots_seat_view::link
bool has_focus;
@@ -100,6 +104,9 @@ struct roots_view *roots_seat_get_focus(struct roots_seat *seat);
void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view);
+void roots_seat_set_focus_layer(struct roots_seat *seat,
+ struct roots_layer_surface *layer);
+
void roots_seat_cycle_focus(struct roots_seat *seat);
void roots_seat_begin_move(struct roots_seat *seat, struct roots_view *view);