X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/768c6e8be2cb044aac165c39e3f6847ee601ab0f..6eaa4426e06c03017b47beaf4235d9f079edf5fe:/src/mac/carbon/mimetmac.cpp?ds=sidebyside diff --git a/src/mac/carbon/mimetmac.cpp b/src/mac/carbon/mimetmac.cpp index 847502c1b7..634c70065c 100644 --- a/src/mac/carbon/mimetmac.cpp +++ b/src/mac/carbon/mimetmac.cpp @@ -26,10 +26,6 @@ // // -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "mimetype.h" -#endif - // for compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -422,8 +418,9 @@ wxString wxFileTypeImpl::GetCommand(const wxString& verb) const CFRelease(cfurlAppPath); //PHEW! Success! + //Since a filename might have spaces in it, so surround it with quotes if(cfsUnixPath) - return wxMacCFStringHolder(cfsUnixPath).AsString(wxLocale::GetSystemEncoding()); + return wxString(wxT("'")) + wxMacCFStringHolder(cfsUnixPath).AsString(wxLocale::GetSystemEncoding()) + wxString(wxT("'")); } else { @@ -972,7 +969,7 @@ public: } } - static void PrintOutType(wxString& sMessage, wxString sValue, CFTypeRef cfRef) + static void PrintOutType(wxString& sMessage, const wxString& sValue, CFTypeRef cfRef) { sMessage << wxT(" {");