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

joostp at users.sourceforge.net joostp at users.sourceforge.net
Wed Mar 19 12:07:27 CET 2008


Revision: 31195
          http://scummvm.svn.sourceforge.net/scummvm/?rev=31195&view=rev
Author:   joostp
Date:     2008-03-19 04:07:27 -0700 (Wed, 19 Mar 2008)

Log Message:
-----------
Implement OSystem_PSP::getFilesystemFactory() and OSystemPSP::getTimeAndDate()

Modified Paths:
--------------
    scummvm/trunk/backends/platform/psp/osys_psp.cpp
    scummvm/trunk/backends/platform/psp/osys_psp.h
    scummvm/trunk/common/system.cpp

Modified: scummvm/trunk/backends/platform/psp/osys_psp.cpp
===================================================================
--- scummvm/trunk/backends/platform/psp/osys_psp.cpp	2008-03-19 10:37:33 UTC (rev 31194)
+++ scummvm/trunk/backends/platform/psp/osys_psp.cpp	2008-03-19 11:07:27 UTC (rev 31195)
@@ -637,6 +637,11 @@
 	sceKernelExitGame();
 }
 
+void OSystem_PSP::getTimeAndDate(struct tm &t) const {
+	time_t curTime = time(0);
+	t = *localtime(&curTime);
+}
+
 void OSystem_PSP::setWindowCaption(const char *caption) {
 }
 

Modified: scummvm/trunk/backends/platform/psp/osys_psp.h
===================================================================
--- scummvm/trunk/backends/platform/psp/osys_psp.h	2008-03-19 10:37:33 UTC (rev 31194)
+++ scummvm/trunk/backends/platform/psp/osys_psp.h	2008-03-19 11:07:27 UTC (rev 31195)
@@ -26,7 +26,9 @@
 #include "common/scummsys.h"
 #include "common/system.h"
 #include "graphics/surface.h"
+#include "backends/fs/psp/psp-fs-factory.h"
 
+
 #include <SDL.h>
 
 enum GraphicModeID {
@@ -135,6 +137,8 @@
 	Common::SaveFileManager *getSavefileManager() { return _savefile; }
 	Audio::Mixer *getMixer() { return _mixer; }
 	Common::TimerManager *getTimerManager() { return _timer; }
+	FilesystemFactory *getFilesystemFactory() { return &PSPFilesystemFactory::instance(); }
+	void getTimeAndDate(struct tm &t) const;
 
 	virtual void quit();
 

Modified: scummvm/trunk/common/system.cpp
===================================================================
--- scummvm/trunk/common/system.cpp	2008-03-19 10:37:33 UTC (rev 31194)
+++ scummvm/trunk/common/system.cpp	2008-03-19 11:07:27 UTC (rev 31195)
@@ -146,12 +146,10 @@
 	#include "backends/fs/palmos/palmos-fs-factory.h"
 #elif defined(__PLAYSTATION2__)
 	#include "backends/fs/ps2/ps2-fs-factory.h"
-#elif defined(__PSP__)
-	#include "backends/fs/psp/psp-fs-factory.h"
 #endif
 
 FilesystemFactory *OSystem::getFilesystemFactory() {
-	#if defined(__amigaos4__) || defined(__DC__) || defined(__SYMBIAN32__) || defined(UNIX) || defined(WIN32)
+	#if defined(__amigaos4__) || defined(__DC__) || defined(__SYMBIAN32__) || defined(UNIX) || defined(WIN32) || defined(__PSP__)
 		// These ports already implement this function, so it should never be called.
 		return 0;
 	#elif defined(__DS__)
@@ -162,8 +160,6 @@
 		return &PalmOSFilesystemFactory::instance();
 	#elif defined(__PLAYSTATION2__)
 		return &Ps2FilesystemFactory::instance();
-	#elif defined(__PSP__)
-		return &PSPFilesystemFactory::instance();
 	#else
 		#error Unknown and unsupported backend in OSystem::getFilesystemFactory
 	#endif


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