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

Stack windows correctly on non-zero x,y screens #1164

Merged
merged 1 commit into from
Oct 22, 2020
Merged

Conversation

jameskerr
Copy link
Member

Third try fix #1041

If a screen had an x or y that was not zero, some parts of the code broke. So we subtract the screen.x from the desired window.x, to effectively make the screen x and y both 0. Then all the math is easier. Then we add back the screen.x at the end.

Added more tests to fix the bugs in the comments of the ticket.

Copy link
Contributor

@mason-fish mason-fish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for including tests, helps understand the logic better!

@jameskerr jameskerr merged commit 4da1755 into master Oct 22, 2020
@jameskerr jameskerr deleted the big_window_fub branch October 22, 2020 22:20
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.

Offer a "Move Brim to Current Display" option
2 participants