I create a ProgressDialog
in onCreateDialog()
like so:
protected Dialog onCreateDialog(int id) {
if (id == DIALOG_PROGRESS_ID)
Well, a not-so-cool workaround would to edit the parameters and not declaring the int private as in the examples. Of course, you lose the ability to switch on onCreateDialog, but you don't seem to be doing that anyway:
showDialog(++DIALOG_PROGRESS_ID);
Of course if the dialog is shown numerous times, you could have memory errors. Not pretty, but should work.