Gesturedeck

constructor(context: Context = GlobalApplication.context, tapAction: () -> Unit? = { Log.d(TAG, "2 finger tap") }, swipeLeftAction: () -> Unit? = { Log.d(TAG, "2 finger swipe left") }, swipeRightAction: () -> Unit? = { Log.d(TAG, "2 finger swipe right") }, panAction: (event: MotionEvent, swipeDirection: SwipeDirection, state: GestureState) -> Unit? = { _, _, _ -> Log.d(TAG, "2 finger pan") }, panSensitivity: PanSensitivity? = null, longPressAction: (state: GestureState) -> Unit? = { Log.d(TAG, "2 finger long press") }, autoStart: Boolean = true, observingRootView: Boolean = true, activationKey: String? = null)

Parameters

context

Context of the current activity.

tapAction

The action to perform when tapping with two fingers.

swipeLeftAction

The action to perform when swipping left with two fingers.

swipeRightAction

The action to perform when swipping right with two fingers.

panAction

The action to perform when panning vertically with two fingers or double tapping and sliding with a single finger.

panSensitivity

The sensitivity of Gesturedeck when panning.

longPressAction

The action to perform when long pressing with two fingers.

autoStart

Start gesturedeck automatically.

observingRootView

Set the touch listener on the root view of the activity, set to false if you want to set the touch listener on a specific view or activity and call onTouchEvent manually.

activationKey

An optional activation key to remove watermarks. If not provided, Gesturedeck will present a watermark.