[Scummvm-cvs-logs] CVS: scummvm/base gameDetector.cpp,1.1,1.2 gameDetector.h,1.1,1.2 plugins.cpp,1.1,1.2

Max Horn fingolfin at users.sourceforge.net
Wed Sep 17 16:06:04 CEST 2003


Update of /cvsroot/scummvm/scummvm/base
In directory sc8-pr-cvs1:/tmp/cvs-serv10200/base

Modified Files:
	gameDetector.cpp gameDetector.h plugins.cpp 
Log Message:
cleanup

Index: gameDetector.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/base/gameDetector.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- gameDetector.cpp	17 Sep 2003 22:40:55 -0000	1.1
+++ gameDetector.cpp	17 Sep 2003 23:05:07 -0000	1.2
@@ -189,7 +189,6 @@
 	_gameDataPath = 0;
 	_gameTempo = 0;
 	_midi_driver = MD_AUTO;
-	_game.id = 0;
 	_game.features = 0;
 	_plugin = 0;
 
@@ -632,7 +631,6 @@
 bool GameDetector::detectGame() {
 	const TargetSettings *target;
 	const char *realGame, *basename;
-	_game.id = 0;
 	_gameText.clear();
 
 	realGame = g_config->get("gameid");
@@ -726,7 +724,7 @@
 #elif defined(X11_BACKEND)
 	return OSystem_X11_create();
 #elif defined(__MORPHOS__)
-	return OSystem_MorphOS_create(_game.id, _gfx_mode, _fullScreen);
+	return OSystem_MorphOS_create(_gfx_mode, _fullScreen);
 #elif defined(_WIN32_WCE)
 	return OSystem_WINCE3_create();
 #elif defined(MACOS_CARBON)
@@ -742,12 +740,8 @@
 }
 
 Engine *GameDetector::createEngine(OSystem *system) {
-	Engine *engine = NULL;
-
 	assert(_plugin);
-	engine = _plugin->createInstance(this, system);
-
-	return engine;
+	return _plugin->createInstance(this, system);
 }
 
 int GameDetector::getMidiDriverType() {

Index: gameDetector.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/base/gameDetector.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- gameDetector.h	17 Sep 2003 22:40:55 -0000	1.1
+++ gameDetector.h	17 Sep 2003 23:05:07 -0000	1.2
@@ -102,31 +102,6 @@
 
 typedef Engine *(*EngineFactory)(GameDetector *detector, OSystem *syst);
 
-// Factory functions => no need to include the specific classes
-// in this header. This serves two purposes:
-// 1) Clean seperation from the game modules (scumm, simon) and the generic code
-// 2) Faster (compiler doesn't have to parse lengthy header files)
-#ifndef DISABLE_SCUMM
-extern const TargetSettings *Engine_SCUMM_targetList();
-extern Engine *Engine_SCUMM_create(GameDetector *detector, OSystem *syst);
-#endif
-
-#ifndef DISABLE_SIMON
-extern Engine *Engine_SIMON_create(GameDetector *detector, OSystem *syst);
-extern const TargetSettings *Engine_SIMON_targetList();
-#endif
-
-#ifndef DISABLE_SKY
-extern const TargetSettings *Engine_SKY_targetList();
-extern Engine *Engine_SKY_create(GameDetector *detector, OSystem *syst);
-#endif
-
-#ifndef DISABLE_SWORD2
-extern const TargetSettings *Engine_SWORD2_targetList();
-extern Engine *Engine_SWORD2_create(GameDetector *detector, OSystem *syst);
-#endif
-
-
 class GameDetector {
 	typedef ScummVM::String String;
 

Index: plugins.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/base/plugins.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- plugins.cpp	17 Sep 2003 22:40:55 -0000	1.1
+++ plugins.cpp	17 Sep 2003 23:05:07 -0000	1.2
@@ -25,6 +25,34 @@
 #include "common/engine.h"
 
 
+// Factory functions => no need to include the specific classes
+// in this header. This serves two purposes:
+// 1) Clean seperation from the game modules (scumm, simon) and the generic code
+// 2) Faster (compiler doesn't have to parse lengthy header files)
+#ifndef DISABLE_SCUMM
+extern const TargetSettings *Engine_SCUMM_targetList();
+extern Engine *Engine_SCUMM_create(GameDetector *detector, OSystem *syst);
+#endif
+
+#ifndef DISABLE_SIMON
+extern Engine *Engine_SIMON_create(GameDetector *detector, OSystem *syst);
+extern const TargetSettings *Engine_SIMON_targetList();
+#endif
+
+#ifndef DISABLE_SKY
+extern const TargetSettings *Engine_SKY_targetList();
+extern Engine *Engine_SKY_create(GameDetector *detector, OSystem *syst);
+#endif
+
+#ifndef DISABLE_SWORD2
+extern const TargetSettings *Engine_SWORD2_targetList();
+extern Engine *Engine_SWORD2_create(GameDetector *detector, OSystem *syst);
+#endif
+
+
+#pragma mark -
+
+
 PluginManager	*g_pluginManager = 0;
 
 





More information about the Scummvm-git-logs mailing list