summaryrefslogtreecommitdiff
path: root/src/actions
diff options
context:
space:
mode:
Diffstat (limited to 'src/actions')
-rw-r--r--src/actions/windows.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/actions/windows.cpp b/src/actions/windows.cpp
index 7e5b31858..f2fcfa85a 100644
--- a/src/actions/windows.cpp
+++ b/src/actions/windows.cpp
@@ -67,6 +67,7 @@
#include "gui/windows/updaterwindow.h"
#include "gui/widgets/tabs/chattab.h"
+#include "gui/widgets/tabs/chattabtype.h"
#include "render/graphics.h"
@@ -132,7 +133,19 @@ static bool showHelpPage(const std::string &page, const bool showHide)
impHandler0(helpWindowShow)
{
- return showHelpPage("index", true);
+ if (!chatWindow || !chatWindow->isInputFocused())
+ return showHelpPage("index", true);
+ if (!event.tab)
+ return showHelpPage("chatcommands", true);
+ switch (event.tab->getType())
+ {
+ case ChatTabType::PARTY:
+ return showHelpPage("chatparty", true);
+ case ChatTabType::GUILD:
+ return showHelpPage("chatguild", true);
+ default:
+ return showHelpPage("chatcommands", true);
+ }
}
impHandler0(aboutWindowShow)