fix select round after closing
This commit is contained in:
parent
d869017646
commit
42eb625ef6
2 changed files with 7 additions and 1 deletions
|
|
@ -141,7 +141,9 @@ class RoundController:
|
||||||
return
|
return
|
||||||
self.app.is_dirty = True
|
self.app.is_dirty = True
|
||||||
self.app.navigation.refresh(RefreshScope.CURRENT_SELECTION_DETAILS)
|
self.app.navigation.refresh(RefreshScope.CURRENT_SELECTION_DETAILS)
|
||||||
self.app.navigation.refresh(RefreshScope.WARS_TREE)
|
self.app.navigation.refresh_and_select(
|
||||||
|
RefreshScope.WARS_TREE, item_type=ItemType.ROUND, item_id=round_id
|
||||||
|
)
|
||||||
|
|
||||||
# Choice methods
|
# Choice methods
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -238,6 +238,10 @@ class View(QtWidgets.QMainWindow, Ui_MainWindow):
|
||||||
|
|
||||||
def display_wars_tree(self, wars: List[WarDTO]) -> None:
|
def display_wars_tree(self, wars: List[WarDTO]) -> None:
|
||||||
tree = self.warsTree
|
tree = self.warsTree
|
||||||
|
try:
|
||||||
|
tree.currentItemChanged.disconnect()
|
||||||
|
except TypeError:
|
||||||
|
pass
|
||||||
tree.clear()
|
tree.clear()
|
||||||
tree.setColumnCount(1)
|
tree.setColumnCount(1)
|
||||||
tree.setHeaderLabels(["Wars"])
|
tree.setHeaderLabels(["Wars"])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue