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

Unified Diff: chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc

Issue 2216713002: Use BookmarkModelFactory::GetForBrowserContext everywhere (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bookmarks
Patch Set: Replace in .mm files Created 4 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
« no previous file with comments | « chrome/browser/ui/webui/browsing_history_handler.cc ('k') | chrome/test/base/testing_profile.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc
diff --git a/chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc b/chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc
index 7f29d6f2a776f3f0cace0e7ab4f2a0c23915331d..28eadd6b7c738207446951ddc8a1f7c31f867428 100644
--- a/chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc
+++ b/chrome/browser/ui/webui/omnibox/omnibox_page_handler.cc
@@ -21,6 +21,7 @@
#include "chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.h"
#include "chrome/browser/bookmarks/bookmark_model_factory.h"
#include "chrome/browser/history/history_service_factory.h"
+#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/search/search.h"
#include "chrome/browser/search_engines/template_url_service_factory.h"
#include "components/bookmarks/browser/bookmark_model.h"
@@ -149,7 +150,8 @@ void OmniboxPageHandler::OnResultChanged(bool default_match_changed) {
controller_->providers());
// Fill AutocompleteMatch::starred.
- BookmarkModel* bookmark_model = BookmarkModelFactory::GetForProfile(profile_);
+ BookmarkModel* bookmark_model =
+ BookmarkModelFactory::GetForBrowserContext(profile_);
if (bookmark_model) {
for (size_t i = 0; i < result->combined_results.size(); ++i) {
result->combined_results[i]->starred = bookmark_model->IsBookmarked(
« no previous file with comments | « chrome/browser/ui/webui/browsing_history_handler.cc ('k') | chrome/test/base/testing_profile.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698