]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/dcmemory.cpp
a base for geometry operations
[wxWidgets.git] / src / mac / carbon / dcmemory.cpp
index 7cbd330821f76b4c97a124689b631d859e829e03..28a652368a97e41c1058b70f1469f67367563a3d 100644 (file)
@@ -40,6 +40,18 @@ void wxMemoryDC::SelectObject( const wxBitmap& bitmap )
   m_selected = bitmap;
   if (m_selected.Ok())
   {
+               wxBitmapRefData * bmap = (wxBitmapRefData*) (m_selected.GetRefData()) ;
+               if ( bmap->m_hBitmap )
+               {
+                       m_macPort = (GrafPtr) bmap->m_hBitmap ;
+                       MacSetupPort() ;
+                       m_ok = TRUE ;
+                       // SetBackground(wxBrush(*wxWHITE, wxSOLID));
+               }
+               else
+               {
+           m_ok = FALSE;
+               }
   }
   else
   {