[Scummvm-cvs-logs] SF.net SVN: scummvm: [26109] scummvm/trunk/backends/fs/symbian/symbian-fs. cpp

anotherguest at users.sourceforge.net anotherguest at users.sourceforge.net
Mon Mar 12 21:13:08 CET 2007


Revision: 26109
          http://scummvm.svn.sourceforge.net/scummvm/?rev=26109&view=rev
Author:   anotherguest
Date:     2007-03-12 13:13:07 -0700 (Mon, 12 Mar 2007)

Log Message:
-----------
Added mapping from '/' to '\' since Symbian OS does n't support mixed mode (\ and / in the same filename).

Modified Paths:
--------------
    scummvm/trunk/backends/fs/symbian/symbian-fs.cpp

Modified: scummvm/trunk/backends/fs/symbian/symbian-fs.cpp
===================================================================
--- scummvm/trunk/backends/fs/symbian/symbian-fs.cpp	2007-03-12 20:08:52 UTC (rev 26108)
+++ scummvm/trunk/backends/fs/symbian/symbian-fs.cpp	2007-03-12 20:13:07 UTC (rev 26109)
@@ -69,6 +69,16 @@
 	return cur + 1;
 }
 
+static void fixFilePath(Common::String& path) {
+	TInt len = path.size();
+	
+	for (TInt index = 0; index < len; index++) {
+		if (path[index] == '/') {	
+			path[index] = '\\';
+		}
+	}
+}
+
 AbstractFilesystemNode *AbstractFilesystemNode::getCurrentDirectory() {
 	char path[MAXPATHLEN];
 	getcwd(path, MAXPATHLEN);
@@ -99,6 +109,9 @@
 		_isPseudoRoot = false;
 
 	_path = path;
+	
+	fixFilePath(_path);
+
 	_displayName = lastPathComponent(_path);
 
 	TEntry fileAttribs;


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