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

#1484, #1527: Fix overlay transition #1528

Merged
merged 2 commits into from
Nov 15, 2022

Conversation

mtkennerly
Copy link
Contributor

This fixes #1484 and #1527, at least on my system (Windows 11).

⚠️ I don't really understand what I did here! ⚠️

I just figured it seemed like the old overlay was being held onto, and so I tried to find where it might need to be flushed. This works, but I haven't studied the other user_interface code to see how this aligns with the rest of the design, so I don't know if it's a good/correct solution.

I tested the pick_list and tour examples with this change. Here's a modified pick_list to show the new behavior:

UiGZ2tk8E6.mp4

@hecrj hecrj added bug Something isn't working widget shell labels Nov 13, 2022
@hecrj hecrj added this to the 0.6.0 milestone Nov 13, 2022
Copy link
Member

@hecrj hecrj 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 taking a look!

This bug has been alive for a while. Basically, the issue is that the active overlay may change after an Event in the base layer is processed. Reusing the layout of the old overlay is incorrect in that case!

Your initial fix consisted in always invalidating the cache of the overlay layout. I changed it in bbd55ff so we only invalidate when an Event in the base layer is Captured, which I believe is reasonable.

Hopefully this still works!

@mtkennerly
Copy link
Contributor Author

Hopefully this still works!

Looks good on my end :D Thanks!

@hecrj hecrj merged commit 042020b into iced-rs:master Nov 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working shell widget
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Switching between two pick lists is not seamless
2 participants