#include "bindings.hh"
#include "actions.hh"
#include "python.hh"
-#include "otk/display.hh"
+#include "otk/otk.hh"
%}
%include "stl.i"
%{
namespace ob {
-void python_callback(PyObject *func, MotionData *data)
+void python_callback(PyObject *func, MouseData *data)
{
PyObject *arglist;
PyObject *result;
arglist = Py_BuildValue("(O)", SWIG_NewPointerObj((void *) data,
- SWIGTYPE_p_ob__MotionData,
- 0));
-
- // call the callback
- result = PyEval_CallObject(func, arglist);
- if (!result || PyErr_Occurred()) {
- // an exception occured in the script, display it
- PyErr_Print();
- }
-
- Py_XDECREF(result);
- Py_DECREF(arglist);
-}
-
-void python_callback(PyObject *func, ButtonData *data)
-{
- PyObject *arglist;
- PyObject *result;
-
- arglist = Py_BuildValue("(O)", SWIG_NewPointerObj((void *) data,
- SWIGTYPE_p_ob__ButtonData,
+ SWIGTYPE_p_ob__MouseData,
0));
// call the callback
}
};
-%import "../otk/eventdispatcher.hh"
-%import "../otk/eventhandler.hh"
-%import "widget.hh"
+%import "../otk/otk.i"
+
+%import "widgetbase.hh"
%import "actions.hh"
%include "openbox.hh"