mirror of
https://github.com/libretro/scummvm.git
synced 2025-04-02 23:01:42 +00:00
BACKENDS: Improve AbstractFSNode::createDirectory() stubs
This commit is contained in:
parent
66ef50cfeb
commit
db445bfc87
@ -444,8 +444,8 @@ Common::WriteStream *AmigaOSFilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool AmigaOSFilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("AmigaOSFilesystemNode::createDirectory(): Not supported");
|
||||
return _bIsValid && _bIsDirectory;
|
||||
}
|
||||
|
||||
#endif //defined(__amigaos4__)
|
||||
|
@ -101,8 +101,7 @@ Common::WriteStream *ChRootFilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool ChRootFilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
return _realNode->createDirectory();
|
||||
}
|
||||
|
||||
Common::String ChRootFilesystemNode::addPathComponent(const Common::String &path, const Common::String &component) {
|
||||
|
@ -212,8 +212,7 @@ Common::WriteStream *DSFileSystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool DSFileSystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
return _isValid && _isDirectory;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
@ -399,8 +398,8 @@ Common::WriteStream *GBAMPFileSystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool GBAMPFileSystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("GBAMPFileSystemNode::createDirectory(): Not supported");
|
||||
return _isValid && _isDirectory;
|
||||
}
|
||||
|
||||
|
||||
|
@ -161,8 +161,7 @@ Common::WriteStream *N64FilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool N64FilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
return _isValid && _isDirectory;
|
||||
}
|
||||
|
||||
#endif //#ifdef __N64__
|
||||
|
@ -444,8 +444,8 @@ Common::WriteStream *Ps2FilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool Ps2FilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("Ps2FilesystemNode::createDirectory(): Not supported");
|
||||
return _isHere && _isDirectory;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -240,8 +240,8 @@ Common::WriteStream *PSPFilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool PSPFilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("PSPFilesystemNode::createDirectory(): Not supported");
|
||||
return _isValid && _isDirectory;
|
||||
}
|
||||
|
||||
#endif //#ifdef __PSP__
|
||||
|
@ -233,8 +233,8 @@ Common::WriteStream *SymbianFilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool SymbianFilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("SymbianFilesystemNode::createDirectory(): Not supported");
|
||||
return _isValid && _isDirectory;
|
||||
}
|
||||
|
||||
#endif //#if defined(__SYMBIAN32__)
|
||||
|
@ -214,8 +214,8 @@ Common::WriteStream *WiiFilesystemNode::createWriteStream() {
|
||||
}
|
||||
|
||||
bool WiiFilesystemNode::createDirectory() {
|
||||
error("Not supported");
|
||||
return false;
|
||||
warning("WiiFilesystemNode::createDirectory(): Not supported");
|
||||
return _exists && _isDirectory;
|
||||
}
|
||||
|
||||
#endif //#if defined(__WII__)
|
||||
|
@ -71,6 +71,7 @@ public:
|
||||
virtual AbstractFSNode *getChild(const Common::String &n) const;
|
||||
virtual bool getChildren(AbstractFSList &list, ListMode mode, bool hidden) const;
|
||||
virtual Common::SeekableReadStream *createReadStream() { return 0; }
|
||||
virtual bool createDirectory() { return true; }
|
||||
};
|
||||
|
||||
/* A file/directory which does not exist */
|
||||
|
@ -439,3 +439,8 @@ Common::WriteStream *TizenFilesystemNode::createWriteStream() {
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
bool TizenFilesystemNode::createDirectory() {
|
||||
warning("TizenFilesystemNode::createDirectory(): Not supported");
|
||||
return _isValid && isDirectory();
|
||||
}
|
||||
|
@ -83,6 +83,7 @@ public:
|
||||
|
||||
Common::SeekableReadStream *createReadStream();
|
||||
Common::WriteStream *createWriteStream();
|
||||
bool createDirectory();
|
||||
|
||||
protected:
|
||||
TizenFilesystemNode(const Common::String &root, const Common::String &p);
|
||||
|
Loading…
x
Reference in New Issue
Block a user