diff --git a/src/dispatch/bind_define.h b/src/dispatch/bind_define.h index 79ac35a..2b9591e 100644 --- a/src/dispatch/bind_define.h +++ b/src/dispatch/bind_define.h @@ -1604,7 +1604,7 @@ int32_t scroller_stack(const Arg *arg) { target_client->isglobal || target_client->isunglobal)) return 0; - if (!target_client) { + if (!target_client || target_client->mon != c->mon) { if (arg->i == LEFT || arg->i == UP) { exit_scroller_stack(c); wl_list_remove(&c->link); diff --git a/src/mango.c b/src/mango.c index 6eded61..f1941d1 100644 --- a/src/mango.c +++ b/src/mango.c @@ -4373,6 +4373,9 @@ void exchange_two_client(Client *c1, Client *c2, bool samemon) { if (samemon && c1->mon != c2->mon) return; + if(c1->mon != c2->mon && (c1->prev_in_stack || c2->prev_in_stack||c1->next_in_stack||c2->next_in_stack)) + return; + // 交换布局参数 master_inner_per = c1->master_inner_per; master_mfact_per = c1->master_mfact_per;