From da4d4d8272a96b6ce5de905966f1ce9ba859a6a3 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Mon, 7 Aug 2017 19:08:03 -0400 Subject: SHERLOCK: Remove redundant derived Serializer class --- engines/sherlock/saveload.cpp | 4 ++-- engines/sherlock/saveload.h | 14 +------------- 2 files changed, 3 insertions(+), 15 deletions(-) (limited to 'engines/sherlock') diff --git a/engines/sherlock/saveload.cpp b/engines/sherlock/saveload.cpp index 45a4eedb10..44b5e103d2 100644 --- a/engines/sherlock/saveload.cpp +++ b/engines/sherlock/saveload.cpp @@ -219,7 +219,7 @@ void SaveManager::loadGame(int slot) { // Synchronize the savegame data Serializer s(saveFile, nullptr); - s.setSaveVersion(header._version); + s.setVersion(header._version); synchronize(s); delete saveFile; @@ -237,7 +237,7 @@ void SaveManager::saveGame(int slot, const Common::String &name) { // Synchronize the savegame data Serializer s(nullptr, out); - s.setSaveVersion(CURRENT_SAVEGAME_VERSION); + s.setVersion(CURRENT_SAVEGAME_VERSION); synchronize(s); out->finalize(); diff --git a/engines/sherlock/saveload.h b/engines/sherlock/saveload.h index 9a26741172..59b0b26d6e 100644 --- a/engines/sherlock/saveload.h +++ b/engines/sherlock/saveload.h @@ -55,19 +55,7 @@ struct SherlockSavegameHeader { class SherlockEngine; - -/** - * Derived serializer class with extra synchronization types - */ -class Serializer : public Common::Serializer { -public: - Serializer(Common::SeekableReadStream *in, Common::WriteStream *out) : Common::Serializer(in, out) {} - - /** - * New method to allow setting the version - */ - void setSaveVersion(byte version) { _version = version; } -}; +typedef Common::Serializer Serializer; class SaveManager { protected: -- cgit v1.2.3