mirror of
https://github.com/swaywm/sway.git
synced 2025-11-16 06:59:49 -05:00
transactions: Amend pending transactions
The transaction system contains a necessary optimization where a popped transaction is combined with later, similar transactions. This breaks the chronological order of states, and can lead to desynchronized geometries. To fix this, we replace the queue with only 2 transactions: current and pending. If a pending transaction exists, it is updated with new state instead of creating additional transactions. As we never have more than a single waiting transaction, we no longer need the queue optimization that is causing problems. Closes: https://github.com/swaywm/sway/issues/6012
This commit is contained in:
parent
b944735b47
commit
c8bf84c82d
3 changed files with 93 additions and 85 deletions
|
|
@ -199,7 +199,6 @@ bool server_init(struct sway_server *server) {
|
|||
}
|
||||
|
||||
server->dirty_nodes = create_list();
|
||||
server->transactions = create_list();
|
||||
|
||||
server->input = input_manager_create(server);
|
||||
input_manager_get_default_seat(); // create seat0
|
||||
|
|
@ -215,7 +214,6 @@ void server_fini(struct sway_server *server) {
|
|||
wl_display_destroy_clients(server->wl_display);
|
||||
wl_display_destroy(server->wl_display);
|
||||
list_free(server->dirty_nodes);
|
||||
list_free(server->transactions);
|
||||
}
|
||||
|
||||
bool server_start(struct sway_server *server) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue