Kodi's progress dialog class (Duh!)
More...
Kodi's progress dialog class (Duh!)
◆ close()
void XBMCAddon::xbmcgui::DialogProgress::close |
( |
|
... | ) |
|
\htmlonly <h4><code><span style="font-style: italic;">Function: </span><span style="font-style: bold;"><font color=31363b><big> xbmcgui.DialogProgress().close() </big></font></span></code></h4> \endhtmlonly
Close the progress dialog.
Example:
◆ create()
void XBMCAddon::xbmcgui::DialogProgress::create |
( |
|
... | ) |
|
\htmlonly <h4><code><span style="font-style: italic;">Function: </span><span style="font-style: bold;"><font color=31363b><big> xbmcgui.DialogProgress().create(heading[, line1, line2, line3]) </big></font></span></code></h4> \endhtmlonly
Create and show a progress dialog.
- Parameters
-
heading | string or unicode - dialog heading. |
line1 | [opt] string or unicode - line #1 multi-line text. |
line2 | [opt] string or unicode - line #2 text. |
line3 | [opt] string or unicode - line #3 text. |
- Note
- It is preferred to only use line1 as it is actually a multi-line text. In this case line2 and line3 must be omitted.
-
Use update() to update lines and progressbar.
Example:
..
pDialog = xbmcgui.DialogProgress()
pDialog.create('Kodi', 'Initializing script...')
..
◆ iscanceled()
bool XBMCAddon::xbmcgui::DialogProgress::iscanceled |
( |
|
... | ) |
|
\htmlonly <h4><code><span style="font-style: italic;">Function: </span><span style="font-style: bold;"><font color=31363b><big> xbmcgui.DialogProgress().iscanceled() </big></font></span></code></h4> \endhtmlonly
Checks progress is canceled.
- Returns
- True if the user pressed cancel.
Example:
..
if (pDialog.iscanceled()): return
..
◆ update()
void XBMCAddon::xbmcgui::DialogProgress::update |
( |
|
... | ) |
|
\htmlonly <h4><code><span style="font-style: italic;">Function: </span><span style="font-style: bold;"><font color=31363b><big> xbmcgui.DialogProgress().update(percent[, line1, line2, line3]) </big></font></span></code></h4> \endhtmlonly
Updates the progress dialog.
- Parameters
-
percent | integer - percent complete. (0:100) |
line1 | [opt] string or unicode - line #1 multi-line text. |
line2 | [opt] string or unicode - line #2 text. |
line3 | [opt] string or unicode - line #3 text. |
- Note
- It is preferred to only use line1 as it is actually a multi-line text. In this case line2 and line3 must be omitted.
Example:
..
pDialog.update(25, 'Importing modules...')
..