Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3300)

Unified Diff: chrome/browser/android/bookmarks/bookmarks_bridge.cc

Issue 699963002: [Android] Change bookmark search to use prefix matching. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/bookmarks/bookmarks_bridge.cc
diff --git a/chrome/browser/android/bookmarks/bookmarks_bridge.cc b/chrome/browser/android/bookmarks/bookmarks_bridge.cc
index cb9052f05ddbc31cfa50e99cee4c9a33f12a83cc..3ca45ba0cbe297a77e64a05773b4d01394dda4d3 100644
--- a/chrome/browser/android/bookmarks/bookmarks_bridge.cc
+++ b/chrome/browser/android/bookmarks/bookmarks_bridge.cc
@@ -25,6 +25,7 @@
#include "components/bookmarks/browser/bookmark_utils.h"
#include "components/bookmarks/browser/scoped_group_bookmark_actions.h"
#include "components/bookmarks/common/android/bookmark_type.h"
+#include "components/query_parser/query_parser.h"
#include "components/signin/core/browser/signin_manager.h"
#include "content/public/browser/browser_thread.h"
#include "jni/BookmarksBridge_jni.h"
@@ -665,6 +666,7 @@ void BookmarksBridge::SearchBookmarks(JNIEnv* env,
bookmark_model_->GetBookmarksMatching(
base::android::ConvertJavaStringToUTF16(env, j_query),
max_results,
+ query_parser::MatchingAlgorithm::ALWAYS_PREFIX_SEARCH,
&results);
for (const bookmarks::BookmarkMatch& match : results) {
const BookmarkNode* node = match.node;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698