From 212836d56b4c464899be2a6a0edc38581b128b10 Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Fri, 30 May 2014 14:26:59 +0200 Subject: [PATCH] Help: Fix check if help viewer currently has focus. Fixes a little issue that after opening context help, clicking into the context help viewer, and pressing F1, the help viewer would show "No documentation available" instead of opening help mode. Change-Id: I071c92946214680e82b1f2982b62cc909a272ad5 Reviewed-by: Eike Ziller --- src/plugins/help/helpplugin.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/help/helpplugin.cpp b/src/plugins/help/helpplugin.cpp index 0876d5138f9..27268f8fc53 100644 --- a/src/plugins/help/helpplugin.cpp +++ b/src/plugins/help/helpplugin.cpp @@ -875,7 +875,8 @@ void HelpPlugin::activateContext() createRightPaneContextViewer(); RightPanePlaceHolder *placeHolder = RightPanePlaceHolder::current(); - if (placeHolder && m_helpViewerForSideBar->hasFocus()) { + if (placeHolder && qApp->focusWidget() + && qApp->focusWidget() == m_helpViewerForSideBar->focusWidget()) { switchToHelpMode(); return; }