diff options
author | Drew DeVault <[email protected]> | 2016-03-30 07:41:13 -0400 |
---|---|---|
committer | Drew DeVault <[email protected]> | 2016-03-30 07:41:13 -0400 |
commit | 4bf10d77713f5ea9fdc05c084a26a5eb1d5bc3c5 (patch) | |
tree | ac04166d4e75b4cf7617705e31214f73f2398655 /sway/focus.c | |
parent | 3ffff5e4f246fd444b8059820825df42e627fef1 (diff) | |
parent | 0af55539a8afe38fa1a1beb6af15b0891030985a (diff) |
Merge pull request #551 from mikkeloscar/window-borders
Implement Window borders
Diffstat (limited to 'sway/focus.c')
-rw-r--r-- | sway/focus.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sway/focus.c b/sway/focus.c index 7f96eda7..0c9719b0 100644 --- a/sway/focus.c +++ b/sway/focus.c @@ -7,6 +7,7 @@ #include "config.h" #include "input_state.h" #include "ipc-server.h" +#include "border.h" bool locked_container_focus = false; bool locked_view_focus = false; @@ -28,6 +29,8 @@ static void update_focus(swayc_t *c) { // Case where output changes case C_OUTPUT: + // update borders for views in prev + container_map(prev, map_update_view_border, NULL); wlc_output_focus(c->handle); break; @@ -130,6 +133,7 @@ bool set_focused_container(swayc_t *c) { // unactivate previous focus if (focused->type == C_VIEW) { wlc_view_set_state(focused->handle, WLC_BIT_ACTIVATED, false); + update_view_border(focused); } // activate current focus if (p->type == C_VIEW) { @@ -137,6 +141,7 @@ bool set_focused_container(swayc_t *c) { // set focus if view_focus is unlocked if (!locked_view_focus) { wlc_view_focus(p->handle); + update_view_border(p); } } } else if (p->type == C_WORKSPACE) { |