Important: The information in this document is obsolete and should not be used for new development.
SystemClick
After receiving a mouse-down event, your application should call the Window
Manager functionFindWindow
to determine where the cursor was when the mouse button was pressed. IfFindWindow
returns theinSysWindow
constant, call theSystemClick
procedure to handle the event.
PROCEDURE SystemClick (theEvent: EventRecord; theWindow: WindowPtr);
theEvent
- The event record for the event.
theWindow
- The window in which the mouse-down event occurred. Pass the window pointer returned by
FindWindow
in this parameter.DESCRIPTION
If a mouse-down event occurred in a desk accessory's window, theSystemClick
procedure determines which part of the desk accessory's window the cursor was in when the mouse button was pressed and routes the event to the appropriate desk accessory as necessary.If the mouse button was pressed while the cursor was in the content region of the desk accessory's window and the window is active,
SystemClick
sends the mouse-down event to the desk accessory to process. If the mouse-down event occurred in the content region of the window and the window is inactive,SystemClick
makes it the active window. It does this by sending your application an activate event to deactivate its
front window and directing an event to the desk accessory to activate its window.If the mouse button was pressed while the cursor was in the drag region or go-away region,
SystemClick
calls the Window Manager routineDragWindow
orTrackGoAway
, as appropriate. IfTrackGoAway
reports that the user closed the desk accessory,SystemClick
sends a close message to the desk accessory.SEE ALSO
See "The Event Record," beginning on page 2-79, for a description of the fields in the event record.