[Scummvm-cvs-logs] CVS: scummvm/scumm/smush smush_player.cpp,1.141,1.142

Max Horn fingolfin at users.sourceforge.net
Thu Jan 6 10:39:08 CET 2005


Update of /cvsroot/scummvm/scummvm/scumm/smush
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8084

Modified Files:
	smush_player.cpp 
Log Message:
Fix getStrings to use the ScummEngine::openFile method

Index: smush_player.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/smush/smush_player.cpp,v
retrieving revision 1.141
retrieving revision 1.142
diff -u -d -r1.141 -r1.142
--- smush_player.cpp	1 Jan 2005 16:09:19 -0000	1.141
+++ smush_player.cpp	6 Jan 2005 18:38:11 -0000	1.142
@@ -172,11 +172,11 @@
 	}
 };
 
-static StringResource *getStrings(const char *file, bool is_encoded) {
+static StringResource *getStrings(ScummEngine *vm, const char *file, bool is_encoded) {
 	debugC(DEBUG_SMUSH, "trying to read text ressources from %s", file);
-	File theFile;
+	ScummFile theFile;
 
-	theFile.open(file);
+	vm->openFile(theFile, file);
 	if (!theFile.isOpen()) {
 		return 0;
 	}
@@ -195,7 +195,7 @@
 
 		if (type != TYPE_ETRS) {
 			delete [] filebuffer;
-			return getStrings(file, false);
+			return getStrings(vm, file, false);
 		}
 
 		char *old = filebuffer;
@@ -651,11 +651,11 @@
 	char fname[260];
 	memcpy(fname, file, i - file);
 	strcpy(fname + (i - file), ".trs");
-	if ((_strings = getStrings(fname, false)) != 0) {
+	if ((_strings = getStrings(_vm, fname, false)) != 0) {
 		return true;
 	}
 
-	if ((_strings = getStrings("digtxt.trs", true)) != 0) {
+	if ((_strings = getStrings(_vm, "digtxt.trs", true)) != 0) {
 		return true;
 	}
 	return false;





More information about the Scummvm-git-logs mailing list