Fixed delete selected shape error. (#858)
Co-authored-by: OZAN ALP (096023) <ozanalp@thy.com>
This commit is contained in:
parent
784144aa29
commit
1a3313842c
@ -1054,7 +1054,10 @@ class MainWindow(QMainWindow, WindowMixin):
|
||||
self.canvas.setEnabled(False)
|
||||
if file_path is None:
|
||||
file_path = self.settings.get(SETTING_FILENAME)
|
||||
|
||||
#Deselect shape when loading new file
|
||||
if self.canvas.selected_shape:
|
||||
self.canvas.selected_shape.selected = False
|
||||
self.canvas.selected_shape = None
|
||||
# Make sure that filePath is a regular python string, rather than QString
|
||||
file_path = ustr(file_path)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user