Interface Node.OnTapListener

  • Enclosing class:
    Node

    public static interface Node.OnTapListener
    Interface definition for a callback to be invoked when a node is tapped.
    • Method Detail

      • onTap

        void onTap​(HitTestResult hitTestResult,
                   android.view.MotionEvent motionEvent)
        Handles when a node has been tapped.

        HitTestResult.getNode() will always be this node or one of its children.

        Parameters:
        hitTestResult - represents the node that was tapped and information about where it was touched
        motionEvent - the MotionEvent.ACTION_UP MotionEvent that caused the tap