Once the `UpdateTimeRunnable` is detached and the `weakRefRttv` cleared, it is never attached again
corneliudascalu opened this issue · comments
In the stopTaskForPeriodicallyUpdatingRelativeTime()
method, the mUpdateTimeTask
is detached, resulting in the weak reference that connects it the the RelativeTimeView being cleared. In the startTaskForPeriodicallyUpdatingRelativeTime()
method, the same mUpdateTimeTask
is reused, but the weak reference is still null. As a consequence, the run()
method in the runnable cannot update the text view.
It should be pretty easy to reproduce. Any action that results in the stopTaskForPeriodicallyUpdatingRelativeTime()
method being called should cause the time to stop being updated. For example, minimize the app and restore it.
@curioustechizen are you going to work on this? I can do a pull request with a fix within the hour.
@corneliudascalu Thanks for reporting this. Already working on it (the solution is as simple as creating a new instance of the UpdateTimeRunnable in startTaskForPeriodicallyUpdatingRelativeTime()
)
Fixed in master. I'll close this issue once this shows up as 1.3.4 in maven central.
Fixed in 1.3.4