feat: add dispatch enable_monitor,disable_monitr,toggle_monitor

This commit is contained in:
DreamMaoMao
2025-10-30 13:30:02 +08:00
parent 181205df35
commit 27fdead702
4 changed files with 58 additions and 7 deletions

View File

@@ -439,7 +439,6 @@ struct Monitor {
Client *sel, *prevsel;
int isoverview;
int is_in_hotarea;
int gamma_lut_changed;
int asleep;
unsigned int visible_clients;
unsigned int visible_tiling_clients;
@@ -4050,7 +4049,6 @@ void powermgrsetmode(struct wl_listener *listener, void *data) {
if (!m)
return;
m->gamma_lut_changed = 1; /* Reapply gamma LUT when re-enabling the ouput */
wlr_output_state_set_enabled(&state, event->mode);
wlr_output_commit_state(m->wlr_output, &state);
@@ -5427,10 +5425,6 @@ void updatemons(struct wl_listener *listener, void *data) {
if ((c = focustop(m)) && c->isfullscreen)
resize(c, m->m, 0);
/* Try to re-set the gamma LUT when updating monitors,
* it's only really needed when enabling a disabled output, but meh.
*/
m->gamma_lut_changed = 1;
config_head->state.x = m->m.x;
config_head->state.y = m->m.y;