mirror of
https://github.com/swaywm/sway.git
synced 2025-11-24 06:59:51 -05:00
Remove output from layout
This commit is contained in:
parent
8764dc26c6
commit
4a14aa9ad9
3 changed files with 7 additions and 2 deletions
|
|
@ -91,12 +91,13 @@ static void set_mode(struct wlr_output *output, int width, int height,
|
|||
void apply_output_config(struct output_config *oc, swayc_t *output) {
|
||||
assert(output->type == C_OUTPUT);
|
||||
|
||||
struct wlr_output *wlr_output = output->sway_output->wlr_output;
|
||||
if (oc && oc->enabled == 0) {
|
||||
wlr_output_layout_remove(root_container.output_layout, wlr_output);
|
||||
destroy_output(output);
|
||||
return;
|
||||
}
|
||||
|
||||
struct wlr_output *wlr_output = output->sway_output->wlr_output;
|
||||
if (oc && oc->width > 0 && oc->height > 0) {
|
||||
set_mode(wlr_output, oc->width, oc->height, oc->refresh_rate);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue