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

Fixed a crash with the items list animations in Sample app #3801

Merged

Conversation

Sergio0694
Copy link
Member

Fixes #3701

PR Type

What kind of change does this PR introduce?

  • Bugfix (sample app)

What is the current behavior?

There is a crash in the items animations when looking for samples. This was unrelated from the actual animation APIs, and the crash was happening because the parent of the DropShadowPanel for each item was actually null if the items were being swapped by a text change while one was animated, so the animation was being invoked on null, resulting in a crash. I've just added two checks to skip the animation out in case the whole list is being refreshed, as the item containers would all be discarded anyway.

What is the new behavior?

The crash is fixed.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tested code with current supported SDKs
  • Pull Request has been submitted to the documentation repository instructions. Link:
  • Sample in sample app has been added / updated (for bug fixes / features)
  • New major technical changes in the toolkit have or will be added to the Wiki e.g. build changes, source generators, testing infrastructure, sample creation changes, etc...
  • Tests for the changes have been added (for bug fixes / features) (if applicable)
  • Header has been added to all new source files (run build/UpdateHeaders.bat)
  • Contains NO breaking changes

@ghost
Copy link

ghost commented Mar 2, 2021

Thanks Sergio0694 for opening a Pull Request! The reviewers will test the PR and highlight if there is any conflict or changes required. If the PR is approved we will proceed to merge the pull request 🙌

@ghost ghost added the bug 🐛 An unexpected issue that highlights incorrect behavior label Mar 2, 2021
@Sergio0694 Sergio0694 force-pushed the bugfix/sample-app-animation-crash branch from 0cdb1d7 to eb0c096 Compare March 2, 2021 21:51
Copy link
Contributor

@Kyaa-dost Kyaa-dost left a comment

Choose a reason for hiding this comment

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

Thanks @Sergio0694 ! Looks good to me 🚀

@ghost
Copy link

ghost commented Mar 2, 2021

Hello @Kyaa-dost!

Because this pull request has the auto merge :zap: label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

Do note that I've been instructed to only help merge pull requests of this repository that have been opened for at least 8 hours, a condition that will be fulfilled in about 6 hours 19 minutes. No worries though, I will be back when the time is right! 😉

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost merged commit 6ec8c8c into CommunityToolkit:master Mar 3, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sample App Crashes when Searching due to Animation on Item
3 participants