aboutsummaryrefslogtreecommitdiff
path: root/backends/platform
diff options
context:
space:
mode:
authorMax Horn2009-01-23 03:41:36 +0000
committerMax Horn2009-01-23 03:41:36 +0000
commit8f16458e9ba830fe80f177cc2fc3bcf2af84ebef (patch)
tree36236e2af1589bca848ce28d7606ef6e789431e8 /backends/platform
parente4b013f616818f6da4cf7a1896f31d1429ef8f04 (diff)
downloadscummvm-rg350-8f16458e9ba830fe80f177cc2fc3bcf2af84ebef.tar.gz
scummvm-rg350-8f16458e9ba830fe80f177cc2fc3bcf2af84ebef.tar.bz2
scummvm-rg350-8f16458e9ba830fe80f177cc2fc3bcf2af84ebef.zip
Renamed FSNode::openForReading / openForWriting to createReadStream / createWriteStream, again to make ownership of the returned stream clear
svn-id: r36014
Diffstat (limited to 'backends/platform')
-rw-r--r--backends/platform/PalmOS/Src/be_base.cpp4
-rw-r--r--backends/platform/dc/dc-fs.cpp10
-rw-r--r--backends/platform/iphone/osys_iphone.cpp4
-rw-r--r--backends/platform/ps2/systemps2.cpp4
-rw-r--r--backends/platform/psp/osys_psp.cpp4
-rw-r--r--backends/platform/sdl/sdl.cpp4
-rw-r--r--backends/platform/symbian/src/SymbianOS.cpp4
-rw-r--r--backends/platform/wince/wince-sdl.cpp4
8 files changed, 19 insertions, 19 deletions
diff --git a/backends/platform/PalmOS/Src/be_base.cpp b/backends/platform/PalmOS/Src/be_base.cpp
index c1a694292f..424c70566c 100644
--- a/backends/platform/PalmOS/Src/be_base.cpp
+++ b/backends/platform/PalmOS/Src/be_base.cpp
@@ -183,10 +183,10 @@ Common::TimerManager *OSystem_PalmBase::getTimerManager() {
Common::SeekableReadStream *OSystem_PalmBase::createConfigReadStream() {
Common::FSNode file(PALMOS_CONFIG_FILE);
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_PalmBase::createConfigWriteStream() {
Common::FSNode file(PALMOS_CONFIG_FILE);
- return file.openForWriting();
+ return file.createWriteStream();
}
diff --git a/backends/platform/dc/dc-fs.cpp b/backends/platform/dc/dc-fs.cpp
index 810eed836c..e21a12fa33 100644
--- a/backends/platform/dc/dc-fs.cpp
+++ b/backends/platform/dc/dc-fs.cpp
@@ -53,8 +53,8 @@ public:
virtual bool getChildren(AbstractFSList &list, ListMode mode, bool hidden) const { return false; }
virtual AbstractFSNode *getParent() const;
- virtual Common::SeekableReadStream *openForReading();
- virtual Common::WriteStream *openForWriting() { return 0; }
+ virtual Common::SeekableReadStream *createReadStream();
+ virtual Common::WriteStream *createWriteStream() { return 0; }
static AbstractFSNode *makeFileNodePath(const Common::String &path);
};
@@ -67,7 +67,7 @@ public:
virtual bool isDirectory() const { return true; }
virtual AbstractFSNode *getChild(const Common::String &n) const;
virtual bool getChildren(AbstractFSList &list, ListMode mode, bool hidden) const;
- virtual Common::SeekableReadStream *openForReading() { return 0; }
+ virtual Common::SeekableReadStream *createReadStream() { return 0; }
};
/* A file/directory which does not exist */
@@ -77,7 +77,7 @@ public:
virtual bool exists() const { return false; }
virtual bool isReadable() const { return false; }
- virtual Common::SeekableReadStream *openForReading() { return 0; }
+ virtual Common::SeekableReadStream *createReadStream() { return 0; }
};
AbstractFSNode *RoninCDFileNode::makeFileNodePath(const Common::String &path) {
@@ -150,7 +150,7 @@ AbstractFSNode *RoninCDFileNode::getParent() const {
}
-Common::SeekableReadStream *RoninCDFileNode::openForReading() {
+Common::SeekableReadStream *RoninCDFileNode::createReadStream() {
return StdioStream::makeFromPath(getPath().c_str(), false);
}
diff --git a/backends/platform/iphone/osys_iphone.cpp b/backends/platform/iphone/osys_iphone.cpp
index 48e95074e0..226626d551 100644
--- a/backends/platform/iphone/osys_iphone.cpp
+++ b/backends/platform/iphone/osys_iphone.cpp
@@ -1314,12 +1314,12 @@ OSystem *OSystem_IPHONE_create() {
Common::SeekableReadStream *OSystem_IPHONE::createConfigReadStream() {
Common::FSNode file(SCUMMVM_PREFS_PATH);
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_IPHONE::createConfigWriteStream() {
Common::FSNode file(SCUMMVM_PREFS_PATH);
- return file.openForWriting();
+ return file.createWriteStream();
}
void iphone_main(int argc, char *argv[]) {
diff --git a/backends/platform/ps2/systemps2.cpp b/backends/platform/ps2/systemps2.cpp
index a9b3b9f29f..e4852e67fa 100644
--- a/backends/platform/ps2/systemps2.cpp
+++ b/backends/platform/ps2/systemps2.cpp
@@ -776,14 +776,14 @@ Common::SeekableReadStream *OSystem_PS2::createConfigReadStream() {
char configFile[MAXPATHLEN];
makeConfigPath(configFile);
Common::FSNode file(configFile);
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_PS2::createConfigWriteStream() {
char configFile[MAXPATHLEN];
makeConfigPath(configFile);
Common::FSNode file(configFile);
- return file.openForWriting();
+ return file.createWriteStream();
}
bool OSystem_PS2::runningFromHost(void) {
diff --git a/backends/platform/psp/osys_psp.cpp b/backends/platform/psp/osys_psp.cpp
index 38208718de..de7ec0631c 100644
--- a/backends/platform/psp/osys_psp.cpp
+++ b/backends/platform/psp/osys_psp.cpp
@@ -645,10 +645,10 @@ void OSystem_PSP::displayMessageOnOSD(const char *msg) {
Common::SeekableReadStream *OSystem_PSP::createConfigReadStream() {
Common::FSNode file(PSP_CONFIG_FILE);
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_PSP::createConfigWriteStream() {
Common::FSNode file(PSP_CONFIG_FILE);
- return file.openForWriting();
+ return file.createWriteStream();
}
diff --git a/backends/platform/sdl/sdl.cpp b/backends/platform/sdl/sdl.cpp
index c852ba206d..13ad284060 100644
--- a/backends/platform/sdl/sdl.cpp
+++ b/backends/platform/sdl/sdl.cpp
@@ -386,12 +386,12 @@ static Common::String getDefaultConfigFileName() {
Common::SeekableReadStream *OSystem_SDL::createConfigReadStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_SDL::createConfigWriteStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForWriting();
+ return file.createWriteStream();
}
void OSystem_SDL::setWindowCaption(const char *caption) {
diff --git a/backends/platform/symbian/src/SymbianOS.cpp b/backends/platform/symbian/src/SymbianOS.cpp
index b822789b04..43a27c5436 100644
--- a/backends/platform/symbian/src/SymbianOS.cpp
+++ b/backends/platform/symbian/src/SymbianOS.cpp
@@ -125,12 +125,12 @@ static Common::String getDefaultConfigFileName() {
Common::SeekableReadStream *OSystem_SDL_Symbian::createConfigReadStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_SDL_Symbian::createConfigWriteStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForWriting();
+ return file.createWriteStream();
}
OSystem_SDL_Symbian::zoneDesc OSystem_SDL_Symbian::_zones[TOTAL_ZONES] = {
diff --git a/backends/platform/wince/wince-sdl.cpp b/backends/platform/wince/wince-sdl.cpp
index 7bfa3a97f6..a67f09fd75 100644
--- a/backends/platform/wince/wince-sdl.cpp
+++ b/backends/platform/wince/wince-sdl.cpp
@@ -465,12 +465,12 @@ static Common::String getDefaultConfigFileName() {
Common::SeekableReadStream *OSystem_WINCE3::createConfigReadStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForReading();
+ return file.createReadStream();
}
Common::WriteStream *OSystem_WINCE3::createConfigWriteStream() {
Common::FSNode file(getDefaultConfigFileName());
- return file.openForWriting();
+ return file.createWriteStream();
}
// ********************************************************************************************