]> Dogcows Code - chaz/openbox/blobdiff - src/blackbox.hh
fix bug where destroying the wrong windows in BlackboxWindow::positionButtons.
[chaz/openbox] / src / blackbox.hh
index b494039c1c4d41075f13a93ddc43b68695c8f293..a54346248e434430ec51bdaabe0b66307e709d04 100644 (file)
@@ -26,7 +26,6 @@
 
 extern "C" {
 #include <X11/Xlib.h>
-#include <X11/Xresource.h>
 
 #ifdef    HAVE_STDIO_H
 # include <stdio.h>
@@ -50,6 +49,7 @@ extern "C" {
 
 #include "i18n.hh"
 #include "BaseDisplay.hh"
+#include "Configuration.hh"
 #include "Timer.hh"
 
 #define AttribShaded      (1l << 0)
@@ -109,10 +109,11 @@ private:
   struct BResource {
     Time double_click_interval;
 
-    std::string menu_file, style_file;
+    std::string style_file;
     int colors_per_channel;
     timeval auto_raise_delay;
     unsigned long cache_life, cache_max;
+    std::string titlebar_layout;
   } resource;
 
   typedef std::map<Window, BlackboxWindow*> WindowLookup;
@@ -144,11 +145,12 @@ private:
   BScreen *active_screen;
   BlackboxWindow *focused_window;
   BTimer *timer;
+  Configuration config;
 
   bool no_focus, reconfigure_wait, reread_menu_wait;
   Time last_time;
   char **argv;
-  std::string rc_file;
+  std::string menu_file, rc_file;
 
   Atom xa_wm_colormap_windows, xa_wm_protocols, xa_wm_state,
     xa_wm_delete_window, xa_wm_take_focus, xa_wm_change_state,
@@ -195,7 +197,6 @@ private:
 
   void load_rc(void);
   void save_rc(void);
-  void reload_rc(void);
   void real_rereadMenu(void);
   void real_reconfigure(void);
 
@@ -205,7 +206,7 @@ private:
 
 
 public:
-  Blackbox(char **m_argv, char *dpy_name = 0, char *rc = 0);
+  Blackbox(char **m_argv, char *dpy_name = 0, char *rc = 0, char *menu = 0);
   virtual ~Blackbox(void);
 
   Basemenu *searchMenu(Window window);
@@ -228,6 +229,7 @@ public:
 
   inline BlackboxWindow *getFocusedWindow(void) { return focused_window; }
 
+  inline Configuration *getConfig() { return &config; }
   inline const Time &getDoubleClickInterval(void) const
   { return resource.double_click_interval; }
   inline const Time &getLastTime(void) const { return last_time; }
@@ -235,11 +237,14 @@ public:
   inline const char *getStyleFilename(void) const
     { return resource.style_file.c_str(); }
   inline const char *getMenuFilename(void) const
-    { return resource.menu_file.c_str(); }
+    { return menu_file.c_str(); }
 
   inline int getColorsPerChannel(void) const
     { return resource.colors_per_channel; }
 
+  inline std::string getTitlebarLayout(void) const
+    { return resource.titlebar_layout; }
+
   inline const timeval &getAutoRaiseDelay(void) const
     { return resource.auto_raise_delay; }
 
@@ -261,9 +266,8 @@ public:
 
   void setFocusedWindow(BlackboxWindow *w);
   void shutdown(void);
-  void load_rc(BScreen *screen);
   void saveStyleFilename(const std::string& filename);
-  void saveMenuFilename(const std::string& filename);
+  void addMenuTimestamp(const std::string& filename);
   void restart(const char *prog = 0);
   void reconfigure(void);
   void rereadMenu(void);
This page took 0.023914 seconds and 4 git commands to generate.