OLD | NEW |
---|---|
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_H_ | 5 #ifndef CHROME_BROWSER_HISTORY_HISTORY_H_ |
6 #define CHROME_BROWSER_HISTORY_HISTORY_H_ | 6 #define CHROME_BROWSER_HISTORY_HISTORY_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 #include <vector> | 10 #include <vector> |
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
636 void OnDBLoaded(); | 636 void OnDBLoaded(); |
637 | 637 |
638 // FavIcon ------------------------------------------------------------------- | 638 // FavIcon ------------------------------------------------------------------- |
639 | 639 |
640 // These favicon methods are exposed to the FaviconService. Instead of calling | 640 // These favicon methods are exposed to the FaviconService. Instead of calling |
641 // these methods directly you should call the respective method on the | 641 // these methods directly you should call the respective method on the |
642 // FaviconService. | 642 // FaviconService. |
643 | 643 |
644 // Used by the FaviconService to get a favicon from the history backend. | 644 // Used by the FaviconService to get a favicon from the history backend. |
645 void GetFavicon(FaviconService::GetFaviconRequest* request, | 645 void GetFavicon(FaviconService::GetFaviconRequest* request, |
646 const GURL& icon_url); | 646 const GURL& icon_url, |
647 history::IconType icon_type); | |
647 | 648 |
648 // Used by the FaviconService to update the favicon mappings on the history | 649 // Used by the FaviconService to update the favicon mappings on the history |
649 // backend. | 650 // backend. |
650 void UpdateFaviconMappingAndFetch(FaviconService::GetFaviconRequest* request, | 651 void UpdateFaviconMappingAndFetch(FaviconService::GetFaviconRequest* request, |
651 const GURL& page_url, | 652 const GURL& page_url, |
652 const GURL& icon_url); | 653 const GURL& icon_url, |
654 history::IconType icon_type); | |
653 | 655 |
654 // Used by the FaviconService to get a favicon from the history backend. | 656 // Used by the FaviconService to get a favicon from the history backend. |
655 void GetFaviconForURL(FaviconService::GetFaviconRequest* request, | 657 void GetFaviconForURL(FaviconService::GetFaviconRequest* request, |
656 const GURL& page_url); | 658 const GURL& page_url, |
659 int icon_type); | |
sky
2011/03/09 21:41:08
icon_types
michaelbai
2011/03/09 23:11:45
Done.
| |
657 | 660 |
658 // Used by the FaviconService to mark the favicon for the page as being out | 661 // Used by the FaviconService to mark the favicon for the page as being out |
659 // of date. | 662 // of date. |
660 void SetFaviconOutOfDateForPage(const GURL& page_url); | 663 void SetFaviconOutOfDateForPage(const GURL& page_url); |
661 | 664 |
662 // Used by the FaviconService for importing many favicons for many pages at | 665 // Used by the FaviconService for importing many favicons for many pages at |
663 // once. The pages must exist, any favicon sets for unknown pages will be | 666 // once. The pages must exist, any favicon sets for unknown pages will be |
664 // discarded. Existing favicons will not be overwritten. | 667 // discarded. Existing favicons will not be overwritten. |
665 void SetImportedFavicons( | 668 void SetImportedFavicons( |
666 const std::vector<history::ImportedFavIconUsage>& favicon_usage); | 669 const std::vector<history::ImportedFavIconUsage>& favicon_usage); |
667 | 670 |
668 // Used by the FaviconService to set the favicon for a page on the history | 671 // Used by the FaviconService to set the favicon for a page on the history |
669 // backend. | 672 // backend. |
670 void SetFavicon(const GURL& page_url, | 673 void SetFavicon(const GURL& page_url, |
671 const GURL& icon_url, | 674 const GURL& icon_url, |
672 const std::vector<unsigned char>& image_data); | 675 const std::vector<unsigned char>& image_data, |
676 history::IconType icon_type); | |
673 | 677 |
674 | 678 |
675 // Sets the in-memory URL database. This is called by the backend once the | 679 // Sets the in-memory URL database. This is called by the backend once the |
676 // database is loaded to make it available. | 680 // database is loaded to make it available. |
677 void SetInMemoryBackend(history::InMemoryHistoryBackend* mem_backend); | 681 void SetInMemoryBackend(history::InMemoryHistoryBackend* mem_backend); |
678 | 682 |
679 // Called by our BackendDelegate when there is a problem reading the database. | 683 // Called by our BackendDelegate when there is a problem reading the database. |
680 // |message_id| is the relevant message in the string table to display. | 684 // |message_id| is the relevant message in the string table to display. |
681 void NotifyProfileError(int message_id); | 685 void NotifyProfileError(int message_id); |
682 | 686 |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
863 BookmarkService* bookmark_service_; | 867 BookmarkService* bookmark_service_; |
864 bool no_db_; | 868 bool no_db_; |
865 | 869 |
866 // True if needs top site migration. | 870 // True if needs top site migration. |
867 bool needs_top_sites_migration_; | 871 bool needs_top_sites_migration_; |
868 | 872 |
869 DISALLOW_COPY_AND_ASSIGN(HistoryService); | 873 DISALLOW_COPY_AND_ASSIGN(HistoryService); |
870 }; | 874 }; |
871 | 875 |
872 #endif // CHROME_BROWSER_HISTORY_HISTORY_H_ | 876 #endif // CHROME_BROWSER_HISTORY_HISTORY_H_ |
OLD | NEW |