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

Side by Side Diff: chrome/browser/history/history.cc

Issue 113591: Fix Acid3 Test 48: LINKTEST, Chromium side.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: Made waiting more bearable. Created 11 years, 5 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
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 // The history system runs on a background thread so that potentially slow 5 // The history system runs on a background thread so that potentially slow
6 // database operations don't delay the browser. This backend processing is 6 // database operations don't delay the browser. This backend processing is
7 // represented by HistoryBackend. The HistoryService's job is to dispatch to 7 // represented by HistoryBackend. The HistoryService's job is to dispatch to
8 // that thread. 8 // that thread.
9 // 9 //
10 // Main thread History thread 10 // Main thread History thread
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 const GURL& referrer, 266 const GURL& referrer,
267 PageTransition::Type transition, 267 PageTransition::Type transition,
268 const history::RedirectList& redirects, 268 const history::RedirectList& redirects,
269 bool did_replace_entry) { 269 bool did_replace_entry) {
270 DCHECK(history_backend_) << "History service being called after cleanup"; 270 DCHECK(history_backend_) << "History service being called after cleanup";
271 271
272 // Filter out unwanted URLs. We don't add auto-subframe URLs. They are a 272 // Filter out unwanted URLs. We don't add auto-subframe URLs. They are a
273 // large part of history (think iframes for ads) and we never display them in 273 // large part of history (think iframes for ads) and we never display them in
274 // history UI. We will still add manual subframes, which are ones the user 274 // history UI. We will still add manual subframes, which are ones the user
275 // has clicked on to get. 275 // has clicked on to get.
276 if (!CanAddURL(url) || PageTransition::StripQualifier(transition) == 276 if (!CanAddURL(url))
277 PageTransition::AUTO_SUBFRAME)
278 return; 277 return;
279 278
280 // Add link & all redirects to visited link list. 279 // Add link & all redirects to visited link list.
281 VisitedLinkMaster* visited_links; 280 VisitedLinkMaster* visited_links;
282 if (profile_ && (visited_links = profile_->GetVisitedLinkMaster())) { 281 if (profile_ && (visited_links = profile_->GetVisitedLinkMaster())) {
283 visited_links->AddURL(url); 282 visited_links->AddURL(url);
284 283
285 if (!redirects.empty()) { 284 if (!redirects.empty()) {
286 // We should not be asked to add a page in the middle of a redirect chain. 285 // We should not be asked to add a page in the middle of a redirect chain.
287 DCHECK(redirects[redirects.size() - 1] == url); 286 DCHECK(redirects[redirects.size() - 1] == url);
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 NotificationService::current()->Notify(type, source, det); 676 NotificationService::current()->Notify(type, source, det);
678 } 677 }
679 678
680 void HistoryService::OnDBLoaded() { 679 void HistoryService::OnDBLoaded() {
681 LOG(INFO) << "History backend finished loading"; 680 LOG(INFO) << "History backend finished loading";
682 backend_loaded_ = true; 681 backend_loaded_ = true;
683 NotificationService::current()->Notify(NotificationType::HISTORY_LOADED, 682 NotificationService::current()->Notify(NotificationType::HISTORY_LOADED,
684 Source<Profile>(profile_), 683 Source<Profile>(profile_),
685 Details<HistoryService>(this)); 684 Details<HistoryService>(this));
686 } 685 }
OLDNEW
« no previous file with comments | « chrome/browser/history/expire_history_backend_unittest.cc ('k') | chrome/browser/history/history_database.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698