GUI: don't filter symbol list when not necessary
This commit is contained in:
parent
62cd2bb915
commit
408b6eeff9
|
@ -163,13 +163,6 @@ void SearchListView::searchTextChanged(const QString & text)
|
||||||
mAbstractSearchList->list()->hide();
|
mAbstractSearchList->list()->hide();
|
||||||
mAbstractSearchList->searchList()->show();
|
mAbstractSearchList->searchList()->show();
|
||||||
mCurList = mAbstractSearchList->searchList();
|
mCurList = mAbstractSearchList->searchList();
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mAbstractSearchList->searchList()->hide();
|
|
||||||
mAbstractSearchList->list()->show();
|
|
||||||
mCurList = mAbstractSearchList->list();
|
|
||||||
}
|
|
||||||
|
|
||||||
// filter the list
|
// filter the list
|
||||||
auto filterType = AbstractSearchList::FilterContainsTextCaseInsensitive;
|
auto filterType = AbstractSearchList::FilterContainsTextCaseInsensitive;
|
||||||
|
@ -182,7 +175,14 @@ void SearchListView::searchTextChanged(const QString & text)
|
||||||
filterType = AbstractSearchList::FilterRegexCaseSensitive;
|
filterType = AbstractSearchList::FilterRegexCaseSensitive;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
mAbstractSearchList->filter(text, filterType, mSearchStartCol); // TODO: do not filter if text is empty
|
mAbstractSearchList->filter(text, filterType, mSearchStartCol);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
mAbstractSearchList->searchList()->hide();
|
||||||
|
mAbstractSearchList->list()->show();
|
||||||
|
mCurList = mAbstractSearchList->list();
|
||||||
|
}
|
||||||
|
|
||||||
// attempt to restore previous selection
|
// attempt to restore previous selection
|
||||||
bool hasSetSingleSelection = false;
|
bool hasSetSingleSelection = false;
|
||||||
|
|
Loading…
Reference in New Issue