- upgraded all the plugins such that at each launch the Plugin UI is reinitialized reducing the chances to get errors like "wrapped up C++ object deleted" with the side effect that the performance might be slightly reduced

This commit is contained in:
Marius Stanciu
2021-03-28 15:21:17 +03:00
committed by Marius
parent d0327ff37d
commit 4c92083c01
39 changed files with 1239 additions and 957 deletions

View File

@@ -3306,8 +3306,32 @@ class FCDetachableTab2(FCDetachableTab):
except TypeError:
pass
self.__auto_remove_closed_tab = True
self.tabBar.onCloseTabSignal.connect(self.on_closetab_middle_button)
@property
def auto_remove_closed_tab(self):
"""
A property that allow the user to handle the tab removal on he's own
:return:
:rtype:
"""
return self.__auto_remove_closed_tab
@auto_remove_closed_tab.setter
def auto_remove_closed_tab(self, val):
"""
A property that allow the user to handle the tab removal on he's own
:param val: If to auto remove the tab
:type val: bool
:return:
:rtype:
"""
self.__auto_remove_closed_tab = val
def on_closetab_middle_button(self, current_index):
"""
@@ -3330,7 +3354,8 @@ class FCDetachableTab2(FCDetachableTab):
tab_name = self.widget(currentIndex).objectName()
self.tab_closed_signal.emit(tab_name, currentIndex)
self.removeTab(currentIndex)
if self.__auto_remove_closed_tab:
self.removeTab(currentIndex)
class VerticalScrollArea(QtWidgets.QScrollArea):