diff --git a/panda/src/express/config_express.cxx b/panda/src/express/config_express.cxx index 989c7da2f1..5380ba0b24 100644 --- a/panda/src/express/config_express.cxx +++ b/panda/src/express/config_express.cxx @@ -20,6 +20,7 @@ #include "config_express.h" #include "datagram.h" #include "referenceCount.h" +#include "thread.h" #include "typedObject.h" #include "typedReferenceCount.h" #include "virtualFile.h" @@ -40,6 +41,7 @@ extern void init_system_type_handles(); ConfigureFn(config_express) { Datagram::init_type(); ReferenceCount::init_type(); + Thread::init_type(); TypedObject::init_type(); TypedReferenceCount::init_type(); VirtualFile::init_type(); diff --git a/panda/src/express/thread.cxx b/panda/src/express/thread.cxx index 5375bac786..05e851d5ac 100644 --- a/panda/src/express/thread.cxx +++ b/panda/src/express/thread.cxx @@ -18,6 +18,7 @@ #include "thread.h" +TypeHandle Thread::_type_handle; //////////////////////////////////////////////////////////////////// // Function: Thread::Destructor diff --git a/panda/src/express/thread.h b/panda/src/express/thread.h index cb46863e81..e4194daf2a 100644 --- a/panda/src/express/thread.h +++ b/panda/src/express/thread.h @@ -20,7 +20,7 @@ #define THREAD_H #include "pandabase.h" -#include "referenceCount.h" +#include "typedReferenceCount.h" #include "threadPriority.h" #include "threadImpl.h" #include "notify.h" @@ -37,7 +37,7 @@ // will automatically be destructed if no other pointers // are referencing it. //////////////////////////////////////////////////////////////////// -class EXPCL_PANDAEXPRESS Thread : public ReferenceCount { +class EXPCL_PANDAEXPRESS Thread : public TypedReferenceCount { public: INLINE Thread(const string &name); virtual ~Thread(); @@ -66,6 +66,20 @@ private: string _name; ThreadImpl _impl; friend ThreadImpl; + + +public: + static TypeHandle get_class_type() { + return _type_handle; + } + static void init_type() { + TypedReferenceCount::init_type(); + register_type(_type_handle, "Thread", + TypedReferenceCount::get_class_type()); + } + +private: + static TypeHandle _type_handle; }; #include "thread.I"