[vtk6] 02/07: Update for wxPython 3.0. (Closes: #761413)

Anton Gladky gladk at moszumanska.debian.org
Wed Oct 1 04:34:51 UTC 2014


This is an automated email from the git hooks/post-receive script.

gladk pushed a commit to branch master
in repository vtk6.

commit 38fb397a08455631479a6509b745a87dec7ead2e
Author: Olly Betts <olly at survex.com>
Date:   Tue Sep 30 22:45:41 2014 +0200

    Update for wxPython 3.0. (Closes: #761413)
---
 debian/patches/series            |  1 +
 debian/patches/wxpython3.0.patch | 79 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 80 insertions(+)

diff --git a/debian/patches/series b/debian/patches/series
index 8426dc1..ea38e8c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -13,3 +13,4 @@ use_system_sqlite.patch
 
 # Temporarly disable system_alglib
 # use_system_alglib.patch
+wxpython3.0.patch
diff --git a/debian/patches/wxpython3.0.patch b/debian/patches/wxpython3.0.patch
new file mode 100644
index 0000000..1e69a50
--- /dev/null
+++ b/debian/patches/wxpython3.0.patch
@@ -0,0 +1,79 @@
+Description: Update for wxPython 3.0
+ These changes should remain compatible with wxPython 2.8.
+Bug-Debian: https://bugs.debian.org/761414
+Forwarded: no
+Last-Update: 2014-09-13
+
+--- vtk-5.10.1.orig/Wrapping/Python/vtk/wx/wxVTKRenderWindow.py
++++ vtk-5.10.1/Wrapping/Python/vtk/wx/wxVTKRenderWindow.py
+@@ -19,7 +19,7 @@ Creation:
+ 
+ wxVTKRenderWindow(parent, ID, stereo=0, [wx keywords]):
+ 
+-You should create a wx.PySimpleApp() or some other wx**App
++You should create a wx.App(False) or some other wx.App subclass
+ before creating the window.
+ 
+ ----------------------------------------
+@@ -190,10 +190,12 @@ class wxVTKRenderWindow(baseClass):
+         # initialize the wx.Window
+         if baseClass.__name__ == 'GLCanvas':
+             # Set the doublebuffer attribute of the GL canvas.
+-            baseClass.__init__(self, parent, ID, position, size, style,
++            baseClass.__init__(self, parent, ID, pos=position, size=size,
++                               style=style,
+                                attribList=[wx.glcanvas.WX_GL_DOUBLEBUFFER])
+         else:
+-            baseClass.__init__(self, parent, ID, position, size, style)
++            baseClass.__init__(self, parent, ID, pos=position, size=size,
++                               style=style)
+ 
+         # create the RenderWindow and initialize it
+         self._RenderWindow = vtk.vtkRenderWindow()
+@@ -735,7 +737,7 @@ def wxVTKRenderWindowConeExample():
+     """Like it says, just a simple example.
+     """
+     # every wx app needs an app
+-    app = wx.PySimpleApp()
++    app = wx.App(False)
+ 
+     # create the widget
+     frame = wx.Frame(None, -1, "wxVTKRenderWindow", size=(400,400))
+--- vtk-5.10.1.orig/Wrapping/Python/vtk/wx/wxVTKRenderWindowInteractor.py
++++ vtk-5.10.1/Wrapping/Python/vtk/wx/wxVTKRenderWindowInteractor.py
+@@ -21,8 +21,8 @@ Creation:
+ 
+  wxVTKRenderWindowInteractor(parent, ID, stereo=0, [wx keywords]):
+ 
+- You should create a wx.PySimpleApp() or some other wx**App before
+- creating the window.
++ You should create a wx.App(False) or some other wx.App subclass
++ before creating the window.
+ 
+ Behaviour:
+ 
+@@ -171,11 +171,12 @@ class wxVTKRenderWindowInteractor(baseCl
+                 attribList.append(wx.glcanvas.WX_GL_STEREO)
+ 
+             try:
+-                baseClass.__init__(self, parent, ID, position, size, style,
+-                                   attribList=attribList)
++                baseClass.__init__(self, parent, 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, pos=position, size=size,
++                                   style=style)
+                 if stereo:
+                     # and make sure everyone knows that the stereo
+                     # visual wasn't set.
+@@ -666,7 +667,7 @@ def wxVTKRenderWindowInteractorConeExamp
+     """Like it says, just a simple example
+     """
+     # every wx app needs an app
+-    app = wx.PySimpleApp()
++    app = wx.App(False)
+ 
+     # create the top-level frame, sizer and wxVTKRWI
+     frame = wx.Frame(None, -1, "wxVTKRenderWindowInteractor", size=(400,400))

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/vtk6.git



More information about the debian-science-commits mailing list