mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-05-26 21:37:31 -04:00
fix: ensure the global link own same order like scroller tag link
This commit is contained in:
parent
9ad13841b3
commit
3b4c4aeca0
1 changed files with 6 additions and 2 deletions
|
|
@ -767,12 +767,16 @@ void scroller_insert_stack(Client *c, Client *target_client,
|
||||||
if (tnode->prev_in_stack)
|
if (tnode->prev_in_stack)
|
||||||
tnode->prev_in_stack->next_in_stack = newnode;
|
tnode->prev_in_stack->next_in_stack = newnode;
|
||||||
tnode->prev_in_stack = newnode;
|
tnode->prev_in_stack = newnode;
|
||||||
|
wl_list_remove(&c->link);
|
||||||
|
wl_list_insert(tnode->client->link.prev, &c->link);
|
||||||
} else {
|
} else {
|
||||||
newnode->prev_in_stack = tnode;
|
newnode->prev_in_stack = tnode;
|
||||||
newnode->next_in_stack = tnode->next_in_stack;
|
newnode->next_in_stack = tnode->next_in_stack;
|
||||||
if (tnode->next_in_stack)
|
if (tnode->next_in_stack)
|
||||||
tnode->next_in_stack->prev_in_stack = newnode;
|
tnode->next_in_stack->prev_in_stack = newnode;
|
||||||
tnode->next_in_stack = newnode;
|
tnode->next_in_stack = newnode;
|
||||||
|
wl_list_remove(&c->link);
|
||||||
|
wl_list_insert(&tnode->client->link, &c->link);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 处理堆叠头部的全屏/最大化状态*/
|
/* 处理堆叠头部的全屏/最大化状态*/
|
||||||
|
|
@ -817,7 +821,7 @@ void scroller_drop_tile(Client *c, Client *closest, int vertical) {
|
||||||
} else if (closest->drop_direction == DOWN) {
|
} else if (closest->drop_direction == DOWN) {
|
||||||
if (c != stack_tail) {
|
if (c != stack_tail) {
|
||||||
wl_list_remove(&c->link);
|
wl_list_remove(&c->link);
|
||||||
wl_list_insert(&stack_head->link, &c->link);
|
wl_list_insert(&stack_tail->link, &c->link);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -837,7 +841,7 @@ void scroller_drop_tile(Client *c, Client *closest, int vertical) {
|
||||||
} else if (closest->drop_direction == RIGHT) {
|
} else if (closest->drop_direction == RIGHT) {
|
||||||
if (c != stack_tail) {
|
if (c != stack_tail) {
|
||||||
wl_list_remove(&c->link);
|
wl_list_remove(&c->link);
|
||||||
wl_list_insert(&stack_head->link, &c->link);
|
wl_list_insert(&stack_tail->link, &c->link);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue