X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2FImage.h;h=5a542c1691f5fe4570bb48bedc19514664820ee1;hb=eb8a11a5a7b066ada63cc3550f8314f53eaf1a39;hp=249f2672c4b13f499b281fd4ecb1e0b5aa77d1ef;hpb=dfc5f034581f5a26cba5c4811500438f89f0634a;p=chaz%2Fopenbox diff --git a/src/Image.h b/src/Image.h index 249f2672..5a542c16 100644 --- a/src/Image.h +++ b/src/Image.h @@ -26,8 +26,8 @@ #include #include -#include "LinkedList.h" #include "Timer.h" +#include class ScreenInfo; class BImage; @@ -114,7 +114,7 @@ public: class BImage { private: - BImageControl *control; + BImageControl &control; #ifdef INTERLACE Bool interlaced; @@ -148,7 +148,7 @@ protected: public: - BImage(BImageControl *, unsigned int, unsigned int); + BImage(BImageControl &, unsigned int, unsigned int); ~BImage(void); Pixmap render(BTexture *); @@ -160,8 +160,8 @@ public: class BImageControl : public TimeoutHandler { private: Bool dither; - BaseDisplay *basedisplay; - ScreenInfo *screeninfo; + BaseDisplay &basedisplay; + ScreenInfo &screeninfo; #ifdef TIMEDCACHE BTimer *timer; #endif // TIMEDCACHE @@ -186,7 +186,8 @@ private: unsigned long pixel1, pixel2, texture; } Cache; - LinkedList *cache; + typedef std::list CacheList; + CacheList cache; protected: @@ -195,19 +196,19 @@ protected: public: - BImageControl(BaseDisplay *, ScreenInfo *, Bool = False, int = 4, + BImageControl(BaseDisplay &, ScreenInfo &, Bool = False, int = 4, unsigned long = 300000l, unsigned long = 200l); virtual ~BImageControl(void); - inline BaseDisplay *getBaseDisplay(void) { return basedisplay; } + inline BaseDisplay &getBaseDisplay(void) { return basedisplay; } inline const Bool &doDither(void) { return dither; } - inline ScreenInfo *getScreenInfo(void) { return screeninfo; } + inline ScreenInfo &getScreenInfo(void) { return screeninfo; } inline const Window &getDrawable(void) const { return window; } - inline Visual *getVisual(void) { return screeninfo->getVisual(); } + inline Visual *getVisual(void) { return screeninfo.getVisual(); } inline const int &getBitsPerPixel(void) const { return bits_per_pixel; } inline const int &getDepth(void) const { return screen_depth; } @@ -230,8 +231,8 @@ public: unsigned int **, unsigned int **); void setDither(Bool d) { dither = d; } void setColorsPerChannel(int); - void parseTexture(BTexture *, char *); - void parseColor(BColor *, char * = 0); + void parseTexture(BTexture *, const char *); + void parseColor(BColor *, const char * = 0); virtual void timeout(void); };