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

Side by Side Diff: chrome/test/base/testing_profile.cc

Issue 184663002: Omnibox: Make URLs of Bookmarks Searchable (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix ALL_MATCHES (in response to recent changes) Created 6 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/bookmarks/bookmark_ui_utils_unittest.cc ('k') | components/bookmarks.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/test/base/testing_profile.h" 5 #include "chrome/test/base/testing_profile.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 8
9 #include "base/base_paths.h" 9 #include "base/base_paths.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 // TopSitesImpl::Shutdown schedules some tasks (from TopSitesBackend) that 487 // TopSitesImpl::Shutdown schedules some tasks (from TopSitesBackend) that
488 // need to be run to properly shutdown. Run all pending tasks now. This is 488 // need to be run to properly shutdown. Run all pending tasks now. This is
489 // normally handled by browser_process shutdown. 489 // normally handled by browser_process shutdown.
490 if (base::MessageLoop::current()) 490 if (base::MessageLoop::current())
491 base::MessageLoop::current()->RunUntilIdle(); 491 base::MessageLoop::current()->RunUntilIdle();
492 } 492 }
493 } 493 }
494 494
495 static KeyedService* BuildBookmarkModel(content::BrowserContext* context) { 495 static KeyedService* BuildBookmarkModel(content::BrowserContext* context) {
496 Profile* profile = static_cast<Profile*>(context); 496 Profile* profile = static_cast<Profile*>(context);
497 BookmarkModel* bookmark_model = new BookmarkModel(profile); 497 BookmarkModel* bookmark_model = new BookmarkModel(profile, false);
498 bookmark_model->Load(profile->GetIOTaskRunner()); 498 bookmark_model->Load(profile->GetIOTaskRunner());
499 return bookmark_model; 499 return bookmark_model;
500 } 500 }
501 501
502 void TestingProfile::CreateBookmarkModel(bool delete_file) { 502 void TestingProfile::CreateBookmarkModel(bool delete_file) {
503 if (delete_file) { 503 if (delete_file) {
504 base::FilePath path = GetPath().Append(bookmarks::kBookmarksFileName); 504 base::FilePath path = GetPath().Append(bookmarks::kBookmarksFileName);
505 base::DeleteFile(path, false); 505 base::DeleteFile(path, false);
506 } 506 }
507 // This will create a bookmark model. 507 // This will create a bookmark model.
(...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after
963 path_, 963 path_,
964 delegate_, 964 delegate_,
965 extension_policy_, 965 extension_policy_,
966 pref_service_.Pass(), 966 pref_service_.Pass(),
967 incognito_, 967 incognito_,
968 guest_session_, 968 guest_session_,
969 managed_user_id_, 969 managed_user_id_,
970 policy_service_.Pass(), 970 policy_service_.Pass(),
971 testing_factories_)); 971 testing_factories_));
972 } 972 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/bookmarks/bookmark_ui_utils_unittest.cc ('k') | components/bookmarks.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698