diff options
Diffstat (limited to 'sway/desktop/output.c')
-rw-r--r-- | sway/desktop/output.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sway/desktop/output.c b/sway/desktop/output.c index 5b7ad4ee..7bb9dab2 100644 --- a/sway/desktop/output.c +++ b/sway/desktop/output.c | |||
@@ -763,7 +763,7 @@ static void update_output_manager_config(struct sway_server *server) { | |||
763 | struct wlr_box output_box; | 763 | struct wlr_box output_box; |
764 | wlr_output_layout_get_box(root->output_layout, | 764 | wlr_output_layout_get_box(root->output_layout, |
765 | output->wlr_output, &output_box); | 765 | output->wlr_output, &output_box); |
766 | // We mark the output enabled even if it is switched off by DPMS | 766 | // We mark the output enabled when it's switched off but not disabled |
767 | config_head->state.enabled = output->current_mode != NULL && output->enabled; | 767 | config_head->state.enabled = output->current_mode != NULL && output->enabled; |
768 | config_head->state.mode = output->current_mode; | 768 | config_head->state.mode = output->current_mode; |
769 | if (!wlr_box_empty(&output_box)) { | 769 | if (!wlr_box_empty(&output_box)) { |
@@ -1028,10 +1028,10 @@ void handle_output_power_manager_set_mode(struct wl_listener *listener, | |||
1028 | struct output_config *oc = new_output_config(output->wlr_output->name); | 1028 | struct output_config *oc = new_output_config(output->wlr_output->name); |
1029 | switch (event->mode) { | 1029 | switch (event->mode) { |
1030 | case ZWLR_OUTPUT_POWER_V1_MODE_OFF: | 1030 | case ZWLR_OUTPUT_POWER_V1_MODE_OFF: |
1031 | oc->dpms_state = DPMS_OFF; | 1031 | oc->power = 0; |
1032 | break; | 1032 | break; |
1033 | case ZWLR_OUTPUT_POWER_V1_MODE_ON: | 1033 | case ZWLR_OUTPUT_POWER_V1_MODE_ON: |
1034 | oc->dpms_state = DPMS_ON; | 1034 | oc->power = 1; |
1035 | break; | 1035 | break; |
1036 | } | 1036 | } |
1037 | oc = store_output_config(oc); | 1037 | oc = store_output_config(oc); |