Panda3D
 All Classes Functions Variables Enumerations
pgMouseWatcherParameter.h
1 // Filename: pgMouseWatcherParameter.h
2 // Created by: drose (05Jul01)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #ifndef PGMOUSEWATCHERPARAMETER_H
16 #define PGMOUSEWATCHERPARAMETER_H
17 
18 #include "pandabase.h"
19 
20 #include "mouseWatcherParameter.h"
21 #include "typedWritableReferenceCount.h"
22 
23 ////////////////////////////////////////////////////////////////////
24 // Class : PGMouseWatcherParameter
25 // Description : This specialization on MouseWatcherParameter allows
26 // us to tag on additional elements to events for the
27 // gui system, and also inherits from
28 // TypedWritableReferenceCount so we can attach this thing to an
29 // event.
30 ////////////////////////////////////////////////////////////////////
32  // For now, this must inherit from TypedWritableReferenceCount on
33  // the left, because MSVC++ wants to make that base class be the one
34  // at the front of the structure, not MouseWatcherParameter for some
35  // reason, and interrogate assumes that whichever base class is on
36  // the left will be at the front of the structure.
37 public:
38  INLINE PGMouseWatcherParameter();
39  INLINE PGMouseWatcherParameter(const MouseWatcherParameter &copy);
40  INLINE void operator = (const MouseWatcherParameter &copy);
41  virtual ~PGMouseWatcherParameter();
42 
43 PUBLISHED:
44  void output(ostream &out) const;
45 
46 public:
47  static TypeHandle get_class_type() {
48  return _type_handle;
49  }
50  static void init_type() {
51  TypedWritableReferenceCount::init_type();
52  register_type(_type_handle, "PGMouseWatcherParameter",
53  TypedWritableReferenceCount::get_class_type());
54  }
55  virtual TypeHandle get_type() const {
56  return get_class_type();
57  }
58  virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
59 
60 private:
61  static TypeHandle _type_handle;
62 };
63 
64 #include "pgMouseWatcherParameter.I"
65 
66 #endif
This specialization on MouseWatcherParameter allows us to tag on additional elements to events for th...
A base class for things which need to inherit from both TypedWritable and from ReferenceCount.
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85
This is sent along as a parameter to most events generated for a region to indicate the mouse and but...