More Python2 migrations, patch from KA.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@18838 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2003-01-21 00:04:37 +00:00
parent f86c833fe0
commit 76bad85642
11 changed files with 13 additions and 16 deletions

View File

@@ -62,7 +62,7 @@ class ParamBinaryOr(PPanel):
dlg = wxDialog(self, -1, 'Choices')
topSizer = wxBoxSizer(wxVERTICAL)
listBox = wxCheckListBox(dlg, -1, choices=self.values, size=(250,200))
value = map(string.strip, string.split(self.text.GetValue(), '|'))
value = map(string.strip, self.text.GetValue().split('|'))
if value == ['']: value = []
ignored = []
for i in value:

View File

@@ -672,7 +672,7 @@ class Frame(wxFrame):
except:
(etype, value, tb) =sys.exc_info()
tblist =traceback.extract_tb(tb)[1:]
msg =string.join(traceback.format_exception_only(etype, value)
msg =' '.join(traceback.format_exception_only(etype, value)
+traceback.format_list(tblist))
print msg

View File

@@ -10,7 +10,7 @@
#----------------------------------------------------------------------
import sys, os, glob, getopt, string
import sys, os, glob, getopt
from wxPython.wx import *
if wxPlatform == "__WXGTK__":
@@ -20,7 +20,7 @@ if wxPlatform == "__WXGTK__":
wxInitAllImageHandlers()
def convert(file, maskClr, outputDir, outputName, outType, outExt):
if string.lower(os.path.splitext(file)[1]) == ".ico":
if os.path.splitext(file)[1].lower() == ".ico":
icon = wxIcon(file, wxBITMAP_TYPE_ICO)
img = wxBitmapFromIcon(icon)
else:

View File

@@ -56,7 +56,7 @@ Options:
#
import sys, os, glob, getopt, tempfile, string
import sys, os, glob, getopt, tempfile
import cPickle, cStringIO, zlib
import img2img
from wxPython import wx