X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/dac7d53a83c862235ad8f3dfe5706e9af4c1480a..7912e6332f65d8c975df0a7bd64a0c2d8445c63f:/src/common/filesys.cpp diff --git a/src/common/filesys.cpp b/src/common/filesys.cpp index 97d2f78d4b..d335bf7e7a 100644 --- a/src/common/filesys.cpp +++ b/src/common/filesys.cpp @@ -431,7 +431,7 @@ wxString wxFileSystem::URLToNativePath( const wxString& url ) path = path.Mid(7) ; } -/* +#ifndef __UNIX__ // file urls either start with a forward slash (local harddisk), // otherwise they have a servername/sharename notation, // which only exists on msw and corresponds to a unc @@ -439,15 +439,13 @@ wxString wxFileSystem::URLToNativePath( const wxString& url ) { path = path.Mid(1) ; } -#ifdef __WXMSW__ else if ( (url.Find(wxT("file://")) == 0) && (path.Find(wxT('/')) != wxNOT_FOUND) && (path.Length() > 1) && (path[1u] != wxT(':')) ) { - path = wxT("\\\\") + path ; + path = wxT("//") + path ; } #endif -*/ path.Replace(g_unixPathString, g_nativePathString) ; @@ -459,7 +457,6 @@ wxString wxFileSystem::NativePathToURL( const wxString& path ) { wxString url = path ; -/* #ifdef __WXMSW__ // unc notation if ( url.Find(wxT("\\\\")) == 0 ) @@ -471,7 +468,6 @@ wxString wxFileSystem::NativePathToURL( const wxString& path ) { url = wxT("/") + url ; } -*/ url.Replace(g_nativePathString, g_unixPathString) ; url = wxT("file://") + url ;