diff --git a/src/plugins/find/findtoolbar.cpp b/src/plugins/find/findtoolbar.cpp index 6a28c4d93c6b92e228172934dcdd473b90ae8d97..f87d9bf9e0587896f38e3f13ae1a987b182c0230 100644 --- a/src/plugins/find/findtoolbar.cpp +++ b/src/plugins/find/findtoolbar.cpp @@ -481,3 +481,16 @@ void FindToolBar::openFind() m_currentDocumentFind->highlightAll(getFindText(), m_plugin->findFlags()); selectFindText(); } + + +bool FindToolBar::focusNextPrevChild(bool next) +{ + // close tab order change + if (next && m_ui.replaceAllButton->hasFocus()) + m_ui.findEdit->setFocus(Qt::TabFocusReason); + else if (!next && m_ui.findEdit->hasFocus()) + m_ui.replaceAllButton->setFocus(Qt::TabFocusReason); + else + return QToolBar::focusNextPrevChild(next); + return true; +} diff --git a/src/plugins/find/findtoolbar.h b/src/plugins/find/findtoolbar.h index 790a1e03002ed920ae3b4d5a9f21659e4760afcd..4eeb4f8a2dca4a7cb0e858577514a747dd3be4e1 100644 --- a/src/plugins/find/findtoolbar.h +++ b/src/plugins/find/findtoolbar.h @@ -79,6 +79,9 @@ private slots: void updateActions(); void findFlagsChanged(); +protected: + bool focusNextPrevChild(bool next); + private: bool setFocusToCurrentFindSupport();