- Sub Tool: fixed an issue due of an incorrect parameter for a QTimer start

This commit is contained in:
Marius Stanciu
2023-06-05 19:07:01 +03:00
parent 5708791acc
commit d491278ab2
2 changed files with 6 additions and 3 deletions

View File

@@ -13,6 +13,7 @@ CHANGELOG for FlatCAM Evo beta
- Paint Plugin: fixed issues caused by the latest changes in the Shapely module - Paint Plugin: fixed issues caused by the latest changes in the Shapely module
- NCC Plugin: some changes in the method used by the Tcl Command - NCC Plugin: some changes in the method used by the Tcl Command
- in Preferences, added a control in the General -> GUI Settings to control the font size for the entire application; require an app restart - in Preferences, added a control in the General -> GUI Settings to control the font size for the entire application; require an app restart
- Sub Tool: fixed an issue due of an incorrect parameter for a QTimer start
31.05.2023 31.05.2023

View File

@@ -87,6 +87,9 @@ class ToolSub(AppTool):
self.pool = self.app.pool self.pool = self.app.pool
self.results = [] self.results = []
# start the QTimer to check for promises with 0.5 seconds period check
self.check_interval = 500
def install(self, icon=None, separator=None, **kwargs): def install(self, icon=None, separator=None, **kwargs):
AppTool.install(self, icon, separator, shortcut='Alt+W', **kwargs) AppTool.install(self, icon, separator, shortcut='Alt+W', **kwargs)
@@ -559,8 +562,7 @@ class ToolSub(AppTool):
self.sub_union = unary_union(self.sub_geo_obj.solid_geometry) self.sub_union = unary_union(self.sub_geo_obj.solid_geometry)
# start the QTimer to check for promises with 0.5 seconds period check self.periodic_check(self.check_interval, reset=True)
self.periodic_check(500, reset=True)
if self.target_geo_obj.multigeo: if self.target_geo_obj.multigeo:
for tool in self.target_geo_obj.tools: for tool in self.target_geo_obj.tools:
@@ -718,7 +720,7 @@ class ToolSub(AppTool):
pass pass
self.check_thread.timeout.connect(self.periodic_check_handler) self.check_thread.timeout.connect(self.periodic_check_handler)
self.check_thread.start(QtCore.QThread.Priority.HighPriority) # noqa self.check_thread.start()
def periodic_check_handler(self): def periodic_check_handler(self):
""" """