java.lang.Object | |||
↳ | android.app.Dialog | ||
↳ | android.app.AlertDialog | ||
↳ | android.app.ProgressDialog |
A dialog showing a progress indicator and an optional text message or view. Only a text message or a view can be used at the same time.
The dialog can be made cancelable on back key press.
The progress range is 0..10000.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | STYLE_HORIZONTAL | Creates a ProgressDialog with a horizontal progress bar. | |||||||||
int | STYLE_SPINNER | Creates a ProgressDialog with a circular, spinning progress bar. |
[Expand]
Inherited Constants
|
|||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
android.app.AlertDialog
|
|||||||||||
From interface
android.content.DialogInterface
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
|
||||||||||
|
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
Called when the dialog is starting.
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
Change the format of the small text showing current and maximum units
of progress.
|
||||||||||
|
Change the format of the small text showing the percentage of progress.
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
||||||||||
|
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
Similar to
onCreate(Bundle)
, you should initialize your dialog
in this method, including calling
setContentView(View)
.
|
||||||||||
|
Called to tell you that you're stopping.
|
[Expand]
Inherited Methods
|
|||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
android.app.AlertDialog
|
|||||||||||
From class
android.app.Dialog
|
|||||||||||
From class
java.lang.Object
|
|||||||||||
From interface
android.content.DialogInterface
|
|||||||||||
From interface
android.view.KeyEvent.Callback
|
|||||||||||
From interface
android.view.View.OnCreateContextMenuListener
|
|||||||||||
From interface
android.view.Window.Callback
|
Creates a ProgressDialog with a horizontal progress bar.
Creates a ProgressDialog with a circular, spinning progress bar. This is the default.
Change the format of the small text showing current and maximum units of progress. The default is "%1d/%2d". Should not be called during the number is progressing.
format |
A string passed to
String.format()
;
use "%1d" for the current number and "%2d" for the maximum. If null,
nothing will be shown.
|
---|
Change the format of the small text showing the percentage of progress.
The default is
NumberFormat.getPercentageInstnace().
Should not be called during the number is progressing.
format |
An instance of a
NumberFormat
to generate the
percentage text. If null, nothing will be shown.
|
---|
Similar to
onCreate(Bundle)
, you should initialize your dialog
in this method, including calling
setContentView(View)
.
savedInstanceState |
If this dialog is being reinitalized after a
the hosting activity was previously shut down, holds the result from
the most recent call to
onSaveInstanceState()
, or null if this
is the first time.
|
---|