FakeMovableComponent


class FakeMovableComponent : FakeComponent


Test-only implementation of MovableComponent

Summary

Public constructors

Public functions

open Unit
addMoveEventListener(
    executor: Executor,
    moveEventListener: MoveEventListener
)

Adds the listener to the set of active listeners for the move events.

open Unit

Removes the listener from the set of active listeners for the move events.

Public properties

open Int

Sets the scale with distance mode.

open Dimensions

Sets the size of the interaction highlight extent.

Public constructors

FakeMovableComponent

Added in 1.0.0-alpha04
FakeMovableComponent()

Public functions

addMoveEventListener

Added in 1.0.0-alpha04
open fun addMoveEventListener(
    executor: Executor,
    moveEventListener: MoveEventListener
): Unit

Adds the listener to the set of active listeners for the move events.

The listener is invoked on the provided executor. If the app intends to modify the UI elements/views during the callback, the app should provide the thread executor that is appropriate for the UI operations. For example, if the app is using the main thread to render the UI, the app should provide the main thread (Looper.getMainLooper()) executor. If the app is using a separate thread to render the UI, the app should provide the executor for that thread.

Parameters
executor: Executor

The executor to run the listener on.

moveEventListener: MoveEventListener

The move event listener to set.

removeMoveEventListener

Added in 1.0.0-alpha04
open fun removeMoveEventListener(moveEventListener: MoveEventListener): Unit

Removes the listener from the set of active listeners for the move events.

Parameters
moveEventListener: MoveEventListener

the move event listener to remove

Public properties

scaleWithDistanceMode

Added in 1.0.0-alpha04
open var scaleWithDistanceModeInt

Sets the scale with distance mode.

The scale with distance mode to set

size

Added in 1.0.0-alpha04
open var sizeDimensions

Sets the size of the interaction highlight extent.