From 76f9c784e2f850e2a9070eaf93488f7459c461ef Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 19 Jun 2017 18:54:45 +0300 Subject: Use staticbrowserbox in helpwindow. --- src/gui/windows/helpwindow.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/gui/windows/helpwindow.cpp') diff --git a/src/gui/windows/helpwindow.cpp b/src/gui/windows/helpwindow.cpp index 85a14594d..ce121a98f 100644 --- a/src/gui/windows/helpwindow.cpp +++ b/src/gui/windows/helpwindow.cpp @@ -35,7 +35,7 @@ #include "gui/windows/setupwindow.h" #include "gui/widgets/button.h" -#include "gui/widgets/browserbox.h" +#include "gui/widgets/staticbrowserbox.h" #include "gui/widgets/layout.h" #include "gui/widgets/scrollarea.h" @@ -58,7 +58,7 @@ HelpWindow::HelpWindow() : ActionListener(), // TRANSLATORS: help window. button. mDYKButton(new Button(this, _("Did you know..."), "DYK", this)), - mBrowserBox(new BrowserBox(this, BrowserBoxMode::AUTO_SIZE, Opaque_true, + mBrowserBox(new StaticBrowserBox(this, Opaque_true, "browserbox.xml")), mScrollArea(new ScrollArea(this, mBrowserBox, Opaque_true, "help_background.xml")), @@ -128,6 +128,7 @@ void HelpWindow::loadHelp(const std::string &helpFile) loadFile(helpFile); loadFile("footer"); mScrollArea->setVerticalScrollAmount(0); + mBrowserBox->updateHeight(); setVisible(Visible_true); } @@ -138,6 +139,7 @@ void HelpWindow::loadHelpSimple(const std::string &helpFile) mBrowserBox->clearRows(); loadFile(helpFile); mScrollArea->setVerticalScrollAmount(0); + mBrowserBox->updateHeight(); setVisible(Visible_true); } @@ -209,6 +211,7 @@ void HelpWindow::search(const std::string &text0) } loadFile("footer"); mScrollArea->setVerticalScrollAmount(0); + mBrowserBox->updateHeight(); setVisible(Visible_true); } } -- cgit v1.2.3-70-g09d2