Activity shown for CNC Job generation via context manager.
This commit is contained in:
@@ -1014,8 +1014,12 @@ class FlatCAMGeometry(FlatCAMObj, Geometry):
|
||||
self.app.inform.emit("Done.")
|
||||
|
||||
def job_thread(app_obj):
|
||||
name = self.options["name"] + "_paint"
|
||||
app_obj.new_object("geometry", name, gen_paintarea)
|
||||
try:
|
||||
name = self.options["name"] + "_paint"
|
||||
app_obj.new_object("geometry", name, gen_paintarea)
|
||||
except Exception as e:
|
||||
proc.done()
|
||||
raise e
|
||||
proc.done()
|
||||
|
||||
self.app.inform.emit("Polygon Paint started ...")
|
||||
@@ -1058,9 +1062,10 @@ class FlatCAMGeometry(FlatCAMObj, Geometry):
|
||||
|
||||
# To be run in separate thread
|
||||
def job_thread(app_obj):
|
||||
app_obj.new_object("cncjob", outname, job_init)
|
||||
app_obj.inform.emit("CNCjob created: %s" % outname)
|
||||
app_obj.progress.emit(100)
|
||||
with self.app.proc_container.new("Generating CNC Job."):
|
||||
app_obj.new_object("cncjob", outname, job_init)
|
||||
app_obj.inform.emit("CNCjob created: %s" % outname)
|
||||
app_obj.progress.emit(100)
|
||||
|
||||
# Send to worker
|
||||
self.app.worker_task.emit({'fcn': job_thread, 'params': [self.app]})
|
||||
|
||||
@@ -30,4 +30,6 @@ class Worker(QtCore.QObject):
|
||||
|
||||
if 'worker_name' not in task and self.name is None:
|
||||
task['fcn'](*task['params'])
|
||||
return
|
||||
return
|
||||
|
||||
FlatCAMApp.App.log.debug("Task ignored.")
|
||||
@@ -331,6 +331,7 @@ class Geometry(object):
|
||||
:return:
|
||||
"""
|
||||
|
||||
log.debug("camlib.clear_polygon()")
|
||||
assert type(polygon) == Polygon
|
||||
|
||||
## The toolpaths
|
||||
@@ -401,6 +402,8 @@ class Geometry(object):
|
||||
:return: List of toolpaths covering polygon.
|
||||
"""
|
||||
|
||||
log.debug("camlib.clear_polygon2()")
|
||||
|
||||
# Current buffer radius
|
||||
radius = tooldia / 2 * (1 - overlap)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user