]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/colour.cpp
don't waste time initializing the memory of newly created wxImage before filling...
[wxWidgets.git] / src / gtk / colour.cpp
index d8176b0b6cbb4214c8b60cbb659a399fd9168d7a..ebb55bb7b01f4fbea09cc3cd74f146773699d6f9 100644 (file)
@@ -4,7 +4,7 @@
 // Author:      Robert Roebling
 // Id:          $Id$
 // Copyright:   (c) 1998 Robert Roebling
-// Licence:     wxWidgets licence
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 
@@ -146,7 +146,8 @@ void wxColourRefData::AllocColour( GdkColormap *cmap )
 
 #define M_COLDATA ((wxColourRefData *)m_refData)
 
-#define SHIFT (8*(sizeof(short int)-sizeof(char)))
+// GDK's values are in 0..65535 range, our are in 0..255
+#define SHIFT  8
 
 IMPLEMENT_DYNAMIC_CLASS(wxColour,wxGDIObject)