feat: add option scratchpad_cross_monitor

This commit is contained in:
DreamMaoMao 2025-09-24 19:35:12 +08:00
parent eb0395a48d
commit 3a21ef8801
6 changed files with 57 additions and 8 deletions

View file

@ -174,6 +174,7 @@ typedef struct {
int edge_scroller_pointer_focus;
int focus_cross_monitor;
int exchange_cross_monitor;
int scratchpad_cross_monitor;
int focus_cross_tag;
int view_current_to_back;
int no_border_when_single;
@ -980,6 +981,8 @@ void parse_config_line(Config *config, const char *line) {
config->focus_cross_monitor = atoi(value);
} else if (strcmp(key, "exchange_cross_monitor") == 0) {
config->exchange_cross_monitor = atoi(value);
} else if (strcmp(key, "scratchpad_cross_monitor") == 0) {
config->scratchpad_cross_monitor = atoi(value);
} else if (strcmp(key, "focus_cross_tag") == 0) {
config->focus_cross_tag = atoi(value);
} else if (strcmp(key, "view_current_to_back") == 0) {
@ -2363,6 +2366,7 @@ void override_config(void) {
warpcursor = CLAMP_INT(config.warpcursor, 0, 1);
focus_cross_monitor = CLAMP_INT(config.focus_cross_monitor, 0, 1);
exchange_cross_monitor = CLAMP_INT(config.exchange_cross_monitor, 0, 1);
scratchpad_cross_monitor = CLAMP_INT(config.scratchpad_cross_monitor, 0, 1);
focus_cross_tag = CLAMP_INT(config.focus_cross_tag, 0, 1);
view_current_to_back = CLAMP_INT(config.view_current_to_back, 0, 1);
enable_floating_snap = CLAMP_INT(config.enable_floating_snap, 0, 1);
@ -2513,6 +2517,7 @@ void set_value_default() {
config.edge_scroller_pointer_focus = edge_scroller_pointer_focus;
config.focus_cross_monitor = focus_cross_monitor;
config.exchange_cross_monitor = exchange_cross_monitor;
config.scratchpad_cross_monitor = scratchpad_cross_monitor;
config.focus_cross_tag = focus_cross_tag;
config.view_current_to_back = view_current_to_back;
config.single_scratchpad = single_scratchpad;