diff options
author | Brian Ashworth <RedSoxFan@users.noreply.github.com> | 2018-07-29 22:03:53 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-29 22:03:53 -0400 |
commit | a3c33e93b80ffd3bd9f9c8dd9af9032ca578b726 (patch) | |
tree | f38b2d3a5c2f2b60804fdf00a05c238ea95bf20b /rootston/layer_shell.c | |
parent | 1c7957cdc1b9bc395510ab7decc1394c1bcd1206 (diff) | |
parent | 2e6eb097b6e23b8923bbfc68b1843d5ccde1955b (diff) |
Merge pull request #1167 from ammen99/master
rootston: focus newly-created surfaces
Diffstat (limited to 'rootston/layer_shell.c')
-rw-r--r-- | rootston/layer_shell.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/rootston/layer_shell.c b/rootston/layer_shell.c index ba69c3db..6795cb58 100644 --- a/rootston/layer_shell.c +++ b/rootston/layer_shell.c @@ -291,7 +291,10 @@ static void handle_map(struct wl_listener *listener, void *data) { static void handle_unmap(struct wl_listener *listener, void *data) { struct roots_layer_surface *layer = wl_container_of( listener, layer, unmap); + struct wlr_output *wlr_output = layer->layer_surface->output; + struct roots_output *output = wlr_output->data; unmap(layer->layer_surface); + input_update_cursor_focus(output->desktop->server->input); } static void popup_handle_map(struct wl_listener *listener, void *data) { @@ -303,6 +306,7 @@ static void popup_handle_map(struct wl_listener *listener, void *data) { int oy = popup->wlr_popup->geometry.y + layer->geo.y; output_damage_whole_local_surface(output, popup->wlr_popup->base->surface, ox, oy, 0); + input_update_cursor_focus(output->desktop->server->input); } static void popup_handle_unmap(struct wl_listener *listener, void *data) { |