dialog_add_button()

Add a button to a dialog.

Synopsis:

#include <bps/dialog.h>
 
BPS_API int dialog_add_button(dialog_instance_t dialog, const char *label, bool enabled, const char *button_context, bool visible)

Since:

BlackBerry 10.0.0

Arguments:

dialog

The dialog to add a button to.

label

The button label.

enabled

If true, the button is enabled when the dialog is displayed; if false, the button is disabled when the dialog is displayed.

button_context

The button context. This can be any data the application wants to associate with a button. If button_context is set and the button is pressed, the button_context is returned in the DIALOG_RESPONSE event.

visible

If true, the button is visible when the dialog is displayed; if false, the button is not visible when the dialog is displayed.

Library:

libbps (For the qcc command, use the -l bps option to link against this library)

Description:

The dialog_add_button() function adds a button to the specified dialog.

Returns:

BPS_SUCCESS upon success, BPS_FAILURE with errno set otherwise.

Last modified: 2014-05-14



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus