From e73ef677cae51b6e775da1ad6ac3ece723de1cb4 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 25 Dec 2012 17:09:41 +0300 Subject: Close help window if it already opened and player clicked on "HLP" button. --- src/gui/windowmenu.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/gui/windowmenu.cpp b/src/gui/windowmenu.cpp index 56fedb3e8..728718acc 100644 --- a/src/gui/windowmenu.cpp +++ b/src/gui/windowmenu.cpp @@ -225,7 +225,12 @@ void WindowMenu::action(const gcn::ActionEvent &event) if (window) { if (window == helpWindow) - helpWindow->loadHelp("index"); + { + if (window->isVisible()) + window->setVisible(false); + else + helpWindow->loadHelp("index"); + } else window->setVisible(!window->isVisible()); if (window->isVisible()) -- cgit v1.2.3-70-g09d2