From 34dccd4224bc775980ea6181f404808229346288 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Thu, 9 Apr 2020 10:18:40 +0200 Subject: Don't add disabled outputs back to output layout Return early from apply_output_config if the output is disabled. This restores our previous behavior [1]. [1]: https://github.com/swaywm/sway/commit/0cdcf66bbccfeb1e3a8191cedd5f824bb27776a6#diff-4f65f4327e987fef8ec3796cdb07644eL349 --- sway/config/output.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sway/config/output.c b/sway/config/output.c index 8dfa8c57..19b9989a 100644 --- a/sway/config/output.c +++ b/sway/config/output.c @@ -425,6 +425,10 @@ bool apply_output_config(struct output_config *oc, struct sway_output *output) { return false; } + if (oc && !oc->enabled) { + return true; + } + if (config->reloading) { output_damage_whole(output); } @@ -464,7 +468,7 @@ bool apply_output_config(struct output_config *oc, struct sway_output *output) { output->width = output_box->width; output->height = output_box->height; - if ((!oc || oc->enabled) && !output->configured) { + if (!output->configured) { output_configure(output); } -- cgit v1.2.3