diff options
Diffstat (limited to 'src/gui/helpwindow.cpp')
-rw-r--r-- | src/gui/helpwindow.cpp | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/gui/helpwindow.cpp b/src/gui/helpwindow.cpp index 1dfc109e..7bb31188 100644 --- a/src/gui/helpwindow.cpp +++ b/src/gui/helpwindow.cpp @@ -47,6 +47,7 @@ HelpWindow::HelpWindow(): setDefaultSize(500, 400, ImageRect::CENTER); mBrowserBox = new BrowserBox; + mBrowserBox->setFrameSize(4); mScrollArea = new ScrollArea(mBrowserBox); auto *okButton = new Button(_("Close"), "close", this); @@ -65,9 +66,7 @@ HelpWindow::HelpWindow(): void HelpWindow::action(const gcn::ActionEvent &event) { if (event.getId() == "close") - { setVisible(false); - } } void HelpWindow::handleLink(const std::string &link) @@ -93,11 +92,8 @@ void HelpWindow::loadFile(const std::string &file) std::string helpPath = branding.getStringValue("helpPath"); if (helpPath.empty()) helpPath = paths.getStringValue("help"); - std::vector<std::string> lines = - resman->loadTextFile(helpPath + file + ".txt"); - for (const auto &line : lines) - { + const auto lines = resman->loadTextFile(helpPath + file + ".txt"); + for (auto &line : lines) mBrowserBox->addRow(line); - } } |