From: Andreas Monzner Date: Sun, 10 Dec 2006 22:32:39 +0000 (+0000) Subject: export gRGB to python again X-Git-Tag: 2.6.0~2607 X-Git-Url: https://git.cweiske.de/enigma2.git/commitdiff_plain/54c5d207bf165cda83eec602c57ed36d1f278454 export gRGB to python again --- diff --git a/lib/gdi/gpixmap.h b/lib/gdi/gpixmap.h index cc2a4cf4..d717ec6f 100644 --- a/lib/gdi/gpixmap.h +++ b/lib/gdi/gpixmap.h @@ -9,20 +9,6 @@ #include #include -#ifndef SWIG -struct gColor -{ - int color; - gColor(int color): color(color) - { - } - gColor(): color(0) - { - } - operator int() const { return color; } - bool operator==(const gColor &o) const { return o.color==color; } -}; - struct gRGB { unsigned char b, g, r, a; @@ -35,12 +21,12 @@ struct gRGB gRGB(): b(0), g(0), r(0), a(0) { } - + unsigned long argb() const { return (a<<24)|(r<<16)|(g<<8)|b; } - + void operator=(unsigned long val) { b = val&0xFF; @@ -72,6 +58,20 @@ struct gRGB } }; +#ifndef SWIG +struct gColor +{ + int color; + gColor(int color): color(color) + { + } + gColor(): color(0) + { + } + operator int() const { return color; } + bool operator==(const gColor &o) const { return o.color==color; } +}; + struct gPalette { int start, colors;