X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8410a7104a8506c111f417d204a0d7dbb2a45fc0..3030ae493df7500fd5da7555f141c0c8a690bd8a:/contrib/src/ogl/oglmisc.cpp?ds=sidebyside diff --git a/contrib/src/ogl/oglmisc.cpp b/contrib/src/ogl/oglmisc.cpp index 3f63c09317..74ee28613f 100644 --- a/contrib/src/ogl/oglmisc.cpp +++ b/contrib/src/ogl/oglmisc.cpp @@ -9,10 +9,6 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ -#pragma implementation "misc.h" -#endif - // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -21,14 +17,14 @@ #endif #ifndef WX_PRECOMP -#include +#include "wx/wx.h" #endif #if wxUSE_PROLOGIO -#include +#include "wx/deprecated/wxexpr.h" #endif -#include +#include "wx/types.h" #ifdef new #undef new @@ -452,7 +448,7 @@ wxStringList *oglFormatText(wxDC& dc, const wxString& text, double width, double wxString oldBuffer(buffer); wxString s = node->GetData(); - if (s.IsEmpty()) + if (s.empty()) { // FORCE NEW LINE if (buffer.Length() > 0) @@ -871,10 +867,12 @@ wxColour oglHexToColour(const wxString& hex) hex.Mid(0,2).ToLong(&r, 16); hex.Mid(2,2).ToLong(&g, 16); hex.Mid(4,2).ToLong(&b, 16); - return wxColour(r, g, b); + return wxColour((unsigned char)r, + (unsigned char)g, + (unsigned char)b); } else - return wxColour(0,0,0); + return *wxBLACK; } // RGB to 3-digit hex