OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ | 5 #ifndef COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ |
6 #define COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ | 6 #define COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include "base/memory/ref_counted_memory.h" | 10 #include "base/memory/ref_counted_memory.h" |
9 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
10 #include "ui/gfx/geometry/size.h" | 12 #include "ui/gfx/geometry/size.h" |
11 #include "ui/gfx/image/image.h" | 13 #include "ui/gfx/image/image.h" |
12 #include "url/gurl.h" | 14 #include "url/gurl.h" |
13 | 15 |
14 namespace favicon_base { | 16 namespace favicon_base { |
15 | 17 |
16 struct FallbackIconStyle; | 18 struct FallbackIconStyle; |
17 | 19 |
18 typedef int64 FaviconID; | 20 typedef int64_t FaviconID; |
19 | 21 |
20 // Defines the icon types. They are also stored in icon_type field of favicons | 22 // Defines the icon types. They are also stored in icon_type field of favicons |
21 // table. | 23 // table. |
22 // The values of the IconTypes are used to select the priority in which favicon | 24 // The values of the IconTypes are used to select the priority in which favicon |
23 // data is returned in HistoryBackend and ThumbnailDatabase. Data for the | 25 // data is returned in HistoryBackend and ThumbnailDatabase. Data for the |
24 // largest IconType takes priority if data for multiple IconTypes is available. | 26 // largest IconType takes priority if data for multiple IconTypes is available. |
25 enum IconType { | 27 enum IconType { |
26 INVALID_ICON = 0x0, | 28 INVALID_ICON = 0x0, |
27 FAVICON = 1 << 0, | 29 FAVICON = 1 << 0, |
28 TOUCH_ICON = 1 << 1, | 30 TOUCH_ICON = 1 << 1, |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 FaviconRawBitmapResult bitmap; | 93 FaviconRawBitmapResult bitmap; |
92 | 94 |
93 // The fallback icon style if a sufficiently large icon isn't available. This | 95 // The fallback icon style if a sufficiently large icon isn't available. This |
94 // uses the dominant color of a smaller icon as the background if available. | 96 // uses the dominant color of a smaller icon as the background if available. |
95 scoped_ptr<FallbackIconStyle> fallback_icon_style; | 97 scoped_ptr<FallbackIconStyle> fallback_icon_style; |
96 }; | 98 }; |
97 | 99 |
98 } // namespace favicon_base | 100 } // namespace favicon_base |
99 | 101 |
100 #endif // COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ | 102 #endif // COMPONENTS_FAVICON_BASE_FAVICON_TYPES_H_ |
OLD | NEW |