Commit df81a73d authored by Keegi's avatar Keegi

use enable/disable for pause button instead of hide/show to not interfere with custombuttons

parent 97a530d5
......@@ -131,7 +131,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
def endcb(self):
print "Print took "+str(int(time.time()-self.starttime)/60)+" minutes."
wx.CallAfter(self.pausebtn.Hide)
wx.CallAfter(self.pausebtn.Disable)
wx.CallAfter(self.printbtn.SetLabel,"Print")
......@@ -524,7 +524,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
self.topsizer.Fit(self)
# disable all printer controls until we connect to a printer
self.pausebtn.Hide()
self.pausebtn.Disable()
for i in self.printerControls:
i.Disable()
......@@ -934,7 +934,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
wx.CallAfter(self.printbtn.Enable)
wx.CallAfter(self.status.SetStatusText,"Loaded "+self.filename+", %d lines"%(len(self.f),))
wx.CallAfter(self.pausebtn.Hide)
wx.CallAfter(self.pausebtn.Disable)
wx.CallAfter(self.printbtn.SetLabel,"Print")
threading.Thread(target=self.loadviz).start()
......@@ -981,7 +981,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
self.status.SetStatusText("Loaded "+name+", %d lines"%(len(self.f),))
wx.CallAfter(self.printbtn.SetLabel, "Print")
wx.CallAfter(self.pausebtn.SetLabel, "Pause")
wx.CallAfter(self.pausebtn.Hide)
wx.CallAfter(self.pausebtn.Disable)
if self.p.online:
wx.CallAfter(self.printbtn.Enable)
threading.Thread(target=self.loadviz).start()
......@@ -1016,7 +1016,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
def on_startprint(self):
wx.CallAfter(self.pausebtn.SetLabel, "Pause")
wx.CallAfter(self.pausebtn.Show)
wx.CallAfter(self.pausebtn.Enable)
wx.CallAfter(self.printbtn.SetLabel, "Restart")
def endupload(self):
......@@ -1107,7 +1107,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
wx.CallAfter(self.connectbtn.Enable);
wx.CallAfter(self.printbtn.Disable);
wx.CallAfter(self.pausebtn.Hide);
wx.CallAfter(self.pausebtn.Disable);
for i in self.printerControls:
wx.CallAfter(i.Disable)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment