From 0524bbc1a60489af8da90c8f3e52acd3bd2a5635 Mon Sep 17 00:00:00 2001 From: David Rosca Date: Sat, 12 Aug 2017 15:10:39 +0200 Subject: [PATCH] LocationCompleter: Don't allow to delete search/visit completion item --- src/lib/navigation/completer/locationcompleterview.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/navigation/completer/locationcompleterview.cpp b/src/lib/navigation/completer/locationcompleterview.cpp index 549cf67c8..5a242b6ec 100644 --- a/src/lib/navigation/completer/locationcompleterview.cpp +++ b/src/lib/navigation/completer/locationcompleterview.cpp @@ -163,7 +163,7 @@ bool LocationCompleterView::eventFilter(QObject* object, QEvent* event) return true; case Qt::Key_Delete: - if (viewport()->rect().contains(visualRect(idx))) { + if (idx != visitSearchIdx && viewport()->rect().contains(visualRect(idx))) { emit indexDeleteRequested(idx); return true; }