diff options
author | Max Horn | 2004-11-27 00:26:11 +0000 |
---|---|---|
committer | Max Horn | 2004-11-27 00:26:11 +0000 |
commit | 876e738dce6e3725ce28d8caf1520e71edfe09f0 (patch) | |
tree | 582797db161e7209b70fb3c563bdb5d5b3a2e060 /backends/PalmOS/Src | |
parent | d56cd17183008830b4fd50d903f7a0250928b691 (diff) | |
download | scummvm-rg350-876e738dce6e3725ce28d8caf1520e71edfe09f0.tar.gz scummvm-rg350-876e738dce6e3725ce28d8caf1520e71edfe09f0.tar.bz2 scummvm-rg350-876e738dce6e3725ce28d8caf1520e71edfe09f0.zip |
Moved Engine::getSavePath() to class SaveFileManager; removed the 'directory' parameter from SaveFileManager::openSavefile and listSavefiles (they always use getSavePath() now, which is what we did anyway)
svn-id: r15901
Diffstat (limited to 'backends/PalmOS/Src')
-rw-r--r-- | backends/PalmOS/Src/palmsave.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/backends/PalmOS/Src/palmsave.cpp b/backends/PalmOS/Src/palmsave.cpp index 291b4d9204..3c3c6791a3 100644 --- a/backends/PalmOS/Src/palmsave.cpp +++ b/backends/PalmOS/Src/palmsave.cpp @@ -126,17 +126,17 @@ uint32 PalmSaveFile::write(const void *buf, uint32 size) { class PalmSaveFileManager : public SaveFileManager { public: - SaveFile *open_savefile(const char *filename, const char *directory, bool saveOrLoad); - void list_savefiles(const char *prefix, const char *directory, bool *marks, int num); + SaveFile *openSavefile(const char *filename, bool saveOrLoad); + void listSavefiles(const char *prefix, bool *marks, int num); protected: SaveFile *makeSaveFile(const char *filename, bool saveOrLoad); }; -SaveFile *PalmSaveFileManager::open_savefile(const char *filename, const char *directory, bool saveOrLoad) { +SaveFile *PalmSaveFileManager::openSavefile(const char *filename, bool saveOrLoad) { char buf[256]; - strncpy(buf, directory, sizeof(buf)); + strncpy(buf, getSavePath(), sizeof(buf)); strncat(buf, filename, sizeof(buf)); SaveFile *sf = makeSaveFile(buf, saveOrLoad); @@ -148,10 +148,10 @@ SaveFile *PalmSaveFileManager::open_savefile(const char *filename, const char *d return sf; } -void PalmSaveFileManager::list_savefiles(const char *prefix, const char *directory, bool *marks, int num) { +void PalmSaveFileManager::listSavefiles(const char *prefix, bool *marks, int num) { FileRef fileRef; // try to open the dir - Err e = VFSFileOpen(gVars->volRefNum, directory, vfsModeRead, &fileRef); + Err e = VFSFileOpen(gVars->volRefNum, getSavePath(), vfsModeRead, &fileRef); memset(marks, false, num*sizeof(bool)); if (e != errNone) |