Class: EventsHandler

new EventsHandler (psv)

Events handler

Name Type Description
psv PSV.Viewer



config PSV.Options readonly inherited overrides

Configuration holder

prop Object readonly inherited overrides

Properties holder

Reference to main controller

state Object protected

Internal properties

Name Type Description
moving boolean

is the user moving

zooming boolean

is the user zooming

startMouseX number

start x position of the click/touch

startMouseY number

start y position of the click/touch

mouseX number

current x position of the cursor

mouseY number

current y position of the cursor

mouseHistory Array.<Array.<number>>

list of latest positions of the cursor, [time, x, y]

pinchDist number

distance between fingers when zooming

dblclickData PSV.ClickData

temporary storage of click data between two clicks

dblclickTimeout number

timeout id for double click


__fullscreenToggled (force) package

Handles fullscreen events

Name Type Description
force boolean optional

force state

  • PSV.event:fullscreen-updated

destroy () inherited overrides

Destroys the service

disableKeyboard () protected

Disables the keyboard controls

enableKeyboard () protected

Enables the keyboard controls

init () protected

Initializes event handlers