Commit c29a7bdc authored by Kåre Särs's avatar Kåre Särs

S&R: Make sure the tree widget also gets the focus.

parent a56727c1
......@@ -162,19 +162,28 @@ void KatePluginSearchView::nextFocus(QWidget *currentWidget, bool *found, bool n
// we use the object names here because there can be multiple replaceButtons (on multiple result tabs)
if (next) {
if (!m_ui.displayOptions->isChecked() && (currentWidget->objectName() == "tree")) {
if (currentWidget->objectName() == "tree") {
m_ui.newTabButton->setFocus();
*found = true;
return;
}
if (currentWidget == m_ui.displayOptions) {
if ((currentWidget == m_ui.displayOptions) && m_ui.displayOptions->isChecked()) {
m_ui.newTabButton->setFocus();
*found = true;
return;
}
}
else if (currentWidget == m_ui.newTabButton) {
m_ui.displayOptions->setFocus();
if(m_ui.displayOptions->isChecked()) {
m_ui.displayOptions->setFocus();
}
else {
Results *res = qobject_cast<Results *>(m_ui.resultTabWidget->currentWidget());
if (!res) {
return;
}
res->tree->setFocus();
}
*found = true;
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment