From f89e3c6f87943716dc77c0910512b2f4cff27e6a Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 20 Feb 2008 16:33:55 +0000 Subject: [PATCH] revert not encoding the colons in FileNameToURL() under MSW (r51904, patch 1890922) as this completely broke wxFS URLs parsing; explain this in a comment in the trunk version git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@51940 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- docs/changes.txt | 3 +-- src/common/filesys.cpp | 7 ------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/docs/changes.txt b/docs/changes.txt index 17c3d6495f..81a4a77937 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -130,8 +130,7 @@ wxMSW: - Fix rare bug with messages delivered to wrong wxSocket (Tim Kosse). - Fix setting icons when they have non-default (16*16 and 32*32) sizes. -- Fixed wxLocale::GetInfo() to use the CRT locale. -- Return URLs which IE can open from wxFileSystem::FileNameToURL(). +- Fixed wxLocale::GetInfo to use the C locale. - Don't enable disabled windows when showing them (Harry McKame). - Fix assert when using owner-drawn menu items with the newest (Vista) SDK. - Fixed wxTextCtrl to not process clipboard events twice if there's diff --git a/src/common/filesys.cpp b/src/common/filesys.cpp index c017905b97..72f647cd29 100644 --- a/src/common/filesys.cpp +++ b/src/common/filesys.cpp @@ -641,14 +641,7 @@ wxString wxFileSystem::FileNameToURL(const wxFileName& filename) url.Replace(g_nativePathString, g_unixPathString); url.Replace(wxT("%"), wxT("%25")); // '%'s must be replaced first! url.Replace(wxT("#"), wxT("%23")); -#ifndef __WXMSW__ - // even though encoding the colon is (AFAICS) the right thing to do, we - // shouldn't do this under Windows because IE refuses to handle the - // resulting file:// URLs and Firefox and Opera (and probably all the other - // browsers as they need to be IE-compatible anyhow) open both the versions - // with ':' and "%3A", so leave the colon alone to keep IE happy url.Replace(wxT(":"), wxT("%3A")); -#endif // __WXMSW__ url = wxT("file:") + url; return url; }