#include <CTrackerEventHandler.h>
Implementation of IEventHandler that forwards events to CTracker.
| CTrackerEventHandler::CTrackerEventHandler | ( | IPMUnknown * | boss | ) | |
Constructor.
- Parameters
| boss | object on which this interface is aggregated |
| virtual CTrackerEventHandler::~CTrackerEventHandler | ( | | ) | |
| virtual |
| virtual bool16 CTrackerEventHandler::Deactivate | ( | IEvent * | theEvent | ) | |
| virtual |
Calls AbortTracking if the application is deactivated
- Parameters
| theEvent | event of interest |
- Returns
- kFalse
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::KeyCmd | ( | IEvent * | e | ) | |
| virtual |
Disallow handling of keyboard shortcuts during tracking
- Parameters
- Returns
- kTrue, meaning that the event has been consumed
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::KeyDown | ( | IEvent * | e | ) | |
| virtual |
Disallow handling of keyboard shortcuts during tracking
- Parameters
- Returns
- kTrue, meaning that the event has been consumed
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::KeyUp | ( | IEvent * | e | ) | |
| virtual |
Disallow handling of keyboard shortcuts during tracking
- Parameters
- Returns
- kTrue, meaning that the event has been consumed
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::LButtonDn | ( | IEvent * | theEvent | ) | |
| virtual |
Begin tracking message will get sent out, if event in bounds.
- Parameters
| theEvent | event being handled |
- Returns
- kTrue if the event is within the bounds of the control-view of the tracker, kFalse otherwise
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::LButtonUp | ( | IEvent * | theEvent | ) | |
| virtual |
| virtual bool16 CTrackerEventHandler::MouseDrag | ( | IEvent * | e | ) | |
| virtual |
We still need to do this. It used to be that all mouse movement happened from a mouse tracker task. But that resulted in jerky tracking and fought with the drag event. Once solution would be to remove the mousedrag code and rely solely on the idle task but that results in an unwanted behaviour: For a quick drag (mouse down followed by mouse up) the idle task inserts a bogus mouse position into the tracker but before the tracker can handle the end tracking event. This gives a momentary flash of drawing the sprite where the mouse is and then redrawing the sprite to where the mouse button was let up. This effect will happen anytime the sequence of events is: GetNextEvent, mouse up inserted into event queue, run all tasks, GetNextEvent, mouse up handled.
Now the only thing the tracker thread is responsible for is generating mouse drag events when the mouse is outside the window and has not moved.
- Parameters
- Returns
- kTrue, meaning that the event has been consumed
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::MouseWheel | ( | IEvent * | e | ) | |
| virtual |
Swallows the event to suppress wheel activity while tracking
- Parameters
| theEvent | event of interest |
- Returns
- kTrue if tracking, kFalse otherwise
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::RButtonDn | ( | IEvent * | e | ) | |
| virtual |
Swallows the event to suppress right button activity while tracking
- Parameters
| theEvent | event of interest |
- Returns
- kTrue if tracking, kFalse otherwise
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::RButtonUp | ( | IEvent * | e | ) | |
| virtual |
Swallows the event to suppress right button activity while tracking
- Parameters
| theEvent | event of interest |
- Returns
- kTrue if tracking, kFalse otherwise
Reimplemented from CEventHandler.
| virtual bool16 CTrackerEventHandler::Suspend | ( | IEvent * | theEvent | ) | |
| virtual |
Calls AbortTracking if the application is suspended
- Parameters
| theEvent | event of interest |
- Returns
- kFalse
Reimplemented from CEventHandler.