public abstract class DimplePluginBroadcastReceiver
extends BroadcastReceiver
<receiver android:name="ReceiverName">
<intent-filter>
<action android:name="io.dimple.action.PLUGIN_LONGPRESS"/>
</intent-filter>
</receiver>
to AndroidManifest.xml to receive Dimple long-press events (replacing ReceiverName with your receiver).| Constructor and Description |
|---|
DimplePluginBroadcastReceiver() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
onDimpleDown(Context context,
byte[] data)
Called when Dimple is pressed down.
|
abstract void |
onDimpleHold(Context context,
long holdLength,
byte[] data,
long timeSinceLastHoldEvent)
Called regularly while Dimple is pressed down.
|
abstract void |
onDimpleUp(Context context,
long holdLength,
byte[] data)
Called when Dimple is released.
|
void |
onReceive(Context context,
Intent intent) |
public void onReceive(Context context,
Intent intent)
public abstract void onDimpleDown(Context context,
byte[] data)
context - Context from Broadcast Receiverdata - Data sent to Dimple when plugin was createdpublic abstract void onDimpleHold(Context context,
long holdLength,
byte[] data,
long timeSinceLastHoldEvent)
context - Context from Broadcast ReceiverholdLength - Milliseconds from Dimple down press.data - Data sent to Dimple when plugin was createdtimeSinceLastHoldEvent - Time between this and last hold event (or down event if this is first).public abstract void onDimpleUp(Context context,
long holdLength,
byte[] data)
context - Context from Broadcast ReceiverholdLength - Milliseconds from Dimple down press (full press length)data - Data sent to Dimple when plugin was created