1 // -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*-
7 # include "../config.h"
14 #include "bindings.hh"
22 //%template(ClientList) std::list<Client*>;
25 %immutable ob::openbox;
29 ob::Openbox *Openbox_instance() { return ob::openbox; }
33 %ignore ob::Screen::clients;
38 Client *client(int i) {
39 if (i < 0 || i >= (int)self->clients.size())
41 ob::Client::List::iterator it = self->clients.begin();
45 int clientCount() const {
46 return (int) self->clients.size();
52 %import "widgetbase.hh"
65 void set_reset_key(const std::string &key)
67 ob::openbox->bindings()->setResetKey(key);
70 void send_client_msg(Window target, Atom type, Window about,
71 long data, long data1, long data2,
72 long data3, long data4)
75 e.xclient.type = ClientMessage;
76 e.xclient.format = 32;
77 e.xclient.message_type = type;
78 e.xclient.window = about;
79 e.xclient.data.l[0] = data;
80 e.xclient.data.l[1] = data1;
81 e.xclient.data.l[2] = data2;
82 e.xclient.data.l[3] = data3;
83 e.xclient.data.l[4] = data4;
85 XSendEvent(**otk::display, target, false,
86 SubstructureRedirectMask | SubstructureNotifyMask,
90 void execute(const std::string &bin, int screen)
92 if (screen >= ScreenCount(**otk::display))
94 otk::bexec(bin, otk::display->screenInfo(screen)->displayString());
101 openbox = cvar.openbox;