VISU - PHP Game Framework

MouseButtonSignal extends Signal
in package

Table of Contents

Properties

$action  : int
The action that was performed
$button  : int
The mouse button that was pressed or released
$mods  : int
Bit field describing which modifier keys were held down
$window  : Window
The window that received the event

Methods

__construct()  : mixed
Constructor
__debugInfo()  : array<string, mixed>
Omits the window property from the debug output
isLeft()  : bool
Returns boolean if the left mouse button was pressed or released
isLeftDown()  : bool
Returns boolean if the left mouse button was pressed down
isLeftUp()  : bool
Returns boolean if the left mouse button was released
isMiddle()  : bool
Returns boolean if the middle mouse button was pressed or released
isMiddleDown()  : bool
Returns boolean if the middle mouse button was pressed down
isMiddleUp()  : bool
Returns boolean if the middle mouse button was released
isPropagationStopped()  : bool
Has the propagation been stopped?
isRight()  : bool
Returns boolean if the right mouse button was pressed or released
isRightDown()  : bool
Returns boolean if the right mouse button was pressed down
isRightUp()  : bool
Returns boolean if the right mouse button was released
stopPropagation()  : void
Stop the propagation of the signal

Properties

$button read-only

The mouse button that was pressed or released

public int $button

$mods read-only

Bit field describing which modifier keys were held down

public int $mods

Methods

__construct()

Constructor

public __construct(Window $window, int $button, int $action, int $mods) : mixed
Parameters
$window : Window

The window that received the event

$button : int

The mouse button that was pressed or released

$action : int

The action that was performed

$mods : int

Bit field describing which modifier keys were held down

__debugInfo()

Omits the window property from the debug output

public __debugInfo() : array<string, mixed>
Return values
array<string, mixed>

isLeft()

Returns boolean if the left mouse button was pressed or released

public isLeft() : bool
Return values
bool

isLeftDown()

Returns boolean if the left mouse button was pressed down

public isLeftDown() : bool
Return values
bool

isLeftUp()

Returns boolean if the left mouse button was released

public isLeftUp() : bool
Return values
bool

isMiddle()

Returns boolean if the middle mouse button was pressed or released

public isMiddle() : bool
Return values
bool

isMiddleDown()

Returns boolean if the middle mouse button was pressed down

public isMiddleDown() : bool
Return values
bool

isMiddleUp()

Returns boolean if the middle mouse button was released

public isMiddleUp() : bool
Return values
bool

isPropagationStopped()

Has the propagation been stopped?

public isPropagationStopped() : bool
Return values
bool

isRight()

Returns boolean if the right mouse button was pressed or released

public isRight() : bool
Return values
bool

isRightDown()

Returns boolean if the right mouse button was pressed down

public isRightDown() : bool
Return values
bool

isRightUp()

Returns boolean if the right mouse button was released

public isRightUp() : bool
Return values
bool

stopPropagation()

Stop the propagation of the signal

public stopPropagation() : void

        
On this page

Search results