Nativescript plugin for Charts
    Preparing search index...

    TouchListener for Pie- and RadarChart with handles all touch interaction.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    the chart the listener represents

    lastHighlighted: Highlight

    the last highlighted object (via touch)

    mLastGesture: ChartGesture

    the last touch gesture that has been performed

    mTouchMode: number

    integer field that holds the current touch-state

    ROTATION_HANDLER_TAG: any
    rotationGestureHandler: RotationGestureHandler
    TAP_HANDLER_TAG: any

    Constructor with initialization parameters.

    instance of the chart

    tapGestureHandler: TapGestureHandler
    DRAG: number
    NONE: number
    PINCH_ZOOM: number

    Protected StaticPOST_ZOOM

    POST_ZOOM: number
    ROTATE: number
    X_ZOOM: number
    Y_ZOOM: number

    Accessors

    • get lastGesture(): ChartGesture

      Returns the last gesture that has been performed on the chart.

      Returns ChartGesture

    • get touchMode(): number

      returns the touch mode the listener is currently in

      Returns number

    Methods

    • Returns void

    • Returns void

    • Returns RotationGestureHandler

    • Returns TapGestureHandler

    • Returns {
          enabled?: boolean;
          gestureTag: any;
          nativeGetterKey?: string;
          shouldCancelWhenOutside?: boolean;
          simultaneousHandlers?: number[];
          waitFor?: number[];
      }

    • Returns {
          enabled?: boolean;
          gestureTag: any;
          maxDelayMs?: number;
          maxDeltaX?: number;
          maxDeltaY?: number;
          maxDist?: number;
          maxDurationMs?: number;
          minPointers?: number;
          nativeGetterKey?: string;
          numberOfTaps?: number;
          shouldCancelWhenOutside?: boolean;
          simultaneousHandlers?: number[];
          waitFor?: number[];
      }

    • Returns the correct translation depending on the provided x and y touch points

      Parameters

      • x: any
      • y: any

      Returns { x: number; y: number }

    • Returns void

    • GESTURE RECOGNITION BELOW

      Parameters

      • event: GestureStateEventData

      Returns void

    • Parameters

      • event: GestureTouchEventData

      Returns void

    • Parameters

      • event: GestureStateEventData

      Returns void

    • sets the starting angle of the rotation, this is only used by the touch listener, x and y is the touch position

      Parameters

      • x: any
      • y: any

      Returns void

    • Parameters

      • enabled: boolean

      Returns void

    • Parameters

      • enabled: boolean

      Returns void

    • Sets the deceleration-angular-velocity to 0f

      Returns void

    • updates the view rotation depending on the given touch position, also takes the starting angle into consideration

      Parameters

      • x: any
      • y: any

      Returns void

    • returns the distance between two points

      Parameters

      • eventX: any
      • startX: any
      • eventY: any
      • startY: any

      Returns number