onEnterEvent

inline fun <T : Actor> T.onEnterEvent(crossinline listener: T.(event: InputEvent, x: Float, y: Float) -> Unit): ClickListener

Attaches a ClickListener to this actor.

Return

ClickListener instance.

Parameters

listener

invoked each time the mouse cursor or finger touch enters the actor. Consumes the triggered InputEvent and the Actor that the listener was originally attached to as this. The received floats are local X and Y coordinates of the actor.

See also