X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=wx%2Flib%2Fapp.py;h=f524cdd34c25fbb5b6e2d078151dd86357b76585;hp=072b79d388b475ae802039267d8e07ef9adbc752;hb=a9c3c32bc9ba2604d0bab6a7a2df530396b6d965;hpb=e37b83503aa09d36d7e32327d9bd1f6c42708890 diff --git a/wx/lib/app.py b/wx/lib/app.py index 072b79d..f524cdd 100644 --- a/wx/lib/app.py +++ b/wx/lib/app.py @@ -143,6 +143,17 @@ class Pdf2Swf: self.view.statusbar.btn_cancel.Bind(wx.EVT_BUTTON, self.OnThumbnailCancel) + # Don't know where the problem is (python/xpython or wxwidgets/wxpython) + # but I found that this hack was necessary to avoid the app enter in a + # idle state. We must, for example, move the mouse inside the app + # for threads continue their job. + # There is no need for this when freezing with other utils, like + # py2exe, pyinstaller, cxfreeze + if "wxMSW" in wx.PlatformInfo: + self.timer = wx.Timer(self.view) + self.view.Bind(wx.EVT_TIMER, lambda evt: None) + self.timer.Start(50) + def OnFilesDroped(self, evt): dlg = wx.MessageDialog(self.view, u"You must drop only one file.",