diff --git a/pysollib/tile/selectcardset.py b/pysollib/tile/selectcardset.py index 6b723001..6915969d 100644 --- a/pysollib/tile/selectcardset.py +++ b/pysollib/tile/selectcardset.py @@ -490,6 +490,8 @@ class SelectCardsetDialogWithPreview(MfxDialog): pos += 1 def selectSearchResult(self, event): + if self.list.size() <= 0: + return oldcur = self.list["cursor"] self.list["cursor"] = "watch" sel = self.list.get(self.list.curselection()) diff --git a/pysollib/tile/selectgame.py b/pysollib/tile/selectgame.py index 6433d37f..fb86206c 100644 --- a/pysollib/tile/selectgame.py +++ b/pysollib/tile/selectgame.py @@ -534,6 +534,8 @@ class SelectGameDialogWithPreview(SelectGameDialog): pos += 1 def selectSearchResult(self, event): + if self.list.size() <= 0: + return oldcur = self.list["cursor"] self.list["cursor"] = "watch" sel = self.list.get(self.list.curselection()) diff --git a/pysollib/tile/selecttile.py b/pysollib/tile/selecttile.py index d2646633..a9b2fd46 100644 --- a/pysollib/tile/selecttile.py +++ b/pysollib/tile/selecttile.py @@ -268,6 +268,8 @@ class SelectTileDialogWithPreview(MfxDialog): pos += 1 def selectSearchResult(self, event): + if self.list.size() <= 0: + return oldcur = self.list["cursor"] self.list["cursor"] = "watch" sel = self.list.get(self.list.curselection())