]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/colour.cpp
cgimagecreate from wxbitmap crashes 10.2 - turn off. Put in right click handler to...
[wxWidgets.git] / src / gtk1 / colour.cpp
index d8176b0b6cbb4214c8b60cbb659a399fd9168d7a..60735789ebf5aa0454b50134af65711de57b3a2a 100644 (file)
@@ -4,7 +4,7 @@
 // Author:      Robert Roebling
 // Id:          $Id$
 // Copyright:   (c) 1998 Robert Roebling
-// Licence:     wxWidgets licence
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 
@@ -15,8 +15,8 @@
 // For compilers that support precompilation, includes "wx.h".
 #include "wx/wxprec.h"
 
-#include "wx/gdicmn.h"
 #include "wx/colour.h"
+#include "wx/gdicmn.h"
 #include "wx/gtk/private.h"
 
 #include <gdk/gdk.h>
@@ -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)