class method Event.isLeftClick

View source on GitHub →

Event.isLeftClick(event) → Boolean
  • event (Event) – An Event object

Determines whether a button-related mouse event involved the left mouse button.

Keep in mind that the "left" mouse button is actually the "primary" mouse button. When a mouse is in left-handed mode, the browser will report clicks of the right button as "left-clicks."

This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.