Skip to content

View "lifecycle" not handled correctly w.r.t handler that refreshes display text. #1

@curioustechizen

Description

@curioustechizen

The method startTaskForPeriodicallyUpdatingRelativeTime() is called both in onAttachedToWindow() and in onVisibilityChanged(). This could result in the Runnable being scheduled twice.

This is because the first time the RelativeTimeTextView is added to its parent, both onAttachedToWindow() and onVisibilityChanged() are called (the latter is called for the parent Window).

Metadata

Metadata

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions