]> Dogcows Code - chaz/openbox/blobdiff - src/BaseDisplay.h
compile with -Wall -W -pendantic when --enable-debug is set.
[chaz/openbox] / src / BaseDisplay.h
index 1a44dddc6661e1cb25ad98bb41eef206f89c25d9..cf1a7ae6a44788ca3a4ef5f770785a13152089b9 100644 (file)
 class BaseDisplay;
 class ScreenInfo;
 
-#include "LinkedList.h"
 #include "Timer.h"
 #include "Geometry.h"
+#include "Util.h"
+#include <vector>
+#include <list>
 
 #define AttribShaded      (1l << 0)
 #define AttribMaxHoriz    (1l << 1)
@@ -127,8 +129,12 @@ private:
 
   Bool _startup, _shutdown;
   Display *display;
-  LinkedList<ScreenInfo> *screenInfoList;
-  LinkedList<BTimer> *timerList;
+
+  typedef std::vector<ScreenInfo*> ScreenInfoList;
+  ScreenInfoList screenInfoList;
+  typedef std::list<BTimer*> TimerList;
+  TimerList timerList;
 
   char *display_name, *application_name;
   int number_of_screens, server_grabs, colors_per_channel;
@@ -270,8 +276,10 @@ public:
 
 #endif // NEWWMSPEC
 
-  inline ScreenInfo *getScreenInfo(int s)
-    { return (ScreenInfo *) screenInfoList->find(s); }
+  inline ScreenInfo *getScreenInfo(unsigned int s) {
+    ASSERT(s < screenInfoList.size());
+    return screenInfoList[s];
+  }
 
   inline const Bool &hasShapeExtensions(void) const
     { return shape.extensions; }
This page took 0.021813 seconds and 4 git commands to generate.