-
-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GetDeskNumber fix, cleanup, and drop support for negative desks.
The function GetDeskNumber would not properly wrap more than once. For instance the command `GotoDesk 3 0 0` should return a desk between the minimum desk 0 and the maximum desk 0, but instead this would move the desk `2` from the current desk, because the wrapping code would only ever occur once. In fixing the issue, this also cleans up the logic in the GetDeskNumber function by better handling all the if cases and use the modulus function to do the wrapping. Last, support for negative desks is dropped, since it is not part of the EWMH spec.
- Loading branch information
1 parent
27ffd68
commit 3f39eb3
Showing
2 changed files
with
59 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters