Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: prevent bar from changing mff #1175

Merged
merged 2 commits into from
Dec 14, 2024

Conversation

alex-ds13
Copy link
Contributor

This PR adds a helper function send_batch to komorebi-client that allows sending multiple messages in a batch. 3rd party users of this library could already do this themselves but it is nice to have this helper to simplify it.

Then, on komorebi-bar it makes use of the new send_batch function to batch all the messages in one go when pressing the button to move between workspaces or when moving between stacked windows.
Since we are creating this messages in one go we won't be mistakenly changing the value of mff for the user.
It also only batches the mff messages when the mff value it's true, if it is already false there is no need to be sending those extra messages.

This commit adds a helper function `send_batch` to komorebi-client that
allows sending multiple messages in a batch. 3rd party users of this
library could already do this themselves but it is nice to have this
helper to simplify it.
This commit makes use of the new `send_batch` function to batch all the
messages in one go when pressing the button to move between workspaces
or when moving between stacked windows.
Since we are creating this messages in one go we won't be mistakenly
chaning the value of mff for the user.
It also only batches the mff messages when the mff value it's true, if
it is already false there is no need to be sending those extra messages.
@LGUG2Z LGUG2Z merged commit 18eae96 into LGUG2Z:master Dec 14, 2024
6 checks passed
@alex-ds13 alex-ds13 deleted the fix/bar-changing-mff branch December 17, 2024 23:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants