Commit e046dc80 authored by Guillaume Seguin's avatar Guillaume Seguin

Fix bug in loadfile() causing file not to be closed

parent 3ba713e5
...@@ -1499,7 +1499,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole): ...@@ -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)
......
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