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

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

Issue 325443002: Move about://-related constants from //content to //url (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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
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 // 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 975 matching lines...) Expand 10 before | Expand all | Expand 10 after
986 url.SchemeIs(content::kChromeDevToolsScheme) || 986 url.SchemeIs(content::kChromeDevToolsScheme) ||
987 url.SchemeIs(content::kChromeUIScheme) || 987 url.SchemeIs(content::kChromeUIScheme) ||
988 url.SchemeIs(content::kViewSourceScheme) || 988 url.SchemeIs(content::kViewSourceScheme) ||
989 url.SchemeIs(chrome::kChromeNativeScheme) || 989 url.SchemeIs(chrome::kChromeNativeScheme) ||
990 url.SchemeIs(chrome::kChromeSearchScheme) || 990 url.SchemeIs(chrome::kChromeSearchScheme) ||
991 url.SchemeIs(chrome::kDomDistillerScheme)) 991 url.SchemeIs(chrome::kDomDistillerScheme))
992 return false; 992 return false;
993 993
994 // Allow all about: and chrome: URLs except about:blank, since the user may 994 // Allow all about: and chrome: URLs except about:blank, since the user may
995 // like to see "chrome://memory/", etc. in their history and autocomplete. 995 // like to see "chrome://memory/", etc. in their history and autocomplete.
996 if (url == GURL(content::kAboutBlankURL)) 996 if (url == GURL(url::kAboutBlankURL))
997 return false; 997 return false;
998 998
999 return true; 999 return true;
1000 } 1000 }
1001 1001
1002 base::WeakPtr<HistoryService> HistoryService::AsWeakPtr() { 1002 base::WeakPtr<HistoryService> HistoryService::AsWeakPtr() {
1003 DCHECK(thread_checker_.CalledOnValidThread()); 1003 DCHECK(thread_checker_.CalledOnValidThread());
1004 return weak_ptr_factory_.GetWeakPtr(); 1004 return weak_ptr_factory_.GetWeakPtr();
1005 } 1005 }
1006 1006
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
1189 DCHECK(thread_checker_.CalledOnValidThread()); 1189 DCHECK(thread_checker_.CalledOnValidThread());
1190 visit_database_observers_.RemoveObserver(observer); 1190 visit_database_observers_.RemoveObserver(observer);
1191 } 1191 }
1192 1192
1193 void HistoryService::NotifyVisitDBObserversOnAddVisit( 1193 void HistoryService::NotifyVisitDBObserversOnAddVisit(
1194 const history::BriefVisitInfo& info) { 1194 const history::BriefVisitInfo& info) {
1195 DCHECK(thread_checker_.CalledOnValidThread()); 1195 DCHECK(thread_checker_.CalledOnValidThread());
1196 FOR_EACH_OBSERVER(history::VisitDatabaseObserver, visit_database_observers_, 1196 FOR_EACH_OBSERVER(history::VisitDatabaseObserver, visit_database_observers_,
1197 OnAddVisit(info)); 1197 OnAddVisit(info));
1198 } 1198 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698