mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-12-02 22:38:54 -06:00
fix: a recorded region is the same choice
This commit is contained in:
1 parent
9feee29318
commit
e7b9acb425
6 files changed
+45
-18
No files matched your search
+13
-4
@@ -24888,11 +24888,20 @@ def _tui_given(state: TuiState) -> list[tuple[str, str | None]]:
|
||||
|
||||
def _record_key(options: Iterable[tuple[str, str | None]]) -> list:
|
||||
"""A choice in a form two spellings of it share: one name per --system
|
||||
and --core, in any order."""
|
||||
and --core, in any order, and the regions as one list in their order of
|
||||
priority, each spelled as the manifests spell it."""
|
||||
pairs = record_options(record_argv(options))
|
||||
return sorted((flag, name.strip()) for flag, value in pairs
|
||||
for name in ((value or "").split(",") if flag in ("--system", "--core")
|
||||
else [value or ""]) if name.strip() or value is None)
|
||||
key = sorted((flag, name.strip()) for flag, value in pairs if flag != "--region"
|
||||
for name in ((value or "").split(",") if flag in ("--system", "--core")
|
||||
else [value or ""]) if name.strip() or value is None)
|
||||
regions = [str(value) for flag, value in pairs if flag == "--region"]
|
||||
if regions:
|
||||
try:
|
||||
spelled = ",".join(resolve_regions(regions))
|
||||
except ValueError:
|
||||
spelled = ",".join(regions)
|
||||
key.append(("--region", spelled))
|
||||
return key
|
||||
|
||||
|
||||
def tui_record_kept(state: TuiState) -> bool:
|
||||
|
||||
Reference in new issue
Block a user