Developer
Documentation
Resources
Get Support
Sign in
Developer
Get Support
Sign in
DOCUMENTATION
Cloud
Data Center
Resources
Sign in
Developer
Sign in
DOCUMENTATION
Cloud
Data Center
Resources
Sign in
Last updated Oct 14, 2025

Dialog~DialogButton

Methods

enable()

Sets the button state to enabled

Example

1
2
AP.dialog.getButton('submit').enable();

disable()

Sets the button state to disabled. A disabled button cannot be clicked and emits no events.

Example

1
2
AP.dialog.getButton('submit').disable();

isEnabled (callback)

Query a button for its current state.

Parameters

NameTypeDescription
callback

function

function to receive the button state.

Example

1
2
AP.dialog.getButton('submit').isEnabled(function(enabled){
  if(enabled){
    //button is enabled
  }
});

toggle()

Toggle the button state between enabled and disabled.

Example

1
2
AP.dialog.getButton('submit').toggle();

trigger()

Trigger a callback bound to a button.

Example

1
2
AP.dialog.getButton('submit').bind(function(){
  alert('clicked!');
});
AP.dialog.getButton('submit').trigger();

isHidden (callback)

Query a button for its current hidden/visible state.

Parameters

NameTypeDescription
callback

function

function to receive the button state.

Example

1
2
AP.dialog.getButton('submit').isHidden(function(hidden){
  if(hidden){
    //button is hidden
  }
});

hide()

Sets the button state to hidden

Example

1
2
AP.dialog.getButton('submit').hide();

show()

Sets the button state to visible

Example

1
2
AP.dialog.getButton('submit').show();

Rate this page: