I am trying to create a custom loading dialog that displays an animated “loading wheel”, but I cant seem to figure out which method to call AnimationDrawable.start() in order to automatically start the animation in the DialogFragment.
The only documentation I found addresses calling it in onWindowFocusChanged(). Does anyone know what is the appropriate method is to call in a DialogFragment?
Figured it out. Turns out what I was using was correct all along. The reason it wasn’t showing was because the ImageView in the layout was being covered by a TextView.
To start an animation in a DialogFragment, override the onStart() method of the DialogFragment as it is typically called when the activity’s onStart() method is called.