X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/20a8b34e2c6d43140cb8b38482536a49ed7e0e7a..b540eb2bee54608fc00b04e800e45086d1d04ff1:/src/generic/helpwxht.cpp diff --git a/src/generic/helpwxht.cpp b/src/generic/helpwxht.cpp index 2dc02e2b10..dc7f167a13 100644 --- a/src/generic/helpwxht.cpp +++ b/src/generic/helpwxht.cpp @@ -27,6 +27,7 @@ # include "wx/list.h" # include "wx/intl.h" # include "wx/layout.h" +# include "wx/combobox.h" #endif #include "wx/helpbase.h" @@ -35,7 +36,9 @@ #include #include +#ifndef __MWERKS__ #include +#endif #ifndef __WINDOWS__ # include @@ -52,22 +55,22 @@ IMPLEMENT_CLASS(wxHelpControllerHtml, wxHTMLHelpControllerBase) class wxForceHtmlFilter : public wxHtmlFilter { public: - virtual wxString ReadFile(const wxFSFile& file) + virtual wxString ReadFile(const wxFSFile& file) const { wxInputStream *s = file.GetStream(); char *src; wxString doc; if (s == NULL) return wxEmptyString; - src = new char[s -> StreamSize()+1]; - src[s -> StreamSize()] = 0; - s -> Read(src, s -> StreamSize()); + src = new char[s -> GetSize()+1]; + src[s -> GetSize()] = 0; + s -> Read(src, s -> GetSize()); doc = src; delete [] src; return doc; } - virtual bool CanRead(const wxFSFile& file) + virtual bool CanRead(const wxFSFile& file) const { wxString filename = file.GetLocation(); if(filename.Length() >= 5 && @@ -217,7 +220,7 @@ wxHelpFrame::~wxHelpFrame() } void -wxHelpFrame::OnClose(wxCloseEvent &ev) +wxHelpFrame::OnClose(wxCloseEvent &WXUNUSED(ev)) { wxASSERT(m_controller); m_controller->m_Frame = NULL; @@ -293,14 +296,15 @@ wxHelpControllerHtml::SetFrameParameters(const wxString &title, m_NewFrameEachTime = newFrame; } -void -wxHelpControllerHtml::GetFrameParameters(wxSize *size = NULL, - wxPoint *pos = NULL, - bool *newframe = NULL) +wxFrame * +wxHelpControllerHtml::GetFrameParameters(wxSize *size, + wxPoint *pos, + bool *newframe) { if(size) *size = m_FrameSize; if(pos) *pos = m_FramePosition; if(newframe) *newframe = m_NewFrameEachTime; + return m_Frame; } #endif // wxUSE_HTML