To link against this class, add the following line to your .pro file: LIBS += -lbbdevice
The Led class represents requests for flashing the LED present on the device.
This class requires that the application be granted the access_led_control capability.
Public Functions Index
If not 0, the supplied parent is responsible for deleting this instance.
This application must have the access_led_control permission to use this class.
Construct an Led instance with a custom color.
This will cancel any pending requests.
Retrieve the color of the Led instance.
If Led::active property is true, this represents the color that is flashing.
Returns the color of this instance.
Retrieve the number of flashes remaining for the Led instance.
If the Led::active property is false, 0 is returned. If the Led::active property is true, this represents the remaining number of times that the active color is flashed. If the Led instance is set to flash indefinitely, a value of -1 is returned.
Returns the number of flashes remaining for this Led instance.
Retrieve the state of the Led instance.
Represents the state of the requests initiated using this instance.
Returns true if a flash request is pending.
Set the color of the Led instance.
If the Led::active property is true and ledColor is not LedColor::None, then the last request will continue with the new color without resetting the Led::remainingFlashCount property. If ledColor is LedColor::None, then the request is canceled, emitting the activeChanged() signal instead of the colorChanged() signal.
The new color for this instance.
Reset the color of this instance.
The default value is bb::device::LedColor::Red.
Requests that the LED is flashed indefinitely with the color returned by color().
Requests that the LED is flashed the specified number of times with the color returned by color().
The Led::active property is set to true.
Emitted when the Led::color property changes.
The new value for the Led::color property.
Emitted when the Led::remainingFlashCount property changes.