mirror of
https://github.com/labwc/labwc.git
synced 2026-02-08 10:06:59 -05:00
layers: handle top layer unmap/destroy better
On losing top layer focus, set focus on topmost mapped view.
This commit is contained in:
parent
5d6143449f
commit
a26fd5a75b
4 changed files with 47 additions and 2 deletions
|
|
@ -16,6 +16,7 @@
|
|||
#include <wlr/types/wlr_input_device.h>
|
||||
#include <wlr/types/wlr_keyboard.h>
|
||||
#include <wlr/types/wlr_keyboard_group.h>
|
||||
#include <wlr/types/wlr_layer_shell_v1.h>
|
||||
#include <wlr/types/wlr_matrix.h>
|
||||
#include <wlr/types/wlr_output.h>
|
||||
#include <wlr/types/wlr_output_layout.h>
|
||||
|
|
@ -58,6 +59,9 @@ struct seat {
|
|||
struct wlr_cursor *cursor;
|
||||
struct wlr_xcursor_manager *xcursor_manager;
|
||||
|
||||
/* if set, views cannot receive focus */
|
||||
struct wlr_layer_surface_v1 *focused_layer;
|
||||
|
||||
struct wl_list inputs;
|
||||
struct wl_listener new_input;
|
||||
|
||||
|
|
@ -244,6 +248,7 @@ void keyboard_init(struct seat *seat);
|
|||
void seat_init(struct server *server);
|
||||
void seat_finish(struct server *server);
|
||||
void seat_focus_surface(struct seat *seat, struct wlr_surface *surface);
|
||||
void seat_set_focus_layer(struct seat *seat, struct wlr_layer_surface_v1 *layer);
|
||||
|
||||
void interactive_begin(struct view *view, enum input_mode mode,
|
||||
uint32_t edges);
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ struct lab_layer_surface {
|
|||
|
||||
struct wl_listener destroy;
|
||||
struct wl_listener map;
|
||||
struct wl_listener unmap;
|
||||
struct wl_listener surface_commit;
|
||||
struct wl_listener output_destroy;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue