diff options
author | fluxgen <fluxgen> | 2002-05-17 10:59:30 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2002-05-17 10:59:30 (GMT) |
commit | e296c91a188c9e66cb4fd13c3986fc17e7179db1 (patch) | |
tree | 268e137cbb81f2fa778e166cea00861ce0329d95 | |
parent | b77eec73c58c9c75436516c3295b95c632823380 (diff) | |
download | fluxbox_paul-e296c91a188c9e66cb4fd13c3986fc17e7179db1.zip fluxbox_paul-e296c91a188c9e66cb4fd13c3986fc17e7179db1.tar.bz2 |
removed const on return values of fundamental types and const-correct on BTexture
-rw-r--r-- | src/Image.hh | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/src/Image.hh b/src/Image.hh index 1ac921a..677acbb 100644 --- a/src/Image.hh +++ b/src/Image.hh | |||
@@ -22,7 +22,7 @@ | |||
22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
23 | // DEALINGS IN THE SOFTWARE. | 23 | // DEALINGS IN THE SOFTWARE. |
24 | 24 | ||
25 | // $Id: Image.hh,v 1.6 2002/03/19 00:04:36 fluxgen Exp $ | 25 | // $Id: Image.hh,v 1.7 2002/05/17 10:59:30 fluxgen Exp $ |
26 | 26 | ||
27 | #ifndef IMAGE_HH | 27 | #ifndef IMAGE_HH |
28 | #define IMAGE_HH | 28 | #define IMAGE_HH |
@@ -49,13 +49,13 @@ public: | |||
49 | BColor(char r = 0, char g = 0, char b = 0) | 49 | BColor(char r = 0, char g = 0, char b = 0) |
50 | { red = r; green = g; blue = b; pixel = 0; allocated = 0; } | 50 | { red = r; green = g; blue = b; pixel = 0; allocated = 0; } |
51 | 51 | ||
52 | inline const int &isAllocated(void) const { return allocated; } | 52 | inline int isAllocated(void) const { return allocated; } |
53 | 53 | ||
54 | inline const unsigned char getRed(void) const { return red; } | 54 | inline unsigned char getRed(void) const { return red; } |
55 | inline const unsigned char getGreen(void) const { return green; } | 55 | inline unsigned char getGreen(void) const { return green; } |
56 | inline const unsigned char getBlue(void) const { return blue; } | 56 | inline unsigned char getBlue(void) const { return blue; } |
57 | 57 | ||
58 | inline const unsigned long getPixel(void) const { return pixel; } | 58 | inline unsigned long getPixel(void) const { return pixel; } |
59 | 59 | ||
60 | inline void setAllocated(int a) { allocated = a; } | 60 | inline void setAllocated(int a) { allocated = a; } |
61 | inline void setRGB(char r, char g, char b) { red = r; green = g; blue = b; } | 61 | inline void setRGB(char r, char g, char b) { red = r; green = g; blue = b; } |
@@ -69,14 +69,19 @@ private: | |||
69 | unsigned long texture; | 69 | unsigned long texture; |
70 | 70 | ||
71 | public: | 71 | public: |
72 | BTexture(void) { texture = 0; } | 72 | BTexture(void):texture(0) { } |
73 | |||
74 | inline const BColor *getColor(void) const { return &color; } | ||
75 | inline const BColor *getColorTo(void) const { return &colorTo; } | ||
76 | inline const BColor *getHiColor(void) const { return &hiColor; } | ||
77 | inline const BColor *getLoColor(void) const { return &loColor; } | ||
73 | 78 | ||
74 | inline BColor *getColor(void) { return &color; } | 79 | inline BColor *getColor(void) { return &color; } |
75 | inline BColor *getColorTo(void) { return &colorTo; } | 80 | inline BColor *getColorTo(void) { return &colorTo; } |
76 | inline BColor *getHiColor(void) { return &hiColor; } | 81 | inline BColor *getHiColor(void) { return &hiColor; } |
77 | inline BColor *getLoColor(void) { return &loColor; } | 82 | inline BColor *getLoColor(void) { return &loColor; } |
78 | 83 | ||
79 | inline const unsigned long getTexture(void) const { return texture; } | 84 | inline unsigned long getTexture(void) const { return texture; } |
80 | 85 | ||
81 | inline void setTexture(unsigned long t) { texture = t; } | 86 | inline void setTexture(unsigned long t) { texture = t; } |
82 | inline void addTexture(unsigned long t) { texture |= t; } | 87 | inline void addTexture(unsigned long t) { texture |= t; } |
@@ -157,7 +162,7 @@ public: | |||
157 | 162 | ||
158 | inline BaseDisplay *getBaseDisplay(void) { return basedisplay; } | 163 | inline BaseDisplay *getBaseDisplay(void) { return basedisplay; } |
159 | 164 | ||
160 | inline const bool doDither(void) { return dither; } | 165 | inline bool doDither(void) { return dither; } |
161 | inline const Colormap &getColormap(void) const { return colormap; } | 166 | inline const Colormap &getColormap(void) const { return colormap; } |
162 | inline ScreenInfo *getScreenInfo(void) { return screeninfo; } | 167 | inline ScreenInfo *getScreenInfo(void) { return screeninfo; } |
163 | 168 | ||
@@ -165,9 +170,9 @@ public: | |||
165 | 170 | ||
166 | inline Visual *getVisual(void) { return screeninfo->getVisual(); } | 171 | inline Visual *getVisual(void) { return screeninfo->getVisual(); } |
167 | 172 | ||
168 | inline const int getBitsPerPixel(void) const { return bits_per_pixel; } | 173 | inline int getBitsPerPixel(void) const { return bits_per_pixel; } |
169 | inline const int getDepth(void) const { return screen_depth; } | 174 | inline int getDepth(void) const { return screen_depth; } |
170 | inline const int getColorsPerChannel(void) const | 175 | inline int getColorsPerChannel(void) const |
171 | { return colors_per_channel; } | 176 | { return colors_per_channel; } |
172 | 177 | ||
173 | unsigned long getColor(const char *); | 178 | unsigned long getColor(const char *); |