forked from qt-creator/qt-creator
Terminal: Fix case insensitive search
Case sensitive / case insensitive were set the wrong way around. Change-Id: I7ed689684972aae5f6b1af2f35d9fd72d2df71e9 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -99,12 +99,13 @@ QList<SearchHit> TerminalSearch::search()
|
||||
|
||||
std::function<bool(char32_t, char32_t)> compare;
|
||||
|
||||
if (m_findFlags.testFlag(Core::FindFlag::FindCaseSensitively))
|
||||
if (m_findFlags.testFlag(Core::FindFlag::FindCaseSensitively)) {
|
||||
compare = [](char32_t a, char32_t b) { return a == b || isSpace(a, b); };
|
||||
} else {
|
||||
compare = [](char32_t a, char32_t b) {
|
||||
return std::tolower(a) == std::tolower(b) || isSpace(a, b);
|
||||
};
|
||||
else
|
||||
compare = [](char32_t a, char32_t b) { return a == b || isSpace(a, b); };
|
||||
}
|
||||
|
||||
if (!m_currentSearchString.isEmpty()) {
|
||||
const QList<uint> asUcs4 = m_currentSearchString.toUcs4();
|
||||
|
||||
Reference in New Issue
Block a user