From b5c182a19aad6e44d18762c4548aeea0d75e1bce Mon Sep 17 00:00:00 2001 From: Kliment Date: Tue, 23 Aug 2011 14:33:28 +0200 Subject: [PATCH] Push gui updates to a separate thread --- pronterface.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pronterface.py b/pronterface.py index a1cebda..be9f435 100755 --- a/pronterface.py +++ b/pronterface.py @@ -163,10 +163,10 @@ class PronterWindow(wx.Frame,pronsole.pronsole): if(layer!=self.curlayer): self.curlayer=layer self.gviz.hilight=[] - wx.CallAfter(self.gviz.setlayer,layer) + threading.Thread(target=wx.CallAfter,args=(self.gviz.setlayer,layer)).start() except: pass - self.gviz.addgcode(line,hilight=1) + threading.Thread(target=self.gviz.addgcode,args=(line,1)).start() #self.gwindow.p.addgcode(line,hilight=1) def do_extrude(self,l=""):