Table of Contents
ProgressDialog
This object represents a window showing a progress bar.
Functions
ProgressDialog
Constructor function.
Syntax
var myObject = new ProgressDialog();
var myObject = new ProgressDialog(parameters);
Arguments
- parameters - (object) window parameters
- title - (string) the window's title
- position - (Point) the window's position
- opacity - (float) the window's opacity
- enabled - (boolean) the window's enabled status
- visible - (boolean) the window's visible status
- value - (integer) the value
- labelText - (string) the label text
- minimum - (integer) the minimum value
- maximum - (integer) the maximum value
- range - (object) the range
- minimum - (integer) the minimum value
- maximum - (integer) the maximum value
- onCanceled - (OnCanceled) event called when the window is canceled
Exceptions
- (ParameterTypeError) incorrect parameter type
- (ParameterCountError) incorrect parameter count
Example
var myObject = new ProgressDialog();
var myObject = new ProgressDialog({ title: "Please wait", value: 50 });
Methods
setTitle
Sets the window's title.
Syntax
myObject.setTitle(title);
Arguments
- title - (string) the window's title
Returns
- (ProgressDialog) this ProgressDialog
setPosition
Sets the window's position.
Syntax
myObject.setPosition(point);
Arguments
- point - (Point) the window's position
Returns
- (ProgressDialog) this ProgressDialog
setOpacity
Sets the window's opacity.
Syntax
myObject.setOpacity(opacity);
Arguments
- opacity - (float) the window's opacity
Returns
- (ProgressDialog) this ProgressDialog
setEnabled
Sets the window's enabled status.
Syntax
myObject.setEnabled(enabled);
Arguments
- enabled - (boolean) the window's enabled status
Returns
- (ProgressDialog) this ProgressDialog
setVisible
Sets the window's visible status.
Syntax
myObject.setVisible(visible);
Arguments
- visible - (boolean) the window's visible status
Returns
- (ProgressDialog) this ProgressDialog
close
Closes the window.
Syntax
myObject.close();
Returns
- (ProgressDialog) this ProgressDialog
title
Returns the window's title.
Syntax
myObject.title();
Returns
- (string) the window's title
position
Returns the window's position.
Syntax
myObject.position();
Returns
- (Point) the window's position
opacity
Returns the window's opacity.
Syntax
myObject.opacity();
Returns
- (float) the window's opacity
enabled
Returns the window's enabled status.
Syntax
myObject.enabled();
Returns
- (boolean) the window's enabled status
visible
Returns the window's visible status.
Syntax
myObject.visible();
Returns
- (boolean) the window's visible status
setValue
Sets the progress value.
Syntax
myObject.setValue(value);
Arguments
- value - (integer) the progress value
Returns
- (ProgressDialog) this ProgressDialog
setLabelText
Sets the label text.
Syntax
myObject.setLabelText(labelText);
Arguments
- labelText - (string) the label text
Returns
- (ProgressDialog) this ProgressDialog
setMinimum
Sets the minimum value.
Syntax
myObject.setMinimum(minimum);
Arguments
- minimum - (integer) the minimum value
Returns
- (ProgressDialog) this ProgressDialog
setMaximum
Sets the maximum value.
Syntax
myObject.setMaximum(maximum);
Arguments
- maximum - (integer) the maximum value
Returns
- (ProgressDialog) this ProgressDialog
setRange
Sets the minimum and maximum value.
Syntax
myObject.setRange(minimum, maximum);
Arguments
- minimum - (integer) the minimum value
- maximum - (integer) the maximum value
Returns
- (ProgressDialog) this ProgressDialog
show
Show the window. (non-blocking) Use the OnCanceled event to know when the window has been closed.
Syntax
myObject.show();
Returns
- (ProgressDialog) this ProgressDialog
showModal
Show the window. (blocking)
Syntax
myObject.showModal();
Returns
- (integer) the window result (0 means that it has been canceled)
Events
onCanceled
Called when the window is canceled.
Syntax
myObject.onCanceled = function() {};
Example
myObject.onCanceled = function() { //Event action };
Attributes
title
The window's title. (string)
position
The window's position. (Point)
opacity
The window's opacity. (float)
enabled
The window's enabled status. (boolean)
value
The progress bar's value. (integer)