Button trigger.
More...
#import <ABButtonTrigger.h>
Inherits ABTrigger.
Button trigger.
This class implements a kind of trigger that appears as a button.
Create a button trigger.
- Parameters
-
title | A user-readable title (used for accessibility) |
icon | A icon of maximum dimensions 80x80, to use to draw the trigger button. This icon will be used as a mask to render the inset button effect. Icon size should be divisible by 2. |
block | Block to be called when trigger is activated |
- (void) setTitle: |
|
(NSString *) |
title |
forState: |
|
(ABTriggerState) |
state |
|
|
| |
Set the title for a given state.
- Parameters
-
title | User-readable title (used for accessibility) |
state | State to apply title to |
Get title for the given state.
- Parameters
-
- Returns
- Title for state
Set the icon for a given state.
- Parameters
-
icon | A icon of maximum dimensions 80x80, to use to draw the trigger button. This icon will be used as a mask to render the inset button effect. Icon size should be divisible by 2. |
state | State to apply icon to |
Get icon for the given state.
- Parameters
-
- Returns
- Icon for state
Set the color for a given state.
By default, normal state icons are drawn in 50% grey, selected icons are drawn in 20% grey unless a custom selected state icon is provided, in which case it is also drawn in 50% grey. Alternate state icons are drawn in green. Triggers with system state ABTriggerTypeRecordToggle are drawn in red.
- Parameters
-
color | The color to use to render the icon for the given state |
state | State to apply color to |
Get color for the given state.
- Parameters
-
- Returns
- Color for state
Add a block to be called in response to events within Audiobus Remote.
This method allows your app to react to UIControlEventTouchDown, UIControlEventTouchUpInside UIControlEventTouchUpOutside, UIControlEventTouchCancel events originating from Audiobus Remote.
This method must only used with triggers that have been added using ABAudiobusController's addRemoteTrigger: and addRemoteTriggerMatrix:rows:cols: methods.
- Parameters
-
block | The block executed if control event occurs. |
controlEvents | The UIControlEvents for which the block shall be executed. |
The documentation for this class was generated from the following file: