Panda3D
|
00001 // Filename: pgMouseWatcherParameter.h 00002 // Created by: drose (05Jul01) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) Carnegie Mellon University. All rights reserved. 00008 // 00009 // All use of this software is subject to the terms of the revised BSD 00010 // license. You should have received a copy of this license along 00011 // with this source code in a file named "LICENSE." 00012 // 00013 //////////////////////////////////////////////////////////////////// 00014 00015 #ifndef PGMOUSEWATCHERPARAMETER_H 00016 #define PGMOUSEWATCHERPARAMETER_H 00017 00018 #include "pandabase.h" 00019 00020 #include "mouseWatcherParameter.h" 00021 #include "typedWritableReferenceCount.h" 00022 00023 //////////////////////////////////////////////////////////////////// 00024 // Class : PGMouseWatcherParameter 00025 // Description : This specialization on MouseWatcherParameter allows 00026 // us to tag on additional elements to events for the 00027 // gui system, and also inherits from 00028 // TypedWritableReferenceCount so we can attach this thing to an 00029 // event. 00030 //////////////////////////////////////////////////////////////////// 00031 class EXPCL_PANDA_PGUI PGMouseWatcherParameter : public TypedWritableReferenceCount, public MouseWatcherParameter { 00032 // For now, this must inherit from TypedWritableReferenceCount on 00033 // the left, because MSVC++ wants to make that base class be the one 00034 // at the front of the structure, not MouseWatcherParameter for some 00035 // reason, and interrogate assumes that whichever base class is on 00036 // the left will be at the front of the structure. 00037 public: 00038 INLINE PGMouseWatcherParameter(); 00039 INLINE PGMouseWatcherParameter(const MouseWatcherParameter ©); 00040 INLINE void operator = (const MouseWatcherParameter ©); 00041 virtual ~PGMouseWatcherParameter(); 00042 00043 PUBLISHED: 00044 void output(ostream &out) const; 00045 00046 public: 00047 static TypeHandle get_class_type() { 00048 return _type_handle; 00049 } 00050 static void init_type() { 00051 TypedWritableReferenceCount::init_type(); 00052 register_type(_type_handle, "PGMouseWatcherParameter", 00053 TypedWritableReferenceCount::get_class_type()); 00054 } 00055 virtual TypeHandle get_type() const { 00056 return get_class_type(); 00057 } 00058 virtual TypeHandle force_init_type() {init_type(); return get_class_type();} 00059 00060 private: 00061 static TypeHandle _type_handle; 00062 }; 00063 00064 #include "pgMouseWatcherParameter.I" 00065 00066 #endif