Sets the button state to enabled
1
AP.dialog.getButton('submit').enable();
Sets the button state to disabled. A disabled button cannot be clicked and emits no events.
1
AP.dialog.getButton('submit').disable();
Query a button for its current state.
Name | Type | Description |
---|---|---|
callback | function | function to receive the button state. |
1 2 3 4 5
AP.dialog.getButton('submit').isEnabled(function(enabled){
if(enabled){
//button is enabled
}
});
Toggle the button state between enabled and disabled.
1
AP.dialog.getButton('submit').toggle();
Trigger a callback bound to a button.
1 2 3 4
AP.dialog.getButton('submit').bind(function(){
alert('clicked!');
});
AP.dialog.getButton('submit').trigger();
Query a button for its current hidden/visible state.
Name | Type | Description |
---|---|---|
callback | function | function to receive the button state. |
1 2 3 4 5
AP.dialog.getButton('submit').isHidden(function(hidden){
if(hidden){
//button is hidden
}
});
Sets the button state to hidden
1
AP.dialog.getButton('submit').hide();
Sets the button state to visible
1
AP.dialog.getButton('submit').show();
Rate this page: