PinchInput
class PinchInput
A module that passes the amount of change to eg.Axes when two pointers are moving toward (zoom-in) or away from each other (zoom-out). use one axis.
constructor
new PinchInput(element, options)
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
element | HTMLElement | String | jQuery | An element to use the eg.Axes.PinchInput module | ||
options | PinchInputOption | ✔️ | The option object of the eg.Axes.PinchInput module |
const pinch = new eg.Axes.PinchInput("#area", {
scale: 1
});
// Connect 'something' axis when two pointers are moving toward (zoom-in) or away from each other (zoom-out).
axes.connect("something", pinch);
Methods
destroy
Destroys elements, properties, and events used in a module.
enable
Enables input devices
Returns: PinchInput
- An instance of a module itself
disable
Disables input devices
Returns: PinchInput
- An instance of a module itself
isEnabled
Returns whether to use an input device
Returns: Boolean
- Whether to use an input device