summaryrefslogtreecommitdiff
path: root/src/urlbar/urlresolver.cpp
diff options
context:
space:
mode:
authorlionelc <lionelc@lionelc.(none)>2010-08-12 18:31:16 +0200
committerlionelc <lionelc@lionelc.(none)>2010-08-12 18:31:16 +0200
commite9d099f4c5efa41fafd16408f13400cb37616f18 (patch)
tree460e901d72921103f6d66e5e4edeb6e233a99969 /src/urlbar/urlresolver.cpp
parentMerge commit 'refs/merge-requests/165' of git://gitorious.org/rekonq/mainline (diff)
downloadrekonq-e9d099f4c5efa41fafd16408f13400cb37616f18.tar.xz
introduce a new SuggestionListItem
introduce an opensearch engine
Diffstat (limited to 'src/urlbar/urlresolver.cpp')
-rw-r--r--src/urlbar/urlresolver.cpp21
1 files changed, 18 insertions, 3 deletions
diff --git a/src/urlbar/urlresolver.cpp b/src/urlbar/urlresolver.cpp
index f0fd257b..157e26a2 100644
--- a/src/urlbar/urlresolver.cpp
+++ b/src/urlbar/urlresolver.cpp
@@ -31,7 +31,7 @@
#include "application.h"
#include "historymanager.h"
#include "bookmarksmanager.h"
-#include "searchengine.h"
+#include "search/searchengine.h"
// KDE Includes
#include <KUriFilter>
@@ -243,11 +243,14 @@ UrlSearchList UrlResolver::orderedSearchItems()
availableEntries -= commonList.count();
}
+
+ UrlSearchList suggestionsList = suggestionResolution();
historyResults = historyList.count();
bookmarksResults = bookmarksList.count();
commonResutls = commonList.count();
-
+ //TODO: count suggestions entries
+
//now fill the list to MAX_ELEMENTS
if(availableEntries > 0)
{
@@ -275,7 +278,7 @@ UrlSearchList UrlResolver::orderedSearchItems()
}
}
- list = list + historyList + commonList + bookmarksList;
+ list = list + historyList + commonList + bookmarksList + suggestionsList;
qWarning() << "orderedSearchItems leave: " << " elapsed: " << myTime.elapsed();
return list;
@@ -343,6 +346,18 @@ UrlSearchList UrlResolver::bookmarksResolution()
}
+// STEP 4 = suggestion completion
+UrlSearchList UrlResolver::suggestionResolution()
+{
+
+ UrlSearchList list;
+ UrlSearchItem gItem(UrlSearchItem::Suggestion, "a", "a");
+ list << gItem;
+
+ return list;
+}
+
+
UrlSearchItem UrlResolver::privilegedItem(UrlSearchList* list)
{
UrlSearchItem item;