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

Unified Diff: chrome/browser/history/android/android_provider_backend.cc

Issue 10825147: Made BookmarkService::GetBookmarks return both urls and title. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync again again Created 8 years, 4 months 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
Index: chrome/browser/history/android/android_provider_backend.cc
diff --git a/chrome/browser/history/android/android_provider_backend.cc b/chrome/browser/history/android/android_provider_backend.cc
index b2243318fb2db66c6051b9112de6174d7ff93f25..9f2d9255e489dd7e1ef01527f5231f564ad7ccc1 100644
--- a/chrome/browser/history/android/android_provider_backend.cc
+++ b/chrome/browser/history/android/android_provider_backend.cc
@@ -749,16 +749,16 @@ bool AndroidProviderBackend::UpdateBookmarks() {
}
bookmark_service_->BlockTillLoaded();
- std::vector<GURL> bookmark_urls;
- bookmark_service_->GetBookmarks(&bookmark_urls);
+ std::vector<BookmarkService::URLAndTitle> bookmarks;
+ bookmark_service_->GetBookmarks(&bookmarks);
- if (bookmark_urls.empty())
+ if (bookmarks.empty())
return true;
std::vector<URLID> url_ids;
- for (std::vector<GURL>::const_iterator i = bookmark_urls.begin();
- i != bookmark_urls.end(); ++i) {
- URLID url_id = history_db_->GetRowForURL(*i, NULL);
+ for (std::vector<BookmarkService::URLAndTitle>::const_iterator i =
+ bookmarks.begin(); i != bookmarks.end(); ++i) {
+ URLID url_id = history_db_->GetRowForURL(i->url, NULL);
if (url_id == 0)
// TODO(michaelbai): Add a row to url and android_url table as the
// bookmark could be added manually by user or insertted by sync.
« no previous file with comments | « chrome/browser/bookmarks/bookmark_service.h ('k') | chrome/browser/history/android/bookmark_model_sql_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698