[Scummvm-cvs-logs] scummvm master -> 887b5c8cdde0c32d0a7b5ed24d82e52f5dc04d92

digitall digitall at scummvm.org
Mon Dec 5 22:40:37 CET 2011


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
887b5c8cdd DREAMWEB: Remove unused 'openFile', merge duplicated 'getFilename'


Commit: 887b5c8cdde0c32d0a7b5ed24d82e52f5dc04d92
    https://github.com/scummvm/scummvm/commit/887b5c8cdde0c32d0a7b5ed24d82e52f5dc04d92
Author: D G Turner (digitall at scummvm.org)
Date: 2011-12-05T13:38:31-08:00

Commit Message:
DREAMWEB: Remove unused 'openFile', merge duplicated 'getFilename'

Changed paths:
    devtools/tasmrecover/tasm-recover
    engines/dreamweb/dreamgen.h
    engines/dreamweb/stubs.cpp
    engines/dreamweb/stubs.h
    engines/dreamweb/vgagrafx.cpp



diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover
index 1e56984..206bb8e 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -377,6 +377,7 @@ generator = cpp(context, "DreamGen", blacklist = [
 	'obtoinv',
 	'oldtonames',
 	'onedigit',
+	'openfile',
 	'openforsave',
 	'othersmoker',
 	'out22c',
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index 39af176..dd3f1f9 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -821,7 +821,6 @@ public:
 	void useCardReader2();
 	void useCardReader3();
 	void useHandle();
-	void openFile();
 	void showPuzText();
 	void incRyanPage();
 	void edenInBath();
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index ab28503..5fb861c 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -735,7 +735,7 @@ void DreamGenContext::switchRyanOff() {
 	data.byte(kRyanon) = 1;
 }
 
-static Common::String getFilename(Context &context) {
+Common::String DreamGenContext::getFilename(Context &context) {
 	const char *name = (const char *)context.cs.ptr(context.dx, 0);
 	return Common::String(name);
 }
@@ -865,14 +865,6 @@ void DreamGenContext::openFileFromC() {
 	openFileNoCheck();
 }
 
-void DreamGenContext::openFile() {
-	Common::String name = getFilename(*this);
-	debug(1, "opening file: %s", name.c_str());
-	engine->openFile(name);
-	cs.word(kHandle) = 1; //only one handle
-	flags._c = false;
-}
-
 void DreamGenContext::createFile() {
 	::error("createfile");
 }
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index b9f2fed..72a5048 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -463,5 +463,6 @@
 	void bibleQuote();
 	void realCredits();
 	void intro();
+	Common::String getFilename(Context &context);
 
 #endif
diff --git a/engines/dreamweb/vgagrafx.cpp b/engines/dreamweb/vgagrafx.cpp
index 440688d..4848e14 100644
--- a/engines/dreamweb/vgagrafx.cpp
+++ b/engines/dreamweb/vgagrafx.cpp
@@ -21,6 +21,7 @@
  */
 
 #include "dreamweb/dreamweb.h"
+#include "dreamweb/stubs.h"
 #include "engines/util.h"
 #include "graphics/surface.h"
 
@@ -210,15 +211,6 @@ void DreamGenContext::setMode() {
 	initGraphics(320, 200, false);
 }
 
-static Common::String getFilename(Context &context) {
-	uint16 name_ptr = context.dx;
-	Common::String name;
-	uint8 c;
-	while((c = context.cs.byte(name_ptr++)) != 0)
-		name += (char)c;
-	return name;
-}
-
 void DreamGenContext::showPCX(const Common::String &name) {
 	Common::File pcxFile;
 






More information about the Scummvm-git-logs mailing list