forked from qt-creator/qt-creator
Introduce and use Utils::stripAccelerator
Change-Id: I8c37728ca5de20e2b68e6d0ac7fc120baa696040 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
committed by
Orgad Shaneh
parent
510a00ea35
commit
c841dc551c
@@ -28,6 +28,8 @@
|
||||
|
||||
#include <coreplugin/icontext.h>
|
||||
|
||||
#include <utils/stringutils.h>
|
||||
|
||||
#include <QDesignerOptionsPageInterface>
|
||||
#include <QCoreApplication>
|
||||
|
||||
@@ -116,7 +118,7 @@ bool SettingsPageProvider::matches(const QString &searchKeyWord) const
|
||||
if (m_keywords.isEmpty()) {
|
||||
m_keywords.reserve(itemCount);
|
||||
for (size_t i = 0; i < itemCount; ++i)
|
||||
m_keywords << QCoreApplication::translate(uitext[i].context, uitext[i].value).remove(QLatin1Char('&'));
|
||||
m_keywords << Utils::stripAccelerator(QCoreApplication::translate(uitext[i].context, uitext[i].value));
|
||||
}
|
||||
foreach (const QString &key, m_keywords) {
|
||||
if (key.contains(searchKeyWord, Qt::CaseInsensitive))
|
||||
|
||||
Reference in New Issue
Block a user