mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2025-11-01 22:58:44 -04:00
feat: add global option edge_scroller_pointer_focus
This commit is contained in:
parent
ffba02fd59
commit
c7b0e2e6c8
4 changed files with 15 additions and 1 deletions
|
|
@ -167,6 +167,7 @@ typedef struct {
|
|||
float scroller_default_proportion_single;
|
||||
int scroller_focus_center;
|
||||
int scroller_prefer_center;
|
||||
int edge_scroller_pointer_focus;
|
||||
int focus_cross_monitor;
|
||||
int focus_cross_tag;
|
||||
int no_border_when_single;
|
||||
|
|
@ -938,6 +939,8 @@ void parse_config_line(Config *config, const char *line) {
|
|||
config->scroller_focus_center = atoi(value);
|
||||
} else if (strcmp(key, "scroller_prefer_center") == 0) {
|
||||
config->scroller_prefer_center = atoi(value);
|
||||
} else if (strcmp(key, "edge_scroller_pointer_focus") == 0) {
|
||||
config->edge_scroller_pointer_focus = atoi(value);
|
||||
} else if (strcmp(key, "focus_cross_monitor") == 0) {
|
||||
config->focus_cross_monitor = atoi(value);
|
||||
} else if (strcmp(key, "focus_cross_tag") == 0) {
|
||||
|
|
@ -2212,6 +2215,8 @@ void override_config(void) {
|
|||
CLAMP_FLOAT(config.scroller_default_proportion_single, 0.1f, 1.0f);
|
||||
scroller_focus_center = CLAMP_INT(config.scroller_focus_center, 0, 1);
|
||||
scroller_prefer_center = CLAMP_INT(config.scroller_prefer_center, 0, 1);
|
||||
edge_scroller_pointer_focus =
|
||||
CLAMP_INT(config.edge_scroller_pointer_focus, 0, 1);
|
||||
scroller_structs = CLAMP_INT(config.scroller_structs, 0, 1000);
|
||||
|
||||
// 主从布局设置
|
||||
|
|
@ -2384,6 +2389,7 @@ void set_value_default() {
|
|||
scroller_default_proportion_single;
|
||||
config.scroller_focus_center = scroller_focus_center;
|
||||
config.scroller_prefer_center = scroller_prefer_center;
|
||||
config.edge_scroller_pointer_focus = edge_scroller_pointer_focus;
|
||||
config.focus_cross_monitor = focus_cross_monitor;
|
||||
config.focus_cross_tag = focus_cross_tag;
|
||||
config.single_scratchpad = single_scratchpad;
|
||||
|
|
|
|||
|
|
@ -132,6 +132,7 @@ int disable_while_typing = 1;
|
|||
int left_handed = 0;
|
||||
int middle_button_emulation = 0;
|
||||
int single_scratchpad = 1;
|
||||
int edge_scroller_pointer_focus = 1;
|
||||
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_SCROLL_NO_SCROLL
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue