X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3103e8a97e834e9793f0eb149aa82a99fd64ef9a..3b96fc2f1b64f78bba7c755a5c14f618962f696b:/src/html/helpfrm.cpp diff --git a/src/html/helpfrm.cpp b/src/html/helpfrm.cpp index e1eac661fc..3f403439b6 100644 --- a/src/html/helpfrm.cpp +++ b/src/html/helpfrm.cpp @@ -9,10 +9,6 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "helpfrm.h" -#endif - // For compilers that support precompilation, includes "wx.h" #include "wx/wxprec.h" @@ -258,6 +254,10 @@ void wxHtmlHelpFrame::Init(wxHtmlHelpData* data) m_DataCreated = true; } + m_ContentsPage = 0; + m_IndexPage = 0; + m_SearchPage = 0; + m_ContentsBox = NULL; m_IndexList = NULL; m_IndexButton = NULL; @@ -281,7 +281,7 @@ void wxHtmlHelpFrame::Init(wxHtmlHelpData* data) m_Config = NULL; m_ConfigRoot = wxEmptyString; - m_Cfg.x = m_Cfg.y = -1; + m_Cfg.x = m_Cfg.y = wxDefaultCoord; m_Cfg.w = 700; m_Cfg.h = 480; m_Cfg.sashpos = 240; @@ -530,7 +530,7 @@ bool wxHtmlHelpFrame::Create(wxWindow* parent, wxWindowID id, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER); m_SearchChoice = new wxChoice(dummy, wxID_HTML_SEARCHCHOICE, - wxDefaultPosition, wxSize(125,-1)); + wxDefaultPosition, wxSize(125,wxDefaultCoord)); m_SearchCaseSensitive = new wxCheckBox(dummy, wxID_ANY, _("Case sensitive")); m_SearchWholeWords = new wxCheckBox(dummy, wxID_ANY, _("Whole words only")); m_SearchButton = new wxButton(dummy, wxID_HTML_SEARCHBUTTON, _("Search")); @@ -736,7 +736,7 @@ bool wxHtmlHelpFrame::DisplayContents() m_Cfg.navig_on = true; } - m_NavigNotebook->SetSelection(0); + m_NavigNotebook->SetSelection(m_ContentsPage); if (m_Data->GetBookRecArray().GetCount() > 0) { @@ -762,7 +762,7 @@ bool wxHtmlHelpFrame::DisplayIndex() m_Splitter->SplitVertically(m_NavigPan, m_HtmlWin, m_Cfg.sashpos); } - m_NavigNotebook->SetSelection(1); + m_NavigNotebook->SetSelection(m_IndexPage); if (m_Data->GetBookRecArray().GetCount() > 0) { @@ -1187,7 +1187,7 @@ void wxHtmlHelpFrame::WriteCustomization(wxConfigBase *cfg, const wxString& path -static void SetFontsToHtmlWin(wxHtmlWindow *win, wxString scalf, wxString fixf, int size) +static void SetFontsToHtmlWin(wxHtmlWindow *win, const wxString& scalf, const wxString& fixf, int size) { int f_sizes[7]; f_sizes[0] = int(size * 0.6); @@ -1830,4 +1830,3 @@ BEGIN_EVENT_TABLE(wxHtmlHelpFrame, wxFrame) END_EVENT_TABLE() #endif // wxUSE_WXHTML_HELP -