def OnImportWretch(self, e) : dialog = wx.FileDialog(self) result = dialog.ShowModal() dialog.Destroy() if result != wx.ID_OK : return file = dialog.GetFilename() dir = dialog.GetDirectory() filename = os.path.join(dir, file) wi = WretchImporter(filename) blogdata = wi.parse() self.setBlogData(blogdata)
def OnImportWretch(self, e): dialog = wx.FileDialog(self) result = dialog.ShowModal() dialog.Destroy() if result != wx.ID_OK: return file = dialog.GetFilename() dir = dialog.GetDirectory() filename = os.path.join(dir, file) wi = WretchImporter(filename) blogdata = wi.parse() self.setBlogData(blogdata)