]> git.saurik.com Git - wxWidgets.git/blobdiff - src/html/htmprint.cpp
Added wxToggleButton handler
[wxWidgets.git] / src / html / htmprint.cpp
index 800ca10d6632b7014a5e681228c0641786335c4a..4e91a6baaf5eb46590f5942d74e282948253210a 100644 (file)
@@ -303,7 +303,12 @@ void wxHtmlPrintout::SetHtmlText(const wxString& html, const wxString &basepath,
 void wxHtmlPrintout::SetHtmlFile(const wxString& htmlfile)
 {
     wxFileSystem fs;
-    wxFSFile *ff = fs.OpenFile(htmlfile);
+    wxFSFile *ff;
+    
+    if (wxFileExists(htmlfile))
+        ff = fs.OpenFile(wxFileSystem::FileNameToURL(htmlfile));
+    else
+        ff = fs.OpenFile(htmlfile);
 
     if (ff == NULL)
     {