Fix bug in loadfile() causing file not to be closed
parent
3ba713e5d0
commit
e046dc8016
|
@ -1499,7 +1499,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
|
||||||
self.filename=self.filename.replace(".stl","_export.gcode").replace(".STL","_export.gcode").replace(".obj","_export.gcode").replace(".OBJ","_export.gcode")
|
self.filename=self.filename.replace(".stl","_export.gcode").replace(".STL","_export.gcode").replace(".obj","_export.gcode").replace(".OBJ","_export.gcode")
|
||||||
of=open(self.filename)
|
of=open(self.filename)
|
||||||
self.f=[i.replace("\n","").replace("\r","") for i in of]
|
self.f=[i.replace("\n","").replace("\r","") for i in of]
|
||||||
of.close
|
of.close()
|
||||||
if self.p.online:
|
if self.p.online:
|
||||||
wx.CallAfter(self.printbtn.Enable)
|
wx.CallAfter(self.printbtn.Enable)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue