SystemUiButton

Since: BlackBerry 10.0.0

#include <bb/system/SystemUiButton>

To link against this class, add the following line to your .pro file: LIBS += -lbbsystem

The invokable buttons that are available for dialogs and toasts.

The presentation of the button is dependent on the class using it. For instance, some classes may choose to always show the button as enabled, or to not show buttons with null or empty labels.


Overview

Properties Index

Public Functions Index

SystemUiButton (QObject *parent=0)
SystemUiButton (const QString &label, QObject *parent=0)
virtual ~SystemUiButton ()
boolenabled () const
QStringlabel () const
Q_INVOKABLE voidresetEnabled ()
Q_INVOKABLE voidresetLabel ()
voidsetEnabled (bool value)
voidsetLabel (const QString &text)

Signals Index

voidenabledChanged (bool value)
voidlabelChanged (const QString &value)

Properties

bool enabled

Indicates whether the button is enabled and can be clicked.

Since:

BlackBerry 10.0.0

QString label

Represents the text of the button.

Since:

BlackBerry 10.0.0

Public Functions

SystemUiButton (

Constructs an instance of a button.

The enabled property will be set to true and the label property will be set to QString::null.
Parameters
parent

If not 0, the supplied parent will be responsible for deleting this instance.

Since:

BlackBerry 10.0.0

SystemUiButton (

Constructs an instance of a button with the label provided.

The enabled property will be set to true.
Parameters
label

The label for the button.

parent

If not 0, the supplied parent will be responsible for deleting this instance.

Since:

BlackBerry 10.0.0

virtual~SystemUiButton ()

Destructor.

Since:

BlackBerry 10.0.0

bool enabled ()

Retrieves the enabled state of the button.

Return:

Returns whether the button should be enabled.

Since:

BlackBerry 10.0.0

QString label ()

Retrieves the label description that is associated with the button.

Return:

Returns the label of the button.

Since:

BlackBerry 10.0.0

Q_INVOKABLE void resetEnabled ()

Resets the SystemUiButton::enabled property to true.

Since:

BlackBerry 10.0.0

Q_INVOKABLE void resetLabel ()

Resets the label description to QString::null.

Since:

BlackBerry 10.0.0

void setEnabled (
  • boolvalue)

Enables or disables the button.

Parameters
value

The new enabled state of the button.

Since:

BlackBerry 10.0.0

void setLabel (

Sets the label description to associate with the button.

Empty or NULL labels may not be shown.
Parameters
text

The new label text.

Since:

BlackBerry 10.0.0

Signals

void enabledChanged (
  • boolvalue)

Emitted when the enabled property is changed programmatically.

Parameters
value

The new value of the enabled property.

Since:

BlackBerry 10.0.0

void labelChanged (

Emitted when the label property is changed programmatically.

Parameters
value

The new value of the label property.

Since:

BlackBerry 10.0.0

Last modified: 2014-06-24



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

comments powered by Disqus