]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/mac/carbon/brush.h
added missing consts and pass objects by const reference instead of by value (patch...
[wxWidgets.git] / include / wx / mac / carbon / brush.h
index 6f915f9d8f29eb3cb5e2f283d600883fe5e5b8aa..2bdfa0fb13e3ef7192a644e6ddfe5d94ef357e7c 100644 (file)
 #ifndef _WX_BRUSH_H_
 #define _WX_BRUSH_H_
 
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-#pragma interface "brush.h"
-#endif
-
 #include "wx/gdicmn.h"
 #include "wx/gdiobj.h"
 #include "wx/bitmap.h"
@@ -30,7 +26,7 @@ typedef enum
 } wxMacBrushKind ;
 
 // Brush
-class WXDLLEXPORT wxBrush: public wxGDIObject
+class WXDLLEXPORT wxBrush: public wxBrushBase
 {
     DECLARE_DYNAMIC_CLASS(wxBrush)
 
@@ -40,7 +36,7 @@ public:
     wxBrush(const wxColour& col, int style = wxSOLID);
     wxBrush(const wxBitmap& stipple);
     wxBrush(const wxBrush& brush)
-        : wxGDIObject()
+        : wxBrushBase()
         { Ref(brush); }
     ~wxBrush();
 
@@ -53,9 +49,9 @@ public:
 
     wxBrush& operator = (const wxBrush& brush)
     { if (*this == brush) return (*this); Ref(brush); return *this; }
-    bool operator == (const wxBrush& brush)
+    bool operator == (const wxBrush& brush) const
     { return m_refData == brush.m_refData; }
-    bool operator != (const wxBrush& brush)
+    bool operator != (const wxBrush& brush) const
     { return m_refData != brush.m_refData; }
 
     wxMacBrushKind MacGetBrushKind()  const ;
@@ -63,12 +59,9 @@ public:
     unsigned long MacGetThemeBackground(WXRECTPTR extent)  const ;
     short MacGetTheme()  const ;
     wxColour& GetColour() const ;
-    int GetStyle() const ;
+    virtual int GetStyle() const ;
     wxBitmap *GetStipple() const ;
 
-    bool IsHatch() const
-        { return (GetStyle()>=wxBDIAGONAL_HATCH) && (GetStyle()<=wxVERTICAL_HATCH); }
-
     virtual bool Ok() const { return (m_refData != NULL) ; }
 
 // Implementation