aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Brian Ashworth <bosrsf04@gmail.com>2019-08-06 05:33:06 -0400
committerLibravatar Drew DeVault <sir@cmpwn.com>2019-08-07 13:50:07 +0900
commit19d05d3ae0eb2545986c275341250845c84f0f30 (patch)
tree901a7bb3efc52c38fd6c9e72d64ab0eace48e4f7
parentcmd_mode: make modes case sensitive (diff)
downloadsway-19d05d3ae0eb2545986c275341250845c84f0f30.tar.gz
sway-19d05d3ae0eb2545986c275341250845c84f0f30.tar.zst
sway-19d05d3ae0eb2545986c275341250845c84f0f30.zip
config/output: rebase cursors after config applied
When applying an output config, an output may transform or be altered in some way that effects the cursor. In order for the cursor images to be updated properly, all cursors need to be rebased after applying output configs.
-rw-r--r--sway/config/output.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sway/config/output.c b/sway/config/output.c
index c41670d5..a96007fb 100644
--- a/sway/config/output.c
+++ b/sway/config/output.c
@@ -5,9 +5,11 @@
5#include <sys/socket.h> 5#include <sys/socket.h>
6#include <sys/wait.h> 6#include <sys/wait.h>
7#include <unistd.h> 7#include <unistd.h>
8#include <wlr/types/wlr_cursor.h>
8#include <wlr/types/wlr_output_layout.h> 9#include <wlr/types/wlr_output_layout.h>
9#include <wlr/types/wlr_output.h> 10#include <wlr/types/wlr_output.h>
10#include "sway/config.h" 11#include "sway/config.h"
12#include "sway/input/cursor.h"
11#include "sway/output.h" 13#include "sway/output.h"
12#include "sway/tree/root.h" 14#include "sway/tree/root.h"
13#include "log.h" 15#include "log.h"
@@ -455,6 +457,12 @@ void apply_output_config_to_outputs(struct output_config *oc) {
455 } 457 }
456 } 458 }
457 } 459 }
460
461 struct sway_seat *seat;
462 wl_list_for_each(seat, &server.input->seats, link) {
463 wlr_seat_pointer_clear_focus(seat->wlr_seat);
464 cursor_rebase(seat->cursor);
465 }
458} 466}
459 467
460void reset_outputs(void) { 468void reset_outputs(void) {