mirror of
https://github.com/shlomif/PySolFC.git
synced 2025-04-05 00:02:29 -04:00
Added search option for compatible cardsets.
This commit is contained in:
parent
b64ef10374
commit
7ef3b1d359
8 changed files with 49 additions and 6 deletions
|
@ -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 <Holger.Schaekel@web.de>\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"
|
||||
|
|
|
@ -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 <neelix570@gmail.com>\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"
|
||||
|
|
|
@ -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 <giuliano.colla@gmail.com>\n"
|
||||
"Language-Team: Italiano <it@li.org>\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"
|
||||
|
|
|
@ -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 <artusek@wp.pl>\n"
|
||||
"Language-Team: Polish <pl@li.org>\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"
|
||||
|
|
|
@ -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 <mtknack555@gmail.com>\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"
|
||||
|
|
|
@ -3989,6 +3989,9 @@ msgstr ""
|
|||
msgid "Year:"
|
||||
msgstr ""
|
||||
|
||||
msgid "Compatible with current game"
|
||||
msgstr ""
|
||||
|
||||
#: pysollib/tile/selectcardset.py:488
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
|
|
@ -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 <skomoroh@gmail.com>\n"
|
||||
"Language-Team: Russian <ru@li.org>\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"
|
||||
|
|
|
@ -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)
|
||||
|
|
Loading…
Add table
Reference in a new issue