Name: mouseDown

Type: message

Syntax: mouseDown <mouseButtonNumber> 

Summary: Sent when the user presses the <mouse button>.

Introduced: 1.0

OS: mac,windows,linux,ios,android

Platforms: desktop,server,web,mobile

Example:
on mouseDown theButton -- show popup menu on Control/Right-click
  if theButton is 3 then popup button "Configure"
  else pass mouseDown
end mouseDow

Parameters:
mouseButtonNumber (enum): The mouseButtonNumber specifies which mouse button was pressed:
-  1 is the mouse button on Mac OS systems and the left button on Windows and Unix systems.
-  2 is the middle button on Unix systems.
-  3 is the right button on Windows and Unix systems and Control-click on Mac OS systems.

Description:
Handle the <mouseDown> <message> to perform an action when the user presses the <mouse button>, before the <mouse button> is released.

The <mouseDown> <message> is sent to the <control> that was clicked, or to the <card> if no <control> was under the <mouse pointer>.

If the Browse tool is being used, and you click an unlocked field with mouse button 1 or 2, no <mouseDown> <message> is sent. If you click with button 3, the <mouseDown> <message> is sent even though the <field> is not <lock|locked>.

>*Important:*  If the user clicks a transparent <pixel> in an <image>, the <mouseDown> <message> is sent to the <object> behind the <image>, not to the <image>.

References: repeatDelay (property), scrollbarBeginning (message), scrollbarLineInc (message), mouseDown (message), mouseStillDown (message), control (keyword), field (glossary), pixel (glossary), mouse button (glossary), lock (glossary), message (glossary), card (glossary), mouse pointer (glossary), image (glossary), mouseClick (function), grab (command), object (object)

Tags: ui
