mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-08 21:10:06 +01:00
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@71161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
17 lines
431 B
Python
17 lines
431 B
Python
|
|
def OnEvent(self, event):
|
|
|
|
dc = wx.ClientDC(self)
|
|
self.DoPrepareDC(dc)
|
|
|
|
dc.SetPen(wx.BLACK_PEN)
|
|
|
|
x, y = event.GetPosition()
|
|
|
|
if (xpos > -1 and ypos > -1 and event.Dragging()):
|
|
dc.DrawLine(xpos, ypos, x, y)
|
|
|
|
xpos = x
|
|
ypos = y
|
|
|