Expand all

ve.ui.HistoryCommand

Extends

Constructor

new ve.ui.HistoryCommand(name, [method]) #

UserInterface history command.

Parameters:

Name Type Attributes Description
name string
method string optional
Source:
UserInterface history command.

Methods

execute(surface, [args], [source]) → {boolean} #

Execute command on a surface.

Parameters:

Name Type Attributes Description
surface ve.ui.Surface

Surface to execute command on

args Array optional

Custom arguments to override defaults

source string optional

Label for the source of the command. One of 'trigger', 'sequence', 'tool', or 'context'

Inherited from:
Source:

Returns:

Command was executed

Type
boolean
Execute command on a surface.

getAction() → {string} #

Get command action.

Inherited from:
Source:

Returns:

action Action to execute when command is triggered

Type
string
Get command action.

getArgs() → {Array} #

Get command arguments.

Inherited from:
Source:

Returns:

args Additional arguments to pass to the action when executing

Type
Array
Get command arguments.

getMethod() → {string} #

Get command method.

Inherited from:
Source:

Returns:

method Method to call on action when executing

Type
string
Get command method.

getName() → {string} #

Get command name.

Inherited from:
Source:

Returns:

name The symbolic name of the command.

Type
string
Get command name.

isExecutable(fragment) → {boolean} #

Check if this command is executable on a given surface fragment

Parameters:

Name Type Description
fragment ve.dm.SurfaceFragment

Surface fragment

Overrides:
Source:

Returns:

The command can execute on this fragment

Type
boolean
Check if this command is executable on a given surface fragment