InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
CIdleMouseWatcher.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Shawn Sheridan
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //========================================================================================
23 
24 #ifndef __CIdleMouseWatcher__
25 #define __CIdleMouseWatcher__
26 
27 //#include "IIdleTask.h"
28 #include "IEventWatcher.h"
29 #include "IPMUnknownData.h"
30 #include "HelperInterface.h"
31 #ifdef MACINTOSH
32 # include <CoreServices/CoreServices.h>
33 #endif
34 
35 class MouseWatcherIdleTask;
36 
73 {
74 public:
77 
79 
83  void StartWatching();
84 
88  void StopWatching();
89 
90  enum { kEndOfTime = ~(uint32)0};
91 
95  virtual uint32 MouseMoved(GSysPoint) = 0;
96 
100  virtual GSysPoint StartingMousePoint();
101 private:
102  friend class MouseWatcherIdleTask; //needs private access to fMouseMoving
103  IPMUnknownData* fAccomplice;
104  enum { kNoOneWatching, kIdleTaskWatching, kEventWatcherWatching} fWhoIsWatching; //an optimization so I don't have to ask the IdleTaskMgr or EventDispatcher which is active
105  void Farewell();
106  bool16 fbInWatchEvent, fStopWhileInMouseMoved;
107 
108 };
109 
110 
111 #endif // __CIdleMouseWatcher__