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

Windows do not notice when mouse is released after they are closed #31

Closed
sdleffler opened this issue Jun 19, 2020 · 2 comments
Closed

Comments

@sdleffler
Copy link
Contributor

Hi! I have two windows, call them window A and window B. Window A contains a button which opens up window B. Window B is closable, so it has that nice lil X in the top right that you can click to make it buzz off. So, what's happening here is that I open window B from window A's button; then, I close window B. At this point, it appears that window B still thinks it is being dragged around; when I re-open window B using my button on window A, then whenever the cursor isn't hovering over window A, window B thinks it's getting dragged around. This causes some odd behavior. I think all that's needed to fix this is to set Instance.IsMoving = False on close; I'll test that shortly.

@sdleffler
Copy link
Contributor Author

sdleffler commented Jun 19, 2020

To clarify: clicking that wonderful little X causes window B to have its IsMoving flag set, as well as close it, at the same time. Because it is closed when the mouse is released, it doesn't have IsMoving unset until it is opened again and the mouse is pressed and released. And, after some testing it seems like adding ActiveInstance.IsMoving = false to the if clause which sets ActiveInstance.IsOpen = false on the window being closed does fix the issue. I'm not sure if this is the sort of solution that would be preferred here or if there's some other way that closed windows get notified of events though.

@coding-jackalope
Copy link
Collaborator

Thanks for reporting this issue. I integrated your fix and attributed you as the author for this fix. The commit can be found at 7836682. This will be deployed with the next update.

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

No branches or pull requests

2 participants