[Scummvm-cvs-logs] SF.net SVN: scummvm:[36007] scummvm/trunk/backends

fingolfin at users.sourceforge.net fingolfin at users.sourceforge.net
Fri Jan 23 00:14:16 CET 2009


Revision: 36007
          http://scummvm.svn.sourceforge.net/scummvm/?rev=36007&view=rev
Author:   fingolfin
Date:     2009-01-22 23:14:16 +0000 (Thu, 22 Jan 2009)

Log Message:
-----------
Get rid of the wrappers around the zlib stream wrapper wrappers ;)

Modified Paths:
--------------
    scummvm/trunk/backends/module.mk
    scummvm/trunk/backends/platform/dc/vmsave.cpp
    scummvm/trunk/backends/saves/default/default-saves.cpp

Removed Paths:
-------------
    scummvm/trunk/backends/saves/compressed/

Modified: scummvm/trunk/backends/module.mk
===================================================================
--- scummvm/trunk/backends/module.mk	2009-01-22 23:03:12 UTC (rev 36006)
+++ scummvm/trunk/backends/module.mk	2009-01-22 23:14:16 UTC (rev 36007)
@@ -33,7 +33,6 @@
 	plugins/win32/win32-provider.o \
 	saves/savefile.o \
 	saves/default/default-saves.o \
-	saves/compressed/compressed-saves.o \
 	saves/posix/posix-saves.o \
 	saves/psp/psp-saves.o \
 	timer/default/default-timer.o \

Modified: scummvm/trunk/backends/platform/dc/vmsave.cpp
===================================================================
--- scummvm/trunk/backends/platform/dc/vmsave.cpp	2009-01-22 23:03:12 UTC (rev 36006)
+++ scummvm/trunk/backends/platform/dc/vmsave.cpp	2009-01-22 23:14:16 UTC (rev 36007)
@@ -30,7 +30,7 @@
 #include <common/savefile.h>
 #include <gui/GuiManager.h>
 #include <gui/message.h>
-#include <backends/saves/compressed/compressed-saves.h>
+#include <common/zlib.h>
 
 
 // Savegame can not be bigger than this
@@ -323,13 +323,13 @@
 public:
 
   virtual Common::OutSaveFile *openForSaving(const char *filename) {
-	return wrapOutSaveFile(new OutVMSave(filename));
+	return Common::wrapCompressedWriteStream(new OutVMSave(filename));
   }
 
   virtual Common::InSaveFile *openForLoading(const char *filename) {
 	InVMSave *s = new InVMSave();
 	if (s->readSaveGame(filename)) {
-	  return wrapInSaveFile(s);
+	  return Common::wrapCompressedReadStream(s);
 	} else {
 	  delete s;
 	  return NULL;

Modified: scummvm/trunk/backends/saves/default/default-saves.cpp
===================================================================
--- scummvm/trunk/backends/saves/default/default-saves.cpp	2009-01-22 23:03:12 UTC (rev 36006)
+++ scummvm/trunk/backends/saves/default/default-saves.cpp	2009-01-22 23:14:16 UTC (rev 36007)
@@ -26,13 +26,13 @@
 #if !defined(DISABLE_DEFAULT_SAVEFILEMANAGER)
 
 #include "backends/saves/default/default-saves.h"
-#include "backends/saves/compressed/compressed-saves.h"
 
 #include "common/savefile.h"
 #include "common/util.h"
 #include "common/fs.h"
 #include "common/archive.h"
 #include "common/config-manager.h"
+#include "common/zlib.h"
 
 #include <errno.h>	// for removeSavefile()
 
@@ -86,7 +86,7 @@
 	// Open the file for reading
 	Common::SeekableReadStream *sf = file.openForReading();
 
-	return wrapInSaveFile(sf);
+	return Common::wrapCompressedReadStream(sf);
 }
 
 Common::OutSaveFile *DefaultSaveFileManager::openForSaving(const char *filename) {
@@ -101,7 +101,7 @@
 	// Open the file for saving
 	Common::WriteStream *sf = file.openForWriting();
 
-	return wrapOutSaveFile(sf);
+	return Common::wrapCompressedWriteStream(sf);
 }
 
 bool DefaultSaveFileManager::removeSavefile(const char *filename) {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list