X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e52f60e65236befe1a509cc3c1823607be0d2b3c..c96faa7c9b1926d63a2fff32ac4508d3138a7bee:/include/wx/gdicmn.h diff --git a/include/wx/gdicmn.h b/include/wx/gdicmn.h index 2f2570797a..111b6ba1d8 100644 --- a/include/wx/gdicmn.h +++ b/include/wx/gdicmn.h @@ -69,6 +69,7 @@ public: inline wxSize(long xx, long yy) { x = xx; y = yy; } inline wxSize(const wxSize& sz) { x = sz.x; y = sz.y; } inline void operator = (const wxSize& sz) { x = sz.x; y = sz.y; } + inline bool operator == (const wxSize& sz) const { return (x == sz.x && y == sz.y); } inline wxSize operator + (const wxSize& sz) { return wxSize(x + sz.x, y + sz.y); } inline wxSize operator - (const wxSize& sz) { return wxSize(x - sz.x, y - sz.y); } inline void Set(long xx, long yy) { x = xx; y = yy; } @@ -88,6 +89,7 @@ class WXDLLEXPORT wxRealPoint inline wxRealPoint operator - (const wxRealPoint& pt) { return wxRealPoint(x - pt.x, y - pt.y); } inline void operator = (const wxRealPoint& pt) { x = pt.x; y = pt.y; } + inline bool operator == (const wxRealPoint& pt) const { return (x == pt.x && y == pt.y); } }; class WXDLLEXPORT wxPoint @@ -106,6 +108,7 @@ class WXDLLEXPORT wxPoint wxPoint(const wxPoint& pt) { x = pt.x; y = pt.y; }; inline void operator = (const wxPoint& pt) { x = pt.x; y = pt.y; } + inline bool operator == (const wxPoint& pt) const { return (x == pt.x && y == pt.y); } inline wxPoint operator + (const wxPoint& pt) { return wxPoint(x + pt.x, y + pt.y); } inline wxPoint operator - (const wxPoint& pt) { return wxPoint(x - pt.x, y - pt.y); } }; @@ -156,6 +159,7 @@ class WXDLLEXPORT wxCursor; class WXDLLEXPORT wxFont; class WXDLLEXPORT wxPalette; class WXDLLEXPORT wxPalette; +class WXDLLEXPORT wxRegion; /* * Bitmap flags @@ -178,6 +182,8 @@ class WXDLLEXPORT wxPalette; #define wxBITMAP_TYPE_GIF_RESOURCE 14 #define wxBITMAP_TYPE_PNG 15 #define wxBITMAP_TYPE_PNG_RESOURCE 16 +#define wxBITMAP_TYPE_JPEG 17 +#define wxBITMAP_TYPE_JPEG_RESOURCE 18 #define wxBITMAP_TYPE_ANY 50 #define wxBITMAP_TYPE_RESOURCE wxBITMAP_TYPE_BMP_RESOURCE @@ -213,7 +219,7 @@ class WXDLLEXPORT wxBrushList: public wxList wxBrush *FindOrCreateBrush(const wxColour& colour, int style); }; -WXDLLEXPORT_DATA(extern const char*) wxEmptyString; +WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; class WXDLLEXPORT wxFontList: public wxList { @@ -331,9 +337,12 @@ extern void WXDLLEXPORT wxSetCursor(const wxCursor& cursor); // Load from a resource # define wxICON(X) wxIcon("" #X "") -#elif defined(__WXGTK__) || defined(__WXMOTIF__) +#elif defined(__WXGTK__) // Initialize from an included XPM # define wxICON(X) wxIcon( (const char**) X##_xpm ) +#elif defined(__WXMOTIF__) +// Initialize from an included XPM +# define wxICON(X) wxIcon( X##_xpm ) #else // This will usually mean something on any platform @@ -350,11 +359,13 @@ extern void WXDLLEXPORT wxSetCursor(const wxCursor& cursor); class WXDLLEXPORT wxResourceCache: public wxList { - DECLARE_DYNAMIC_CLASS(wxResourceCache) - public: - wxResourceCache(); - wxResourceCache(const unsigned int the_key_type); - ~wxResourceCache(); +public: + wxResourceCache() { } + wxResourceCache(const unsigned int keyType) : wxList(keyType) { } + ~wxResourceCache(); + +private: + DECLARE_DYNAMIC_CLASS(wxResourceCache) }; #endif