]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/dcmemory.cpp
Updated version to 2.3.2 so apps can test for differences in new merged source
[wxWidgets.git] / src / gtk / dcmemory.cpp
index 27dd0e8e9d531d44ebde4e5f1da27bddabe10d28..a1e0c244522876fd6e6ce37b46803511e5f8f31a 100644 (file)
@@ -43,6 +43,7 @@ wxMemoryDC::~wxMemoryDC()
 
 void wxMemoryDC::SelectObject( const wxBitmap& bitmap )
 {
 
 void wxMemoryDC::SelectObject( const wxBitmap& bitmap )
 {
+    Destroy();
     m_selected = bitmap;
     if (m_selected.Ok())
     {
     m_selected = bitmap;
     if (m_selected.Ok())
     {
@@ -55,9 +56,9 @@ void wxMemoryDC::SelectObject( const wxBitmap& bitmap )
             m_window = m_selected.GetBitmap();
         }
 
             m_window = m_selected.GetBitmap();
         }
 
-        SetUpDC();
-
         m_isMemDC = TRUE;
         m_isMemDC = TRUE;
+
+        SetUpDC();
     }
     else
     {
     }
     else
     {