We were using this library and noticed that it would leak the activity that contains the SnowfallView. This was due to the HandlerThread being an inner class, therefore having a reference to the view.
I also ensured that the thread is not started until the view is attached. And that we call quit() when detached.
I tested the changes with the sample app and the android studio memory analyser.
We were using this library and noticed that it would leak the activity that contains the
SnowfallView
. This was due to the HandlerThread being aninner
class, therefore having a reference to the view.I also ensured that the thread is not started until the view is attached. And that we call
quit()
when detached.I tested the changes with the sample app and the android studio memory analyser.