More fixes for ZIP_SUPPORT

- add extra commenting in FSNodeZIP concerning why another node is needed
- exclude zip files from the ROM launcher when ZIP_SUPPORT is disabled
This commit is contained in:
Stephen Anthony 2019-04-25 22:26:14 -02:30
parent dd09187fc0
commit 35ca8edbaf
3 changed files with 12 additions and 3 deletions

View File

@ -95,6 +95,11 @@ FilesystemNodeZIP::FilesystemNodeZIP(const string& p)
else
_isDirectory = true;
// Create a concrete FSNode to use
// This *must not* be a ZIP file; it must be a real FSNode object that
// has direct access to the actual filesystem (aka, a 'System' node)
// Behind the scenes, this node is actually a platform-specific object
// for whatever system we are running on
_realNode = FilesystemNodeFactory::create(_zipFile, FilesystemNodeFactory::Type::SYSTEM);
setFlags(_zipFile, _virtualPath, _realNode);

View File

@ -93,7 +93,10 @@ class FilesystemNodeZIP : public AbstractFSNode
NO_ROMS
};
// Since a ZIP file is itself an abstraction, it still needs access to
// an actual concrete filesystem node
AbstractFSNodePtr _realNode;
string _zipFile, _virtualPath;
string _name, _path, _shortPath;
zip_error _error;

View File

@ -137,7 +137,7 @@ Bankswitch::Description Bankswitch::BSList[int(Bankswitch::Type::NumSchemes)] =
{ "UA", "UA (8K UA Ltd.)" },
{ "WD", "WD (Experimental)" },
{ "X07", "X07 (64K AtariAge)" },
#ifdef CUSTOM_ARM
#if defined(CUSTOM_ARM)
{ "CUSTOM", "CUSTOM (ARM)" }
#endif
};
@ -149,11 +149,12 @@ Bankswitch::ExtensionMap Bankswitch::ourExtensions = {
{ "a26", Bankswitch::Type::_AUTO },
{ "bin", Bankswitch::Type::_AUTO },
{ "rom", Bankswitch::Type::_AUTO },
{ "gz", Bankswitch::Type::_AUTO },
#if defined(ZIP_SUPPORT)
{ "zip", Bankswitch::Type::_AUTO },
#endif
{ "cu", Bankswitch::Type::_AUTO },
// All bankswitch types (tose that UnoCart and HarmonyCart support have the same name)
// All bankswitch types (those that UnoCart and HarmonyCart support have the same name)
{ "084", Bankswitch::Type::_0840 },
{ "2N1", Bankswitch::Type::_2IN1 },
{ "4N1", Bankswitch::Type::_4IN1 },