diff options
author | emersion <contact@emersion.fr> | 2018-09-01 18:56:53 +0200 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2018-09-01 18:56:53 +0200 |
commit | 349d1f3be87ad9fd49482f64c71eb2665750261b (patch) | |
tree | f3f31dfb8145dc76031c784f68b551bd8b3f8d82 /sway/config | |
parent | Merge pull request #2547 from RyanDwyer/fix-reload-crash (diff) | |
download | sway-349d1f3be87ad9fd49482f64c71eb2665750261b.tar.gz sway-349d1f3be87ad9fd49482f64c71eb2665750261b.tar.zst sway-349d1f3be87ad9fd49482f64c71eb2665750261b.zip |
Do not modeset disabled outputs
Diffstat (limited to 'sway/config')
-rw-r--r-- | sway/config/output.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/config/output.c b/sway/config/output.c index 16ec9339..65f09258 100644 --- a/sway/config/output.c +++ b/sway/config/output.c | |||
@@ -196,6 +196,10 @@ void apply_output_config(struct output_config *oc, struct sway_container *output | |||
196 | wlr_log(WLR_DEBUG, "Set %s mode to %dx%d (%f GHz)", oc->name, oc->width, | 196 | wlr_log(WLR_DEBUG, "Set %s mode to %dx%d (%f GHz)", oc->name, oc->width, |
197 | oc->height, oc->refresh_rate); | 197 | oc->height, oc->refresh_rate); |
198 | set_mode(wlr_output, oc->width, oc->height, oc->refresh_rate); | 198 | set_mode(wlr_output, oc->width, oc->height, oc->refresh_rate); |
199 | } else if (!wl_list_empty(&wlr_output->modes)) { | ||
200 | struct wlr_output_mode *mode = | ||
201 | wl_container_of(wlr_output->modes.prev, mode, link); | ||
202 | wlr_output_set_mode(wlr_output, mode); | ||
199 | } | 203 | } |
200 | if (oc && oc->scale > 0) { | 204 | if (oc && oc->scale > 0) { |
201 | wlr_log(WLR_DEBUG, "Set %s scale to %f", oc->name, oc->scale); | 205 | wlr_log(WLR_DEBUG, "Set %s scale to %f", oc->name, oc->scale); |