mirror of
https://github.com/libretro/stella2023.git
synced 2024-12-03 15:11:03 +00:00
Fix overzealous TV detection in ROM filenames. Fixes #747.
This commit is contained in:
parent
e14da1344a
commit
5c7ae3a147
@ -38,6 +38,9 @@
|
||||
|
||||
* Fixed autofire bug for trackball controllers.
|
||||
|
||||
* Fixed bug in TV autodetection in filenames; a filename containing
|
||||
'PAL' would sometimes misdetect as a PAL ROM.
|
||||
|
||||
* Fixed Stelladaptor/2600'daptor devices sometimes not being assigned
|
||||
correct default mappings.
|
||||
|
||||
|
@ -316,13 +316,13 @@ string Console::formatFromFilename() const
|
||||
{ R"([ _\-(\[<]+NTSC[ _-]?50)", "NTSC50" },
|
||||
{ R"([ _\-(\[<]+PAL[ _-]?60)", "PAL60" },
|
||||
{ R"([ _\-(\[<]+SECAM[ _-]?60)", "SECAM60" },
|
||||
{ R"([ _\-(\[<]+NTSC[ _\-)\]>]?)", "NTSC" },
|
||||
{ R"([ _\-(\[<]+PAL[ _\-)\]>]?)", "PAL" },
|
||||
{ R"([ _\-(\[<]+SECAM[ _\-)\]>]?)", "SECAM" }
|
||||
{ R"([ _\-(\[<]+NTSC[ _\-)\]>.])", "NTSC" },
|
||||
{ R"([ _\-(\[<]+PAL[ _\-)\]>.])", "PAL" },
|
||||
{ R"([ _\-(\[<]+SECAM[ _\-)\]>.])", "SECAM" }
|
||||
}};
|
||||
|
||||
// Get filename *without* extension, and search using regex's above
|
||||
const string& filename = myOSystem.romFile().getNameWithExt("");
|
||||
// Get filename, and search using regex's above
|
||||
const string& filename = myOSystem.romFile().getName();
|
||||
for(size_t i = 0; i < Pattern.size(); ++i)
|
||||
{
|
||||
try
|
||||
|
Loading…
Reference in New Issue
Block a user