libs: match the applets case-insensitively in Plasma::WidgetExplorerPrivate::filterApplets()

note that the old implementation was not matching the plugin name, only the
applet name and comment. could match other applet info but that would be
greedy

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2023-09-12 02:43:00 +03:00
parent 8609a4ae20
commit b1aed2bbf4

View file

@ -446,7 +446,10 @@ void WidgetExplorerPrivate::filterApplets(const QString &text)
if (!text.isEmpty()) {
const QString appletName = appletInfo.name();
const QString appletComment = appletInfo.comment();
if (appletName.contains(text) || appletPluginName.contains(text) || appletComment.contains(text)) {
if (appletName.contains(text, Qt::CaseInsensitive)
|| appletPluginName.contains(text, Qt::CaseInsensitive)
|| appletComment.contains(text, Qt::CaseInsensitive))
{
appletFrame->setVisible(true);
hasapplets = true;
}