]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/filesys.cpp
SourceForge patch #654210 to fix naming/numbering shared libs under OS X
[wxWidgets.git] / src / common / filesys.cpp
index ceb2810018702e17941cca945c5f17470f3abca1..e86b88cea1a0995b32f1163808fa80a73397b062 100644 (file)
@@ -441,6 +441,11 @@ wxFileName wxFileSystem::URLToFileName(const wxString& url)
        {
                path = path.Mid(5);
        }
+       // Remove preceding double slash on Mac Classic
+#if defined(__WXMAC__) && !defined(__UNIX__)
+    else if ( path.Find(wxT("//")) == 0 )
+        path = path.Mid(2);
+#endif
     
     path.Replace(wxT("%25"), wxT("%"));
     path.Replace(wxT("%3A"), wxT(":"));
@@ -482,6 +487,10 @@ wxString wxFileSystem::FileNameToURL(const wxFileName& filename)
     else
     {
         url = wxT("/") + url;
+#ifdef __WXMAC__
+        url = wxT("/") + url;
+#endif
+
     }
 #endif