Skip to content

Commit

Permalink
Merge pull request #62 from mluessi/wxpython_2.9
Browse files Browse the repository at this point in the history
FIX: use kwargs for wxpython 2.9 compat
  • Loading branch information
prabhuramachandran committed Apr 6, 2013
2 parents c9b4767 + d1d2f63 commit 576b9ca
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tvtk/pyface/ui/wx/wxVTKRenderWindowInteractor.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
_useCapture = (wx.Platform == "__WXMSW__")

# for wx < 2.9.2, CmdDown is preferred to ControlDown since it catches the
# meta key on OS X, but in later versions, CmdDown is depricated and its
# meta key on OS X, but in later versions, CmdDown is depricated and its
# functionality moved to ControlDown
_useCmdDown = (wx.VERSION[0] < 2) or \
(wx.VERSION[0] == 2 and wx.VERSION[1] < 9) or \
Expand Down Expand Up @@ -182,11 +182,13 @@ def __init__(self, parent, ID, *args, **kw):
attribList.append(wx.glcanvas.WX_GL_STEREO)

try:
baseClass.__init__(self, parent, ID, position, size, style,
baseClass.__init__(self, parent, id=ID, pos=position,
size=size, style=style,
attribList=attribList)
except wx.PyAssertionError:
# visual couldn't be allocated, so we go back to default
baseClass.__init__(self, parent, ID, position, size, style)
baseClass.__init__(self, parent, id=ID, pos=position,
size=size, style=style)
if stereo:
# and make sure everyone knows that the stereo
# visual wasn't set.
Expand Down

0 comments on commit 576b9ca

Please sign in to comment.