mirror of
https://github.com/shlomif/PySolFC.git
synced 2025-04-05 00:02:29 -04:00
consolidate diffs
This commit is contained in:
parent
6b228291cc
commit
4d61d73f3a
2 changed files with 5 additions and 8 deletions
|
@ -230,8 +230,6 @@ class SelectGameData(SelectDialogTreeData):
|
||||||
lambda gi: gi.si.redeals == 3),
|
lambda gi: gi.si.redeals == 3),
|
||||||
SelectGameNode(None, _("Unlimited redeals"),
|
SelectGameNode(None, _("Unlimited redeals"),
|
||||||
lambda gi: gi.si.redeals == -1),
|
lambda gi: gi.si.redeals == -1),
|
||||||
# SelectGameNode(None, "Variable redeals",
|
|
||||||
# lambda gi: gi.si.redeals == -2),
|
|
||||||
SelectGameNode(
|
SelectGameNode(
|
||||||
None, _("Other number of redeals"),
|
None, _("Other number of redeals"),
|
||||||
lambda gi: gi.si.redeals not in (-1, 0, 1, 2, 3)),
|
lambda gi: gi.si.redeals not in (-1, 0, 1, 2, 3)),
|
||||||
|
|
|
@ -165,16 +165,16 @@ class SelectGameData(SelectDialogTreeData):
|
||||||
list(app.gdb.getGamesTuplesSortedByAlternateName()))
|
list(app.gdb.getGamesTuplesSortedByAlternateName()))
|
||||||
#
|
#
|
||||||
self.rootnodes = [_f for _f in (
|
self.rootnodes = [_f for _f in (
|
||||||
SelectGameNode(None, _("All Games"), None),
|
SelectGameNode(None, _("All Games"), None, expanded=0),
|
||||||
SelectGameNode(None, _("Alternate Names"), ul_alternate_names),
|
SelectGameNode(None, _("Alternate Names"), ul_alternate_names),
|
||||||
SelectGameNode(None, _("Popular Games"),
|
SelectGameNode(None, _("Popular Games"),
|
||||||
lambda gi: gi.si.game_flags & GI.GT_POPULAR),
|
lambda gi: gi.si.game_flags & GI.GT_POPULAR),
|
||||||
|
s_by_type,
|
||||||
s_mahjongg,
|
s_mahjongg,
|
||||||
s_oriental,
|
s_oriental,
|
||||||
s_special,
|
s_special,
|
||||||
SelectGameNode(None, _("Custom Games"),
|
SelectGameNode(None, _("Custom Games"),
|
||||||
lambda gi: gi.si.game_type == GI.GT_CUSTOM),
|
lambda gi: gi.si.game_type == GI.GT_CUSTOM),
|
||||||
s_by_type,
|
|
||||||
SelectGameNode(None, _('by Skill Level'), (
|
SelectGameNode(None, _('by Skill Level'), (
|
||||||
SelectGameNode(None, _('Luck only'),
|
SelectGameNode(None, _('Luck only'),
|
||||||
lambda gi: gi.skill_level == GI.SL_LUCK),
|
lambda gi: gi.skill_level == GI.SL_LUCK),
|
||||||
|
@ -230,8 +230,6 @@ class SelectGameData(SelectDialogTreeData):
|
||||||
lambda gi: gi.si.redeals == 3),
|
lambda gi: gi.si.redeals == 3),
|
||||||
SelectGameNode(None, _("Unlimited redeals"),
|
SelectGameNode(None, _("Unlimited redeals"),
|
||||||
lambda gi: gi.si.redeals == -1),
|
lambda gi: gi.si.redeals == -1),
|
||||||
SelectGameNode(None, "Variable redeals",
|
|
||||||
lambda gi: gi.si.redeals == -2),
|
|
||||||
SelectGameNode(
|
SelectGameNode(
|
||||||
None, _("Other number of redeals"),
|
None, _("Other number of redeals"),
|
||||||
lambda gi: gi.si.redeals not in (-1, 0, 1, 2, 3)),
|
lambda gi: gi.si.redeals not in (-1, 0, 1, 2, 3)),
|
||||||
|
@ -435,7 +433,8 @@ class SelectGameDialogWithPreview(SelectGameDialog):
|
||||||
|
|
||||||
def initKw(self, kw):
|
def initKw(self, kw):
|
||||||
kw = KwStruct(kw,
|
kw = KwStruct(kw,
|
||||||
strings=(_("&Select"), _("&Rules"), _("&Cancel"),),
|
strings=((_("&Rules"), 10), 'sep',
|
||||||
|
_("&Select"), _("&Cancel"),),
|
||||||
default=0,
|
default=0,
|
||||||
)
|
)
|
||||||
return SelectGameDialog.initKw(self, kw)
|
return SelectGameDialog.initKw(self, kw)
|
||||||
|
@ -544,7 +543,7 @@ class SelectGameDialogWithPreview(SelectGameDialog):
|
||||||
#
|
#
|
||||||
self.updateInfo(gameid)
|
self.updateInfo(gameid)
|
||||||
#
|
#
|
||||||
rules_button = self.buttons[1]
|
rules_button = self.buttons[0]
|
||||||
if self.app.getGameRulesFilename(gameid):
|
if self.app.getGameRulesFilename(gameid):
|
||||||
rules_button.config(state="normal")
|
rules_button.config(state="normal")
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Reference in a new issue