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

Unified Diff: chrome/browser/bookmarks/bookmark_model.cc

Issue 12952005: Delay bookmarks load while the profile is loading. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add startup_task_runner_service. Created 7 years, 9 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/bookmarks/bookmark_model.cc
diff --git a/chrome/browser/bookmarks/bookmark_model.cc b/chrome/browser/bookmarks/bookmark_model.cc
index 52533b4c2be72210353f7fc5c17cb7d33441eae5..0e392c8550775dceea184f82d98804841b1f5990 100644
--- a/chrome/browser/bookmarks/bookmark_model.cc
+++ b/chrome/browser/bookmarks/bookmark_model.cc
@@ -233,7 +233,7 @@ void BookmarkModel::Shutdown() {
loaded_signal_.Signal();
}
-void BookmarkModel::Load() {
+void BookmarkModel::Load(scoped_refptr<base::SequencedTaskRunner> task_runner) {
Miranda Callahan 2013/03/29 14:40:13 Do we really need to pass the task_runner here? No
msarda 2013/03/29 14:46:24 I did that in a local change. However, I understoo
if (store_.get()) {
// If the store is non-null, it means Load was already invoked. Load should
// only be invoked once.
@@ -250,7 +250,7 @@ void BookmarkModel::Load() {
content::Source<Profile>(profile_));
// Load the bookmarks. BookmarkStorage notifies us when done.
- store_ = new BookmarkStorage(profile_, this, profile_->GetIOTaskRunner());
+ store_ = new BookmarkStorage(profile_, this, task_runner);
Miranda Callahan 2013/03/29 14:40:13 see comment on "Load" above.
store_->LoadBookmarks(CreateLoadDetails());
}

Powered by Google App Engine
This is Rietveld 408576698