- refactored the is_legacy object to use_3d_engine

- made sure that there is no longer a double action when toggling the object visibility ('plot' attribute)
This commit is contained in:
Marius Stanciu
2021-10-31 14:05:00 +02:00
committed by Marius
parent 25bca44996
commit bb089eb657
34 changed files with 321 additions and 366 deletions

View File

@@ -238,7 +238,7 @@ class ToolCalibration(AppTool):
self.mr = self.canvas.graph_event_connect('mouse_release', self.on_mouse_click_release)
if self.app.is_legacy is False:
if self.app.use_3d_engine:
self.canvas.graph_event_disconnect('mouse_release', self.app.on_mouse_click_release_over_plot)
else:
self.canvas.graph_event_disconnect(self.app.mr)
@@ -250,7 +250,7 @@ class ToolCalibration(AppTool):
self.app.inform.emit(_("Get First calibration point. Bottom Left..."))
def on_mouse_click_release(self, event):
if self.app.is_legacy is False:
if self.app.use_3d_engine:
event_pos = event.pos
right_button = 2
self.app.event_is_dragging = self.app.event_is_dragging
@@ -748,7 +748,7 @@ class ToolCalibration(AppTool):
self.app.mr = self.canvas.graph_event_connect('mouse_release', self.app.on_mouse_click_release_over_plot)
if self.app.is_legacy is False:
if self.app.use_3d_engine:
self.canvas.graph_event_disconnect('mouse_release', self.on_mouse_click_release)
else:
self.canvas.graph_event_disconnect(self.mr)