diff --git a/po/de_pysol.po b/po/de_pysol.po index a549b834..e2232c4c 100644 --- a/po/de_pysol.po +++ b/po/de_pysol.po @@ -3,7 +3,7 @@ msgstr "" "Project-Id-Version: PySol 0.0.1\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:22-0400\n" +"PO-Revision-Date: 2024-05-31 20:27-0400\n" "Last-Translator: H. Schaekel \n" "Language-Team: German\n" "Language: de\n" @@ -4133,6 +4133,9 @@ msgstr "Nationalität:" msgid "Year:" msgstr "Jahr:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 msgid "Settings" msgstr "Enstellungen" diff --git a/po/fr_pysol.po b/po/fr_pysol.po index 9f07291c..3c8cd7c9 100644 --- a/po/fr_pysol.po +++ b/po/fr_pysol.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: 1.02\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:23-0400\n" +"PO-Revision-Date: 2024-05-31 20:26-0400\n" "Last-Translator: Eric Rausch \n" "Language-Team: French\n" "Language: fr\n" @@ -4184,6 +4184,9 @@ msgstr "Origine:" msgid "Year:" msgstr "Année:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 msgid "Settings" msgstr "Réglages" diff --git a/po/it_pysol.po b/po/it_pysol.po index 1b8548c2..dc12bc7f 100644 --- a/po/it_pysol.po +++ b/po/it_pysol.po @@ -12,7 +12,7 @@ msgstr "" "Project-Id-Version: it_pysol\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:23-0400\n" +"PO-Revision-Date: 2024-05-31 20:26-0400\n" "Last-Translator: Giuliano Colla \n" "Language-Team: Italiano \n" "Language: it\n" @@ -4247,6 +4247,9 @@ msgstr "Nazionalità:" msgid "Year:" msgstr "Anno:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 #, fuzzy msgid "Settings" diff --git a/po/pl_pysol.po b/po/pl_pysol.po index 25d05c2d..58737ebd 100644 --- a/po/pl_pysol.po +++ b/po/pl_pysol.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PySolFC\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:24-0400\n" +"PO-Revision-Date: 2024-05-31 20:26-0400\n" "Last-Translator: Jerzy Trzeciak \n" "Language-Team: Polish \n" "Language: pl\n" @@ -4201,6 +4201,9 @@ msgstr "Narodowość:" msgid "Year:" msgstr "Rok:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 msgid "Settings" msgstr "Ustawienie" diff --git a/po/pt_BR_pysol.po b/po/pt_BR_pysol.po index 2e04cf77..6b7b4c48 100644 --- a/po/pt_BR_pysol.po +++ b/po/pt_BR_pysol.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:24-0400\n" +"PO-Revision-Date: 2024-05-31 20:25-0400\n" "Last-Translator: Matheus Knack \n" "Language-Team: \n" "Language: pt_BR\n" @@ -4207,6 +4207,9 @@ msgstr "Nacionalidade:" msgid "Year:" msgstr "Ano:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 msgid "Settings" msgstr "Configurações" diff --git a/po/pysol.pot b/po/pysol.pot index cf3f19c1..63e262f5 100644 --- a/po/pysol.pot +++ b/po/pysol.pot @@ -3989,6 +3989,9 @@ msgstr "" msgid "Year:" msgstr "" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 msgid "Settings" msgstr "" diff --git a/po/ru_pysol.po b/po/ru_pysol.po index c6659c0b..338f7056 100644 --- a/po/ru_pysol.po +++ b/po/ru_pysol.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2021-12-10 10:19-0500\n" -"PO-Revision-Date: 2024-03-21 18:26-0400\n" +"PO-Revision-Date: 2024-05-31 20:25-0400\n" "Last-Translator: Skomoroh \n" "Language-Team: Russian \n" "Language: ru\n" @@ -4256,6 +4256,9 @@ msgstr "Национальность:" msgid "Year:" msgstr "Год:" +msgid "Compatible with current game" +msgstr "" + #: pysollib/tile/selectcardset.py:488 #, fuzzy msgid "Settings" diff --git a/pysollib/tile/selectcardset.py b/pysollib/tile/selectcardset.py index ebf1f4cd..993ba89d 100644 --- a/pysollib/tile/selectcardset.py +++ b/pysollib/tile/selectcardset.py @@ -525,6 +525,17 @@ class SelectCardsetDialogWithPreview(MfxDialog): not in cardset.si.nationalities): continue + if self.criteria.compatible: + if self.app.game is not None: + gi = self.app.getGameInfo(self.app.game.id) + else: + gi = self.app.getGameInfo(self.app.nextgame.id) + cs, cs_update_flag, t = \ + self.app.getCompatibleCardset(gi, cardset, trychange=False) + + if cs is None: + continue + if self.app.checkSearchString(self.criteria.name, cardset.name): results.append(cardset.name) @@ -549,6 +560,7 @@ class SelectCardsetDialogWithPreview(MfxDialog): self.criteria.style = d.style.get() self.criteria.date = d.date.get() self.criteria.nationality = d.nationality.get() + self.criteria.compatible = d.compatible.get() self.performSearch() @@ -730,6 +742,7 @@ class SearchCriteria: self.style = "" self.date = "" self.nationality = "" + self.compatible = False self.sizeOptions = {"": -1, "Tiny cardsets": CSI.SIZE_TINY, @@ -794,6 +807,8 @@ class SelectCardsetAdvancedSearch(MfxDialog): self.date.set(criteria.date) self.nationality = tkinter.StringVar() self.nationality.set(criteria.nationality) + self.compatible = tkinter.BooleanVar() + self.compatible.set(criteria.compatible) # row = 0 @@ -885,6 +900,13 @@ class SelectCardsetAdvancedSearch(MfxDialog): padx=1, pady=1) row += 1 + compatCheck = tkinter.Checkbutton( + top_frame, variable=self.compatible, + text=_("Compatible with current game"), anchor="w" + ) + compatCheck.grid(row=row, column=0, columnspan=2, sticky='ew', + padx=1, pady=1) + focus = self.createButtons(bottom_frame, kw) # focus = text_w self.mainloop(focus, kw.timeout)