diff options
author | Max Horn | 2009-05-29 14:38:22 +0000 |
---|---|---|
committer | Max Horn | 2009-05-29 14:38:22 +0000 |
commit | fb79b185717c9aae7c793e7f07d5d6b94aec4abf (patch) | |
tree | 6df973c3f64d5712d6df36caa0af30b6b6012561 /engines/parallaction | |
parent | 518e005ec27ef323275b364a3cd16d24d7491674 (diff) | |
download | scummvm-rg350-fb79b185717c9aae7c793e7f07d5d6b94aec4abf.tar.gz scummvm-rg350-fb79b185717c9aae7c793e7f07d5d6b94aec4abf.tar.bz2 scummvm-rg350-fb79b185717c9aae7c793e7f07d5d6b94aec4abf.zip |
Changed SaveFileManager methods to take Common::String params (instead of char pointers)
svn-id: r41000
Diffstat (limited to 'engines/parallaction')
-rw-r--r-- | engines/parallaction/detection.cpp | 6 | ||||
-rw-r--r-- | engines/parallaction/saveload.cpp | 10 |
2 files changed, 8 insertions, 8 deletions
diff --git a/engines/parallaction/detection.cpp b/engines/parallaction/detection.cpp index 6e5be94c81..ec483bad84 100644 --- a/engines/parallaction/detection.cpp +++ b/engines/parallaction/detection.cpp @@ -286,7 +286,7 @@ SaveStateList ParallactionMetaEngine::listSaves(const char *target) const { Common::String pattern = target; pattern += ".0??"; - filenames = saveFileMan->listSavefiles(pattern.c_str()); + filenames = saveFileMan->listSavefiles(pattern); sort(filenames.begin(), filenames.end()); // Sort (hopefully ensuring we are sorted numerically..) SaveStateList saveList; @@ -295,7 +295,7 @@ SaveStateList ParallactionMetaEngine::listSaves(const char *target) const { int slotNum = atoi(file->c_str() + file->size() - 2); if (slotNum >= 0 && slotNum <= 99) { - Common::InSaveFile *in = saveFileMan->openForLoading(file->c_str()); + Common::InSaveFile *in = saveFileMan->openForLoading(*file); if (in) { Common::String saveDesc = in->readLine(); saveList.push_back(SaveStateDescriptor(slotNum, saveDesc)); @@ -316,7 +316,7 @@ void ParallactionMetaEngine::removeSaveState(const char *target, int slot) const Common::String filename = target; filename += extension; - g_system->getSavefileManager()->removeSavefile(filename.c_str()); + g_system->getSavefileManager()->removeSavefile(filename); } #if PLUGIN_ENABLED_DYNAMIC(PARALLACTION) diff --git a/engines/parallaction/saveload.cpp b/engines/parallaction/saveload.cpp index 784fc8ac8a..5db0e732ee 100644 --- a/engines/parallaction/saveload.cpp +++ b/engines/parallaction/saveload.cpp @@ -88,12 +88,12 @@ Common::String SaveLoad::genSaveFileName(uint slot) { Common::InSaveFile *SaveLoad::getInSaveFile(uint slot) { Common::String name = genSaveFileName(slot); - return _saveFileMan->openForLoading(name.c_str()); + return _saveFileMan->openForLoading(name); } Common::OutSaveFile *SaveLoad::getOutSaveFile(uint slot) { Common::String name = genSaveFileName(slot); - return _saveFileMan->openForSaving(name.c_str()); + return _saveFileMan->openForSaving(name); } @@ -307,7 +307,7 @@ void SaveLoadChooser::reflowLayout() { int SaveLoad::buildSaveFileList(Common::StringList& l) { Common::String pattern = _saveFilePrefix + ".???"; - Common::StringList filenames = _saveFileMan->listSavefiles(pattern.c_str()); + Common::StringList filenames = _saveFileMan->listSavefiles(pattern); Common::String s; @@ -439,7 +439,7 @@ void SaveLoad_ns::renameOldSavefiles() { for (i = 0; i < NUM_SAVESLOTS; i++) { exists[i] = false; Common::String name = genOldSaveFileName(i); - Common::InSaveFile *f = _saveFileMan->openForLoading(name.c_str()); + Common::InSaveFile *f = _saveFileMan->openForLoading(name); if (f) { exists[i] = true; num++; @@ -468,7 +468,7 @@ void SaveLoad_ns::renameOldSavefiles() { if (exists[i]) { Common::String oldName = genOldSaveFileName(i); Common::String newName = genSaveFileName(i); - if (_saveFileMan->renameSavefile(oldName.c_str(), newName.c_str())) { + if (_saveFileMan->renameSavefile(oldName, newName)) { success++; } else { warning("Error %i (%s) occurred while renaming %s to %s", _saveFileMan->getError(), |