From be10cff3c51ba8891e490fed0bf99359f13c7d15 Mon Sep 17 00:00:00 2001 From: Guillaume Seguin Date: Sat, 18 May 2013 23:01:13 +0200 Subject: [PATCH] Cleanup and fix recvcb --- pronterface.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pronterface.py b/pronterface.py index 707abb4..ebb49a9 100755 --- a/pronterface.py +++ b/pronterface.py @@ -1145,13 +1145,10 @@ class PronterWindow(MainWindow, pronsole.pronsole): wx.CallAfter(self.tempdisp.SetLabel, self.tempreport.strip().replace("ok ", "")) self.update_tempdisplay() tstring = l.rstrip() - #print tstring - if (tstring!="ok") and (tstring!="wait") and ("ok T:" not in tstring) and (not self.p.loud): - # print "*"+tstring+"*" - # print "[" + time.strftime('%H:%M:%S',time.localtime(time.time())) + "] " + tstring + if self.p.loud or (tstring not in ["ok", "wait"] and "ok T:" not in tstring and "ok C:" not in tstring): wx.CallAfter(self.addtexttolog, tstring + "\n"); - for i in self.recvlisteners: - i(l) + for listener in self.recvlisteners: + listener(l) def listfiles(self, line): if "Begin file list" in line: