14 #ifndef PYTHONCALLBACKOBJECT_H 15 #define PYTHONCALLBACKOBJECT_H 30 PythonCallbackObject(PyObject *
function = Py_None);
31 virtual ~PythonCallbackObject();
32 ALLOC_DELETED_CHAIN(PythonCallbackObject);
34 void set_function(PyObject *
function);
35 PyObject *get_function();
37 MAKE_PROPERTY(
function, get_function, set_function);
51 static void init_type() {
52 CallbackObject::init_type();
54 CallbackObject::get_class_type());
57 return get_class_type();
59 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This is a generic data block that is passed along to a CallbackObject when a callback is made.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
virtual void do_callback(CallbackData *cbdata)
This method called when the callback is triggered; it *replaces* the original function.
This is a generic object that can be assigned to a callback at various points in the rendering proces...
TypeHandle is the identifier used to differentiate C++ class types.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.