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

[Fix] Remove memory leaks in ArmoireActivity by ending infinite animations in onPause #2103

Merged

Conversation

jsoberg
Copy link
Contributor

@jsoberg jsoberg commented Jan 25, 2025

On an orientation change, I noticed that LeakCanary was reporting Context memory leaks in ArmoireActivity:

Upon investigation, these leaks were coming from underlying views infinite animations maintaining ArmoireActivity's Context after it was destroyed. Ending/cancelling these infinite animations in ArmoireActivitys onPause removes these memory leaks, and animations still re-play on an orientation change. Here is a recording of an orientation change after these changes:

Screen_recording_20250125_113422.mp4

my Habitica User-ID: caef89d8-3a3d-4d3b-a5ad-67cb0455a56e

@phillipthelen phillipthelen merged commit 376c8b3 into HabitRPG:main Jan 30, 2025
4 checks passed
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.

2 participants