OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_COMMON_NTP_LOGGING_EVENTS_H_ | 5 #ifndef CHROME_COMMON_NTP_LOGGING_EVENTS_H_ |
6 #define CHROME_COMMON_NTP_LOGGING_EVENTS_H_ | 6 #define CHROME_COMMON_NTP_LOGGING_EVENTS_H_ |
7 | 7 |
8 // The different types of events that are logged from the NTP. | 8 // The different types of events that are logged from the NTP. This enum is used |
| 9 // to transfer information from the NTP javascript to the renderer and is not |
| 10 // used as a UMA enum histogram's logged value. |
| 11 // Note: Keep in sync with browser/resources/local_ntp/most_visited_utils.js |
9 enum NTPLoggingEventType { | 12 enum NTPLoggingEventType { |
10 // The user moused over an NTP tile or title. | 13 // The suggestion is coming from the server. |
11 NTP_MOUSEOVER = 0, | 14 NTP_SERVER_SIDE_SUGGESTION = 0, |
12 | 15 |
13 // The page attempted to load a thumbnail image. | 16 // The suggestion is coming from the client. |
14 NTP_THUMBNAIL_ATTEMPT = 1, | 17 NTP_CLIENT_SIDE_SUGGESTION = 1, |
| 18 |
| 19 // Indicates a tile was rendered, no matter if it's a thumbnail, a gray tile |
| 20 // or an external tile. |
| 21 NTP_TILE = 2, |
| 22 |
| 23 // The tile uses a local thumbnail image. |
| 24 NTP_THUMBNAIL_TILE = 3, |
| 25 |
| 26 // Used when no thumbnail is specified and a gray tile with the domain is used |
| 27 // as the main tile. |
| 28 NTP_GRAY_TILE = 4, |
| 29 |
| 30 // The visuals of that tile are handled externally by the page itself. |
| 31 NTP_EXTERNAL_TILE = 5, |
15 | 32 |
16 // There was an error in loading both the thumbnail image and the fallback | 33 // There was an error in loading both the thumbnail image and the fallback |
17 // (if it was provided), resulting in a grey tile. | 34 // (if it was provided), resulting in a grey tile. |
18 NTP_THUMBNAIL_ERROR = 2, | 35 NTP_THUMBNAIL_ERROR = 6, |
19 | 36 |
20 // The page attempted to load a thumbnail URL while a fallback thumbnail was | 37 // Used a gray tile with the domain as the fallback for a failed thumbnail. |
21 // provided. | 38 NTP_GRAY_TILE_FALLBACK = 7, |
22 NTP_FALLBACK_THUMBNAIL_REQUESTED = 3, | |
23 | 39 |
24 // The primary thumbnail image failed to load and caused us to use the | 40 // The visuals of that tile's fallback are handled externally. |
25 // secondary thumbnail as a fallback. | 41 NTP_EXTERNAL_TILE_FALLBACK = 8, |
26 NTP_FALLBACK_THUMBNAIL_USED = 4, | |
27 | 42 |
28 // The suggestion is coming from the server. | 43 // The user moused over an NTP tile or title. |
29 NTP_SERVER_SIDE_SUGGESTION = 5, | 44 NTP_MOUSEOVER = 9, |
30 | |
31 // The suggestion is coming from the client. | |
32 NTP_CLIENT_SIDE_SUGGESTION = 6, | |
33 | |
34 // The visuals of that tile are handled externally by the page itself. | |
35 NTP_EXTERNAL_TILE = 7, | |
36 | 45 |
37 NTP_NUM_EVENT_TYPES | 46 NTP_NUM_EVENT_TYPES |
38 }; | 47 }; |
39 | 48 |
40 #endif // CHROME_COMMON_NTP_LOGGING_EVENTS_H_ | 49 #endif // CHROME_COMMON_NTP_LOGGING_EVENTS_H_ |
OLD | NEW |