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

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

Issue 375613002: Bypass the favicon_service when importing favicons. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed friend. Created 6 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) 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 #ifndef CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_ 5 #ifndef CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
6 #define CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_ 6 #define CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 base::Time end_time, 372 base::Time end_time,
373 const base::Closure& callback, 373 const base::Closure& callback,
374 base::CancelableTaskTracker* tracker); 374 base::CancelableTaskTracker* tracker);
375 375
376 // Processes the given |delete_directive| and sends it to the 376 // Processes the given |delete_directive| and sends it to the
377 // SyncChangeProcessor (if it exists). Returns any error resulting 377 // SyncChangeProcessor (if it exists). Returns any error resulting
378 // from sending the delete directive to sync. 378 // from sending the delete directive to sync.
379 syncer::SyncError ProcessLocalDeleteDirective( 379 syncer::SyncError ProcessLocalDeleteDirective(
380 const sync_pb::HistoryDeleteDirectiveSpecifics& delete_directive); 380 const sync_pb::HistoryDeleteDirectiveSpecifics& delete_directive);
381 381
382 // Importer ------------------------------------------------------------------
383
384 // Used by the ProfileWriter for importing many favicons for many pages at
385 // once. The pages must exist, any favicon sets for unknown pages will be
386 // discarded. Existing favicons will not be overwritten.
387 void SetImportedFavicons(
388 const std::vector<ImportedFaviconUsage>& favicon_usage);
389
382 // Downloads ----------------------------------------------------------------- 390 // Downloads -----------------------------------------------------------------
383 391
384 // Implemented by the caller of 'CreateDownload' below, and is called when the 392 // Implemented by the caller of 'CreateDownload' below, and is called when the
385 // history service has created a new entry for a download in the history db. 393 // history service has created a new entry for a download in the history db.
386 typedef base::Callback<void(bool)> DownloadCreateCallback; 394 typedef base::Callback<void(bool)> DownloadCreateCallback;
387 395
388 // Begins a history request to create a new row for a download. 'info' 396 // Begins a history request to create a new row for a download. 'info'
389 // contains all the download's creation state, and 'callback' runs when the 397 // contains all the download's creation state, and 'callback' runs when the
390 // history service request is complete. The callback is called on the thread 398 // history service request is complete. The callback is called on the thread
391 // that calls CreateDownload(). 399 // that calls CreateDownload().
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 favicon_bitmap_data); 723 favicon_bitmap_data);
716 724
717 // Used by the FaviconService to mark the favicon for the page as being out 725 // Used by the FaviconService to mark the favicon for the page as being out
718 // of date. 726 // of date.
719 void SetFaviconsOutOfDateForPage(const GURL& page_url); 727 void SetFaviconsOutOfDateForPage(const GURL& page_url);
720 728
721 // Used by the FaviconService to clone favicons from one page to another, 729 // Used by the FaviconService to clone favicons from one page to another,
722 // provided that other page does not already have favicons. 730 // provided that other page does not already have favicons.
723 void CloneFavicons(const GURL& old_page_url, const GURL& new_page_url); 731 void CloneFavicons(const GURL& old_page_url, const GURL& new_page_url);
724 732
725 // Used by the FaviconService for importing many favicons for many pages at
726 // once. The pages must exist, any favicon sets for unknown pages will be
727 // discarded. Existing favicons will not be overwritten.
728 void SetImportedFavicons(
729 const std::vector<ImportedFaviconUsage>& favicon_usage);
730
731 // Sets the in-memory URL database. This is called by the backend once the 733 // Sets the in-memory URL database. This is called by the backend once the
732 // database is loaded to make it available. 734 // database is loaded to make it available.
733 void SetInMemoryBackend( 735 void SetInMemoryBackend(
734 scoped_ptr<history::InMemoryHistoryBackend> mem_backend); 736 scoped_ptr<history::InMemoryHistoryBackend> mem_backend);
735 737
736 // Called by our BackendDelegate when there is a problem reading the database. 738 // Called by our BackendDelegate when there is a problem reading the database.
737 void NotifyProfileError(sql::InitStatus init_status); 739 void NotifyProfileError(sql::InitStatus init_status);
738 740
739 // Call to schedule a given task for running on the history thread with the 741 // Call to schedule a given task for running on the history thread with the
740 // specified priority. The task will have ownership taken. 742 // specified priority. The task will have ownership taken.
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
976 scoped_ptr<history::InMemoryURLIndex> in_memory_url_index_; 978 scoped_ptr<history::InMemoryURLIndex> in_memory_url_index_;
977 979
978 ObserverList<history::VisitDatabaseObserver> visit_database_observers_; 980 ObserverList<history::VisitDatabaseObserver> visit_database_observers_;
979 981
980 history::DeleteDirectiveHandler delete_directive_handler_; 982 history::DeleteDirectiveHandler delete_directive_handler_;
981 983
982 DISALLOW_COPY_AND_ASSIGN(HistoryService); 984 DISALLOW_COPY_AND_ASSIGN(HistoryService);
983 }; 985 };
984 986
985 #endif // CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_ 987 #endif // CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698