Quantcast
Channel: Background task, progress dialog, orientation change - is there any 100% working solution? - Stack Overflow
Viewing all articles
Browse latest Browse all 9

Answer by Timmmm for Background task, progress dialog, orientation change - is there any 100% working solution?

$
0
0

The accepted answer was very helpful, but it doesn't have a progress dialog.

Fortunately for you, reader, I have created an extremely comprehensive and working example of an AsyncTask with a progress dialog!

  1. Rotation works, and the dialog survives.
  2. You can cancel the task and dialog by pressing the back button (if you want this behaviour).
  3. It uses fragments.
  4. The layout of the fragment underneath the activity changes properly when the device rotates.

Viewing all articles
Browse latest Browse all 9

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>