X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;ds=sidebyside;f=wrap%2Fob.i;fp=wrap%2Fob.i;h=7fbd8e83e3d914b45ec33c8501c0d1ff967a7b46;hb=c217a730901137252cde2d3a39b59c4ebd53e879;hp=fa2d020e506fcd1ec0695eafba47a50d0421e70d;hpb=0dd7ebcba90752d3ad832586f0c1745660078a03;p=chaz%2Fopenbox diff --git a/wrap/ob.i b/wrap/ob.i index fa2d020e..7fbd8e83 100644 --- a/wrap/ob.i +++ b/wrap/ob.i @@ -3,67 +3,8 @@ %module ob %{ -#include "config.h" - -#include "frame.hh" -#include "openbox.hh" -#include "screen.hh" -#include "client.hh" -#include "bindings.hh" -#include "actions.hh" -#include "python.hh" -#include "otk/otk.hh" -%} - -%include "stl.i" -%include "callback.i" - -%immutable ob::openbox; -/* -%ignore ob::openbox; -%inline %{ - ob::Openbox *Openbox_instance() { return ob::openbox; } -%}; -*/ - -%typemap(python,out) std::list { - unsigned int s = $1.size(); - PyObject *l = PyList_New(s); - - std::list::const_iterator it = $1.begin(), end = $1.end(); - for (unsigned int i = 0; i < s; ++i, ++it) { - PyObject *pdata = SWIG_NewPointerObj((void *) *it, - SWIGTYPE_p_ob__Client, 0); - PyList_SET_ITEM(l, i, pdata); - } - $result = l; -} - -// do this through events -%ignore ob::Screen::showDesktop(bool); - -%ignore ob::Screen::managed; -%ignore ob::Screen::config; - -%import "otk.i" - -%import "actions.hh" - -%include "openbox.hh" -%include "screen.hh" -%include "client.hh" -%include "frame.hh" -%include "python.hh" - -// for Window etc -%import "X11/X.h" - -%inline %{ -void set_reset_key(const std::string &key) -{ - ob::openbox->bindings()->setResetKey(key); -} - +#include +#include "otk/display.hh" void send_client_msg(Window target, Atom type, Window about, long data=0, long data1=0, long data2=0, long data3=0, long data4=0) @@ -84,6 +25,27 @@ void send_client_msg(Window target, Atom type, Window about, &e); } +%} + +%include "ob_openbox.i" +%include "ob_screen.i" +%include "ob_client.i" +%include "ob_frame.i" +%include "ob_python.i" +%include "callback.i" + +%import "otk.i" +// for Window etc +%import "X11/X.h" + +%inline %{ +#include + +void set_reset_key(const std::string &key) +{ + ob::openbox->bindings()->setResetKey(key); +} + void execute(const std::string &bin, int screen=0) { if (screen >= ScreenCount(**otk::display))