]> git.saurik.com Git - wxWidgets.git/blobdiff - src/html/htmlpars.cpp
Add support for icons in wxAUI panes title bars.
[wxWidgets.git] / src / html / htmlpars.cpp
index 3c312275a707e0a3007edb76210d6c3853cfec9d..38c0680c232a5eb5507c41f2d7118c9862500dba 100644 (file)
@@ -250,8 +250,7 @@ void wxHtmlParser::DestroyDOMTree()
     }
     m_Tags = m_CurTag = NULL;
 
-    delete m_TextPieces;
-    m_TextPieces = NULL;
+    wxDELETE(m_TextPieces);
 }
 
 void wxHtmlParser::DoParsing()
@@ -870,10 +869,14 @@ wxChar wxHtmlEntitiesParser::GetEntityChar(const wxString& entity) const
         return GetCharForCode(code);
 }
 
-wxFSFile *wxHtmlParser::OpenURL(wxHtmlURLType WXUNUSED(type),
+wxFSFile *wxHtmlParser::OpenURL(wxHtmlURLType type,
                                 const wxString& url) const
 {
-    return m_FS ? m_FS->OpenFile(url) : NULL;
+    int flags = wxFS_READ;
+    if (type == wxHTML_URL_IMAGE)
+        flags |= wxFS_SEEKABLE;
+
+    return m_FS ? m_FS->OpenFile(url, flags) : NULL;
 
 }