Commit 48e29eed authored by Waqar Ahmed's avatar Waqar Ahmed
Browse files

Select first item in quick-open if only one item in list

BUG: 422751
parent d28c44a8
...@@ -122,7 +122,7 @@ bool KateQuickOpen::eventFilter(QObject *obj, QEvent *event) ...@@ -122,7 +122,7 @@ bool KateQuickOpen::eventFilter(QObject *obj, QEvent *event)
void KateQuickOpen::reselectFirst() void KateQuickOpen::reselectFirst()
{ {
int first = 0; int first = 0;
if (m_mainWindow->viewManager()->sortedViews().size() > 1) if (m_mainWindow->viewManager()->sortedViews().size() > 1 && m_model->rowCount() > 1)
first = 1; first = 1;
QModelIndex index = m_model->index(first, 0); QModelIndex index = m_model->index(first, 0);
......
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