Components Interactions Examples Tutorials API FAQ
Options
Menu

Hierarchy

Index

Constructors

constructor

  • new Mouse(svg: SVGElement): Mouse
  • This constructor not be invoked directly.

    constructor

    Parameters

    • svg: SVGElement

      The root to attach to.

    Returns Mouse

Properties

Protected _eventToProcessingFunction

_eventToProcessingFunction: object

Type declaration

  • [eventName: string]: function
      • (e: Event): any
      • Parameters

        • e: Event

        Returns any

Private _lastMousePosition

_lastMousePosition: any

Private _translator

_translator: any

Static Private _DBLCLICK_EVENT_NAME

_DBLCLICK_EVENT_NAME: any

Static Private _DISPATCHER_KEY

_DISPATCHER_KEY: any

Static Private _MOUSEDOWN_EVENT_NAME

_MOUSEDOWN_EVENT_NAME: any

Static Private _MOUSEMOVE_EVENT_NAME

_MOUSEMOVE_EVENT_NAME: any

Static Private _MOUSEOUT_EVENT_NAME

_MOUSEOUT_EVENT_NAME: any

Static Private _MOUSEOVER_EVENT_NAME

_MOUSEOVER_EVENT_NAME: any

Static Private _MOUSEUP_EVENT_NAME

_MOUSEUP_EVENT_NAME: any

Static Private _WHEEL_EVENT_NAME

_WHEEL_EVENT_NAME: any

Methods

Protected _addCallbackForEvent

  • _addCallbackForEvent(eventName: string, callback: Function): void

Protected _callCallbacksForEvent

  • _callCallbacksForEvent(eventName: string, ...args: any[]): void

Private _measureAndDispatch

  • _measureAndDispatch(event: any, eventName: any, scope?: any): any
  • Computes the mouse position from the given event, and if successful calls all the callbacks in the provided callbackSet.

    Parameters

    • event: any
    • eventName: any
    • Optional scope: any

    Returns any

Protected _removeCallbackForEvent

  • _removeCallbackForEvent(eventName: string, callback: Function): void

eventInsideSVG

  • eventInsideSVG(event: MouseEvent): boolean

lastMousePosition

  • lastMousePosition(): Point

offDblClick

offMouseDown

offMouseMove

offMouseUp

offWheel

onDblClick

onMouseDown

onMouseMove

onMouseUp

onWheel

Static getDispatcher

  • getDispatcher(elem: SVGElement): Mouse
  • Get a Mouse Dispatcher for the containing elem. If one already exists on that , it will be returned; otherwise, a new one will be created.

    Parameters

    • elem: SVGElement

    Returns Mouse

Generated using TypeDoc