Tools
addTool(tool)
Adds a tool to the player.
Kind: inner method of Tools
parameter | type |
---|---|
tool | string | Tool |
player.tools.addTool('orbit')
addTools(tools)
Adds an array of tools to the player.
Kind: inner method of Tools
parameter | type |
---|---|
tools | array | (string|Tool) |
player.tools.addTools(['pan', 'orbit', 'zoom'])
setTool(key, attrs)
Updates an existing tool.
Kind: inner method of Tools
parameter | type |
---|---|
key | string |
attrs | Tool |
player.tools.setTool('orbit', { enabled: false })
setTools(tools)
Updates existing tools.
Kind: inner method of Tools
parameter | type |
---|---|
tools | object l string, Tool |
player.tools.setTools({ 'orbit', { enabled: false }, 'pan': { enabled: true } })
removeTool(toolName)
Removes a tool from the player.
Kind: inner method of Tools
parameter | type |
---|---|
toolName | string |
player.tools.removeTool('orbit')
removeTools(toolNames)
Removes an array of tools from the player.
Kind: inner method of Tools
parameter | type |
---|---|
toolNames | Array | string |
player.tools.removeTools(['pan', 'orbit', 'zoom'])
setPrimary(toolName)
Sets a tool as Primary tool.
Kind: inner method of Tools
parameter | type |
---|---|
toolName | string |
player.tools.setPrimary('zoom')
getPrimaryTool()
Gets the current primary tool.
Kind: inner method of Tools
Returns: string -
player.tools.getPrimaryTool()