Skip to main content

Class: Mouse

Constructors​

constructor​

• new Mouse(screen)

Parameters​

NameType
screenScreen

Defined in​

src/Mouse.ts:24

Properties​

working​

• Private working: boolean = false

Defined in​

src/Mouse.ts:20


events​

• Private events: IEvent[] = []

Defined in​

src/Mouse.ts:21


eventElements​

• Private eventElements: Element[] = []

Defined in​

src/Mouse.ts:22


screen​

• Private Readonly screen: Screen

Defined in​

src/Mouse.ts:25

Methods​

isWorking​

â–¸ isWorking(): boolean

Returns​

boolean

Defined in​

src/Mouse.ts:31


start​

â–¸ start(): void

Returns​

void

Defined in​

src/Mouse.ts:35


stop​

â–¸ stop(): void

Returns​

void

Defined in​

src/Mouse.ts:52


hasEvents​

â–¸ hasEvents(): boolean

Returns​

boolean

Defined in​

src/Mouse.ts:64


runEvents​

â–¸ runEvents(): void

Returns​

void

Defined in​

src/Mouse.ts:68


checkPath​

â–¸ checkPath(element, ctx): void

Parameters​

NameType
elementElement
ctxRenderingContext2D

Returns​

void

Defined in​

src/Mouse.ts:100


checkBoundingBox​

â–¸ checkBoundingBox(element, boundingBox): void

Parameters​

NameType
elementElement
boundingBoxBoundingBox

Returns​

void

Defined in​

src/Mouse.ts:118


mapXY​

â–¸ Private mapXY(x, y): Point

Parameters​

NameType
xnumber
ynumber

Returns​

Point

Defined in​

src/Mouse.ts:135


onClick​

â–¸ Private onClick(event): void

Parameters​

NameType
eventMouseEvent

Returns​

void

Defined in​

src/Mouse.ts:160


onMouseMove​

â–¸ Private onMouseMove(event): void

Parameters​

NameType
eventMouseEvent

Returns​

void

Defined in​

src/Mouse.ts:181