X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/89de9af3cbe9ddc877594e05380f0e30428677f1..0ddea946963af702917b80861d63544dda0eb334:/src/html/htmlwin.cpp?ds=sidebyside diff --git a/src/html/htmlwin.cpp b/src/html/htmlwin.cpp index 962fa16d1e..e8f394324c 100644 --- a/src/html/htmlwin.cpp +++ b/src/html/htmlwin.cpp @@ -261,7 +261,7 @@ void wxHtmlWindow::CreateLayout() if (!m_Cell) return; if (m_Style == wxHW_SCROLLBAR_NEVER) { - SetScrollbars(1, 1, 0, 0); // always off + SetScrollbars(wxHTML_SCROLL_STEP, 1, m_Cell -> GetWidth() / wxHTML_SCROLL_STEP, 0); // always off GetClientSize(&ClientWidth, &ClientHeight); m_Cell -> Layout(ClientWidth); } @@ -270,7 +270,7 @@ void wxHtmlWindow::CreateLayout() GetClientSize(&ClientWidth, &ClientHeight); #ifndef __WXMSW__ // VS : this looks extremely ugly under windoze, better fix needed! - SetScrollbars(1, 1, 0, ClientHeight * 2); // always on + SetScrollbars(wxHTML_SCROLL_STEP, 1, m_Cell -> GetWidth() / wxHTML_SCROLL_STEP, ClientHeight * 2); // always on #endif GetClientSize(&ClientWidth, &ClientHeight); m_Cell -> Layout(ClientWidth); @@ -281,7 +281,7 @@ void wxHtmlWindow::CreateLayout() /*cheat: top-level frag is always container*/); } else { /* we fit into window, no need for scrollbars */ - SetScrollbars(1, 1, 0, 0); // disable... + SetScrollbars(wxHTML_SCROLL_STEP, 1, m_Cell -> GetWidth() / wxHTML_SCROLL_STEP, 0); // disable... GetClientSize(&ClientWidth, &ClientHeight); m_Cell -> Layout(ClientWidth); // ...and relayout } @@ -361,9 +361,9 @@ bool wxHtmlWindow::HistoryBack() if (a == wxEmptyString) LoadPage(l); else LoadPage(l + "#" + a); m_HistoryOn = TRUE; - Scroll(0, m_History[m_HistoryPos].GetPos()); -// wxYield(); + wxYield(); m_tmpCanDrawLocks--; + Scroll(0, m_History[m_HistoryPos].GetPos()); Refresh(); return TRUE; } @@ -387,9 +387,9 @@ bool wxHtmlWindow::HistoryForward() if (a == wxEmptyString) LoadPage(l); else LoadPage(l + "#" + a); m_HistoryOn = TRUE; - Scroll(0, m_History[m_HistoryPos].GetPos()); -// wxYield(); + wxYield(); m_tmpCanDrawLocks--; + Scroll(0, m_History[m_HistoryPos].GetPos()); Refresh(); return TRUE; } @@ -586,14 +586,15 @@ IMPLEMENT_DYNAMIC_CLASS(wxHtmlWinModule, wxModule) ///// default mod handlers are forced there: -FORCE_LINK(mod_layout) -FORCE_LINK(mod_fonts) -FORCE_LINK(mod_image) -FORCE_LINK(mod_list) -FORCE_LINK(mod_pre) -FORCE_LINK(mod_hline) -FORCE_LINK(mod_links) -FORCE_LINK(mod_tables) +FORCE_LINK(m_layout) +FORCE_LINK(m_fonts) +FORCE_LINK(m_image) +FORCE_LINK(m_list) +FORCE_LINK(m_dflist) +FORCE_LINK(m_pre) +FORCE_LINK(m_hline) +FORCE_LINK(m_links) +FORCE_LINK(m_tables) #endif