From f9781fb4b7d4c09b71188b43848095a1415a4f1e Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Sun, 25 Nov 2012 12:23:54 +0100 Subject: Improve suggestions, step 2 Every change here is given to trade-off suggestions performance (p) and relevancy (r). - just check bookmarks for relevance if no history entries found (p) - remove bookmarks item duplicates from history (r) - just do it is user typed more than 1 char (p) - order history entries just if user typed more than 1 char (p) - (reverse) order by visit count (most visited first) (r) --- src/history/historymanager.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/history/historymanager.h') diff --git a/src/history/historymanager.h b/src/history/historymanager.h index 96de8ab8..a0c3a5eb 100644 --- a/src/history/historymanager.h +++ b/src/history/historymanager.h @@ -86,7 +86,8 @@ public: // history is sorted in reverse inline bool operator <(const HistoryItem &other) const { - return lastDateTimeVisit > other.lastDateTimeVisit; + return visitCount > other.visitCount; +// return lastDateTimeVisit > other.lastDateTimeVisit; } QString title; -- cgit v1.2.1