]> git.saurik.com Git - wxWidgets.git/blobdiff - src/x11/colour.cpp
fixing the shrinking embedded controls
[wxWidgets.git] / src / x11 / colour.cpp
index 32d69c30a0725f27eb135b118df6cab8f06f109d..2890656e0ef901b333f42c686acc53d54d813351 100644 (file)
 
 #ifndef WX_PRECOMP
     #include "wx/app.h"
+    #include "wx/gdicmn.h"
 #endif
 
-#include "wx/gdicmn.h"
-
 #include "wx/x11/private.h"
 
 //-----------------------------------------------------------------------------
@@ -46,7 +45,7 @@ public:
         m_hasPixel = data.m_hasPixel;
     }
 
-    ~wxColourRefData()
+    virtual ~wxColourRefData()
     {
         FreeColour();
     }
@@ -173,7 +172,8 @@ wxObjectRefData *wxColour::CloneRefData(const wxObjectRefData *data) const
     return new wxColourRefData(*(wxColourRefData *)data);
 }
 
-void wxColour::InitWith( unsigned char red, unsigned char green, unsigned char blue )
+void wxColour::InitRGBA(unsigned char red, unsigned char green, unsigned char blue,
+                        unsigned char WXUNUSED(alpha))
 {
     AllocExclusive();
 
@@ -250,7 +250,7 @@ bool wxColour::FromString(const wxChar *name)
     Display *dpy = wxGlobalDisplay();
     WXColormap colormap = wxTheApp->GetMainColormap( dpy );
     XColor xcol;
-    if ( XParseColor( dpy, (Colormap)colormap, name , &xcol ) )
+    if ( XParseColor( dpy, (Colormap)colormap, wxConvertWX2MB(name), &xcol ) )
     {
         UnRef();