#import <CPEvent.h>
Inheritance diagram for CPEvent:CPEvent encapsulates the details of a Cappuccino keyboard or mouse event.
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
Creates a new mouse tracking event.
| anEventType | the event type |
| aPoint | the location of the cursor in the window specified by aWindowNumber |
| modifierFlags | a bitwise combination of the modifiers specified in the CPEvent globals |
| aTimestamp | the time the event occurred |
| aWindowNumber | the number of the CPWindow where the event occurred |
| aGraphicsContext | the graphics context where the event occurred |
| anEventNumber | a number for this event |
| aTrackingArea | the tracking area that triggered the event |
| CPInternalInconsistencyException | if an invalid event type is provided |
|
implementation |
|
implementation |
|
implementation |
Creates a new keyboard event.
| anEventType | the event type. Must be one of CPKeyDown, CPKeyUp or CPFlagsChanged |
| aPoint | the location of the cursor in the window specified by aWindowNumber |
| modifierFlags | a bitwise combination of the modifiers specified in the CPEvent globals |
| aTimestamp | the time the event occurred |
| aWindowNumber | the number of the CPWindow where the event occurred |
| aGraphicsContext | the graphics context where the event occurred |
| characters | the characters associated with the event |
| unmodCharacters | the string of keys pressed without the presence of any modifiers other than Shift |
| repeatKey | YES if this is caused by the system repeat as opposed to the user pressing the key again |
| code | a number associated with the keyboard key of this event |
| CPInternalInconsistencyException | if anEventType is not a CPKeyDown, CPKeyUp or CPFlagsChanged |
|
implementation |
Returns the location of the mouse (for mouse events). If the receiver is not a mouse event, it returns nil. If window returns nil, then the mouse coordinates will be based on the screen coordinates. Otherwise, the coordinates are relative to the window's coordinates.
nil for non-mouse events.
|
implementation |
Returns event information as a bit mask.
Provided by category CPEvent(CPApplicationModifierFlags).
|
implementation |
Creates a new mouse event.
| anEventType | the event type |
| aPoint | the location of the cursor in the window specified by aWindowNumber |
| modifierFlags | a bitwise combination of the modifiers specified in the CPEvent globals |
| aTimestamp | the time the event occurred |
| aWindowNumber | the number of the CPWindow where the event occurred |
| aGraphicsContext | the graphics context where the event occurred |
| anEventNumber | a number for this event |
| aClickCount | the number of clicks that caused this event |
| aPressure | the amount of pressure applied to the input device (ranges from 0.0 to 1.0) |
| CPInternalInconsistencyException | if an invalid event type is provided |
|
implementation |
Creates a new custom event.
| anEventType | the event type. Must be one of CPAppKitDefined, CPSystemDefined, CPApplicationDefined or CPPeriodic |
| aLocation | the location of the cursor in the window specified by aWindowNumber |
| modifierFlags | a bitwise combination of the modifiers specified in the CPEvent globals |
| aTimestamp | the time the event occurred |
| aWindowNumber | the number of the CPWindow where the event occurred |
| aGraphicsContext | the graphics context where the event occurred |
| aSubtype | a numeric identifier to differentiate this event from other custom events |
| aData1 | more data that describes the event |
| aData2 | even more data that describes the event |
| CPInternalInconsistencyException | if an invalid event type is provided |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |
|
implementation |