]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/brush.cpp
fix to not show ampersands in the static box title (needed after the previous change)
[wxWidgets.git] / src / motif / brush.cpp
index 804bcaaa3e9bf30ca75aea6bc9271e0dad5fd48f..685b376427d3a7829418348a248b195fc95cab90 100644 (file)
@@ -1,12 +1,12 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        brush.cpp
+// Name:        src/motif/brush.cpp
 // Purpose:     wxBrush
 // Author:      Julian Smart
 // Modified by:
 // Created:     17/09/98
 // RCS-ID:      $Id$
 // Copyright:   (c) Julian Smart
-// Licence:    wxWindows licence
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 #ifdef __GNUG__
@@ -17,9 +17,7 @@
 #include "wx/utils.h"
 #include "wx/brush.h"
 
-#if !USE_SHARED_LIBRARIES
 IMPLEMENT_DYNAMIC_CLASS(wxBrush, wxGDIObject)
-#endif
 
 wxBrushRefData::wxBrushRefData()
 {
@@ -28,9 +26,9 @@ wxBrushRefData::wxBrushRefData()
 
 wxBrushRefData::wxBrushRefData(const wxBrushRefData& data)
 {
-  m_style = data.m_style;
-  m_stipple = data.m_stipple;
-  m_colour = data.m_colour;
+    m_style = data.m_style;
+    m_stipple = data.m_stipple;
+    m_colour = data.m_colour;
 }
 
 wxBrushRefData::~wxBrushRefData()
@@ -40,14 +38,10 @@ wxBrushRefData::~wxBrushRefData()
 // Brushes
 wxBrush::wxBrush()
 {
-    if ( wxTheBrushList )
-        wxTheBrushList->AddBrush(this);
 }
 
 wxBrush::~wxBrush()
 {
-    if ( wxTheBrushList )
-        wxTheBrushList->RemoveBrush(this);
 }
 
 wxBrush::wxBrush(const wxColour& col, int Style)
@@ -58,9 +52,6 @@ wxBrush::wxBrush(const wxColour& col, int Style)
     M_BRUSHDATA->m_style = Style;
 
     RealizeResource();
-
-    if ( wxTheBrushList )
-        wxTheBrushList->AddBrush(this);
 }
 
 wxBrush::wxBrush(const wxBitmap& stipple)
@@ -71,24 +62,21 @@ wxBrush::wxBrush(const wxBitmap& stipple)
     M_BRUSHDATA->m_stipple = stipple;
 
     RealizeResource();
-
-    if ( wxTheBrushList )
-        wxTheBrushList->AddBrush(this);
 }
 
 void wxBrush::Unshare()
 {
-       // Don't change shared data
-       if (!m_refData)
+    // Don't change shared data
+    if (!m_refData)
     {
-               m_refData = new wxBrushRefData();
-       }
+        m_refData = new wxBrushRefData();
+    }
     else
     {
-               wxBrushRefData* ref = new wxBrushRefData(*(wxBrushRefData*)m_refData);
-               UnRef();
-               m_refData = ref;
-       }
+        wxBrushRefData* ref = new wxBrushRefData(*(wxBrushRefData*)m_refData);
+        UnRef();
+        m_refData = ref;
+    }
 }
 
 void wxBrush::SetColour(const wxColour& col)