]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/dc.cpp
define ChangeSelection() (fixes wxMotif build)
[wxWidgets.git] / src / msw / dc.cpp
index 50e86d027cfad0cfc7c7d31b154c735e93c528e5..03375ff1083a7e81509d36956401417ffd14df68 100644 (file)
@@ -25,6 +25,7 @@
 #endif
 
 #ifndef WX_PRECOMP
+    #include "wx/msw/wrapcdlg.h"
     #include "wx/image.h"
     #include "wx/window.h"
     #include "wx/dc.h"
@@ -48,7 +49,6 @@
 
 #include <string.h>
 
-#include "wx/msw/wrapcdlg.h"
 #ifndef __WIN32__
     #include <print.h>
 #endif
@@ -554,9 +554,9 @@ void wxDC::Clear()
         if (!m_selectedBitmap.Ok())
             return;
 
-        rect.left = 0; rect.top = 0;
-        rect.right = m_selectedBitmap.GetWidth();
-        rect.bottom = m_selectedBitmap.GetHeight();
+        rect.left = -m_deviceOriginX; rect.top = -m_deviceOriginY;
+        rect.right = m_selectedBitmap.GetWidth()-m_deviceOriginX;
+        rect.bottom = m_selectedBitmap.GetHeight()-m_deviceOriginY;
     }
 
 #ifndef __WXWINCE__
@@ -2258,7 +2258,7 @@ bool wxDC::DoBlit(wxCoord xdest, wxCoord ydest,
                                      ds.dsBm.bmBits,
                                      (LPBITMAPINFO)&ds.dsBmih,
                                      DIB_RGB_COLORS,
-                                     SRCCOPY
+                                     dwRop
                                      ) == (int)GDI_ERROR )
                 {
                     // On Win9x this API fails most (all?) of the time, so