- moved all the new_object related methods in their own class AppObjects.AppObject
This commit is contained in:
@@ -2239,7 +2239,7 @@ class FlatCAMExcEditor(QtCore.QObject):
|
||||
|
||||
# store the status of the editor so the Delete at object level will not work until the edit is finished
|
||||
self.editor_active = False
|
||||
log.debug("Initialization of the FlatCAM Excellon Editor is finished ...")
|
||||
log.debug("Initialization of the Excellon Editor is finished ...")
|
||||
|
||||
def pool_recreated(self, pool):
|
||||
self.shapes.pool = pool
|
||||
@@ -3336,7 +3336,7 @@ class FlatCAMExcEditor(QtCore.QObject):
|
||||
with self.app.proc_container.new(_("Creating Excellon.")):
|
||||
|
||||
try:
|
||||
edited_obj = self.app.new_object("excellon", outname, obj_init)
|
||||
edited_obj = self.app.app_obj.new_object("excellon", outname, obj_init)
|
||||
edited_obj.source_file = self.app.export_excellon(obj_name=edited_obj.options['name'],
|
||||
local_use=edited_obj,
|
||||
filename=None,
|
||||
|
||||
@@ -3552,7 +3552,7 @@ class FlatCAMGeoEditor(QtCore.QObject):
|
||||
|
||||
# store the status of the editor so the Delete at object level will not work until the edit is finished
|
||||
self.editor_active = False
|
||||
log.debug("Initialization of the FlatCAM Geometry Editor is finished ...")
|
||||
log.debug("Initialization of the Geometry Editor is finished ...")
|
||||
|
||||
def pool_recreated(self, pool):
|
||||
self.shapes.pool = pool
|
||||
|
||||
@@ -3110,7 +3110,7 @@ class FlatCAMGrbEditor(QtCore.QObject):
|
||||
self.complete = True
|
||||
|
||||
self.set_ui()
|
||||
log.debug("Initialization of the FlatCAM Gerber Editor is finished ...")
|
||||
log.debug("Initialization of the Gerber Editor is finished ...")
|
||||
|
||||
def pool_recreated(self, pool):
|
||||
self.shapes.pool = pool
|
||||
@@ -4346,7 +4346,7 @@ class FlatCAMGrbEditor(QtCore.QObject):
|
||||
|
||||
with self.app.proc_container.new(_("Creating Gerber.")):
|
||||
try:
|
||||
self.app.new_object("gerber", outname, obj_init)
|
||||
self.app.app_obj.new_object("gerber", outname, obj_init)
|
||||
except Exception as e:
|
||||
log.error("Error on Edited object creation: %s" % str(e))
|
||||
# make sure to clean the previous results
|
||||
|
||||
Reference in New Issue
Block a user