Skip to content

Commit

Permalink
在英雄 Build 界面为空时锁住切换按钮
Browse files Browse the repository at this point in the history
  • Loading branch information
Zzaphkiel committed Jul 26, 2024
1 parent 0147857 commit 5d6e69d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/view/opgg_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,10 @@ def __onStackedWidgetCurrentChanged(self):
elif widget in [self.buildInterface, self.errorInterface]:
self.searchButton.setEnabled(False)

if widget is self.tierInterface \
and not self.buildInterface.getCurrentChampionId():
self.toggleButton.setEnabled(False)

if (index := self.stackedWidget.currentIndex()) in [0, 1]:
self.toggleButton.setCurrentIcon(index)

Expand Down

0 comments on commit 5d6e69d

Please sign in to comment.