]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/demo/wxDragImage.py
WinCE patches from "Viktor Voroshylo" <viktor@voroshylo.com>
[wxWidgets.git] / wxPython / demo / wxDragImage.py
index 5fcecb0d539d1228b4c81d46314fe50df0dff7fb..8506fb72006003552128407a255d709fb46e58f7 100644 (file)
@@ -29,9 +29,9 @@ class DragShape:
             memDC = wxMemoryDC()
             memDC.SelectObject(self.bmp)
 
-            dc.Blit(self.pos.x, self.pos.y,
-                    self.bmp.GetWidth(), self.bmp.GetHeight(),
-                    memDC, 0, 0, op, True)
+            dc.Blit((self.pos.x, self.pos.y),
+                    (self.bmp.GetWidth(), self.bmp.GetHeight()),
+                    memDC, (0, 0), op, True)
 
             return True
         else:
@@ -74,7 +74,7 @@ class DragCanvas(wxScrolledWindow):
         dc.Clear()
         dc.SetTextForeground(wxRED)
         dc.SetFont(font)
-        dc.DrawText(text, 0, 0)
+        dc.DrawText(text, (0, 0))
         dc.SelectObject(wxNullBitmap)
         mask = wxMaskColour(bmp, bg_colour)
         bmp.SetMask(mask)
@@ -117,7 +117,7 @@ class DragCanvas(wxScrolledWindow):
         while x < sz.width:
             y = 0
             while y < sz.height:
-                dc.DrawBitmap(self.bg_bmp, x, y)
+                dc.DrawBitmap(self.bg_bmp, (x, y))
                 y = y + h
             x = x + w
 
@@ -194,7 +194,7 @@ class DragCanvas(wxScrolledWindow):
         if not self.dragShape or not evt.Dragging() or not evt.LeftIsDown():
             return
 
-        # if we have a shape, but havn't started dragging yet
+        # if we have a shape, but haven't started dragging yet
         if self.dragShape and not self.dragImage:
 
             # only start the drag after having moved a couple pixels