summaryrefslogtreecommitdiff
path: root/util/epist/epist.hh
diff options
context:
space:
mode:
Diffstat (limited to 'util/epist/epist.hh')
-rw-r--r--util/epist/epist.hh37
1 files changed, 33 insertions, 4 deletions
diff --git a/util/epist/epist.hh b/util/epist/epist.hh
index 2f5d7399..061e1f4d 100644
--- a/util/epist/epist.hh
+++ b/util/epist/epist.hh
@@ -27,11 +27,40 @@ extern "C" {
#include <X11/Xlib.h>
}
+#include <string>
+#include <map>
+
+#include "../../src/BaseDisplay.hh"
+
class XAtom;
+class screen;
+class XWindow;
+
+class epist : public BaseDisplay {
+private:
+ std::string _rc_file;
+ XAtom *_xatom;
+ char **_argv;
+
+ typedef std::vector<screen *> ScreenList;
+ ScreenList _screens;
+
+ typedef std::map<Window, XWindow*> WindowLookup;
+ typedef WindowLookup::value_type WindowLookupPair;
+ WindowLookup _windows;
+
+ virtual void process_event(XEvent *e);
+ virtual bool handleSignal(int sig);
+
+public:
+ epist(char **argv, char *display_name, char *rc_file);
+ virtual ~epist();
+
+ inline XAtom *xatom() { return _xatom; }
-extern bool _shutdown;
-extern Display *_display;
-extern Window _root;
-extern XAtom *_xatom;
+ void addWindow(XWindow *window);
+ void removeWindow(XWindow *window);
+ XWindow *findWindow(Window window) const;
+};
#endif // __epist_hh