Pause/Stop slideshow when CardsView not visible #34
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR aims to address issue #33 and add more resource management for the
CardsView
.CarouselProcessor
to combat the crash in the issue.CardsView
slideshows are now stopped & resumed depending on the state of theCardsView
's visibility (throughIsVisible
andOpacity
) to help prevent extra processing.CardsView
's handler is now disconnected on view unload to help cleanup resources/memory (in alignment with Microsoft's recommendations).CardsView
slideshows are now stopped on view unload/cleanup as I noticed that they were still processing when the view had been "destroyed". This should cleanup strong references that might have been preventing the GC from collecting the view.Platforms Tested