Panda3D
|
00001 // Filename: eventReceiver.h 00002 // Created by: drose (14Dec99) 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 EVENTRECEIVER_H 00016 #define EVENTRECEIVER_H 00017 00018 #include "pandabase.h" 00019 #include "typedObject.h" 00020 00021 //////////////////////////////////////////////////////////////////// 00022 // Class : EventReceiver 00023 // Description : An abstract base class for anything that might care 00024 // about receiving events. An object that might receive 00025 // an event should inherit from this class; each event 00026 // may be sent with an optional EventReceiver pointer. 00027 //////////////////////////////////////////////////////////////////// 00028 class EXPCL_PANDA_EVENT EventReceiver { 00029 00030 public: 00031 static TypeHandle get_class_type() { 00032 return _type_handle; 00033 } 00034 static void init_type() { 00035 register_type(_type_handle, "EventReceiver"); 00036 } 00037 00038 private: 00039 static TypeHandle _type_handle; 00040 }; 00041 00042 #endif 00043 00044