Starshatter_Open
Open source Starshatter engine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
EventDispatch.h
Go to the documentation of this file.
1 /* Project nGenEx
2  Destroyer Studios LLC
3  Copyright © 1997-2004. All Rights Reserved.
4 
5  SUBSYSTEM: nGenEx.lib
6  FILE: EventDispatch.h
7  AUTHOR: John DiCamillo
8 
9 
10  OVERVIEW
11  ========
12  Event Dispatch class
13 */
14 
15 #ifndef EventDispatch_h
16 #define EventDispatch_h
17 
18 #include "Types.h"
19 #include "EventTarget.h"
20 #include "List.h"
21 
22 // +--------------------------------------------------------------------+
23 
25 {
26 public:
27  static const char* TYPENAME() { return "EventDispatch"; }
28 
29  EventDispatch();
30  virtual ~EventDispatch();
31 
32  static void Create();
33  static void Close();
34  static EventDispatch* GetInstance() { return dispatcher; }
35 
36  virtual void Dispatch();
37  virtual void Register(EventTarget* tgt);
38  virtual void Unregister(EventTarget* tgt);
39 
40  virtual EventTarget* GetCapture();
41  virtual int CaptureMouse(EventTarget* tgt);
42  virtual int ReleaseMouse(EventTarget* tgt);
43 
44  virtual EventTarget* GetFocus();
45  virtual void SetFocus(EventTarget* tgt);
46  virtual void KillFocus(EventTarget* tgt);
47 
48  virtual void MouseEnter(EventTarget* tgt);
49 
50 protected:
57 
59 };
60 
61 #endif EventDispatch_h
62