convert unicode filename to file system encoding

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41957 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn 2006-10-11 23:48:59 +00:00
parent 2dda386424
commit cc202d9b5e

View File

@ -373,6 +373,8 @@ class Frame(wx.Frame):
wx.SAVE | wx.OVERWRITE_PROMPT | wx.CHANGE_DIR)
if dlg.ShowModal() == wx.ID_OK:
path = dlg.GetPath()
if isinstance(path, unicode):
path = path.encode(sys.getfilesystemencoding())
dlg.Destroy()
else:
dlg.Destroy()