| 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_SEARCH_NTP_LOGGING_EVENTS_H_ | 5 #ifndef CHROME_COMMON_SEARCH_NTP_LOGGING_EVENTS_H_ |
| 6 #define CHROME_COMMON_SEARCH_NTP_LOGGING_EVENTS_H_ | 6 #define CHROME_COMMON_SEARCH_NTP_LOGGING_EVENTS_H_ |
| 7 | 7 |
| 8 // The different types of events that are logged from the NTP. This enum is used | 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 | 9 // to transfer information from the NTP javascript to the renderer and is not |
| 10 // used as a UMA enum histogram's logged value. | 10 // used as a UMA enum histogram's logged value. |
| 11 // Note: Keep in sync with browser/resources/local_ntp/most_visited_util.js | 11 // Note: Keep in sync with browser/resources/local_ntp/most_visited_util.js |
| 12 // and browser/resources/local_ntp/most_visited_single.js | 12 // and browser/resources/local_ntp/most_visited_single.js |
| 13 enum NTPLoggingEventType { | 13 enum NTPLoggingEventType { |
| 14 // The suggestion is coming from the server. | 14 // The suggestion is coming from the server. |
| 15 NTP_SERVER_SIDE_SUGGESTION = 0, | 15 NTP_SERVER_SIDE_SUGGESTION = 0, |
| 16 | 16 |
| 17 // The suggestion is coming from the client. | 17 // The suggestion is coming from the client. |
| 18 NTP_CLIENT_SIDE_SUGGESTION = 1, | 18 NTP_CLIENT_SIDE_SUGGESTION = 1, |
| 19 | 19 |
| 20 // Indicates a tile was rendered, no matter if it's a thumbnail, a gray tile | 20 // Indicates a tile was rendered, no matter if it's a thumbnail, a gray tile |
| 21 // or an external tile. | 21 // or an external tile. |
| 22 NTP_TILE = 2, | 22 NTP_TILE = 2, |
| 23 | 23 |
| 24 // The tile uses a local thumbnail image. | 24 // The tile uses a local thumbnail image. |
| 25 NTP_THUMBNAIL_TILE = 3, | 25 // Deleted: NTP_THUMBNAIL_TILE = 3, |
| 26 | 26 |
| 27 // Used when no thumbnail is specified and a gray tile with the domain is used | 27 // Used when no thumbnail is specified and a gray tile with the domain is used |
| 28 // as the main tile. | 28 // as the main tile. |
| 29 NTP_GRAY_TILE = 4, | 29 // Deleted: NTP_GRAY_TILE = 4, |
| 30 | 30 |
| 31 // The visuals of that tile are handled externally by the page itself. | 31 // The visuals of that tile are handled externally by the page itself. |
| 32 NTP_EXTERNAL_TILE = 5, | 32 // Deleted: NTP_EXTERNAL_TILE = 5, |
| 33 | 33 |
| 34 // There was an error in loading both the thumbnail image and the fallback | 34 // There was an error in loading both the thumbnail image and the fallback |
| 35 // (if it was provided), resulting in a grey tile. | 35 // (if it was provided), resulting in a grey tile. |
| 36 NTP_THUMBNAIL_ERROR = 6, | 36 // Deleted: NTP_THUMBNAIL_ERROR = 6, |
| 37 | 37 |
| 38 // Used a gray tile with the domain as the fallback for a failed thumbnail. | 38 // Used a gray tile with the domain as the fallback for a failed thumbnail. |
| 39 NTP_GRAY_TILE_FALLBACK = 7, | 39 // Deleted: NTP_GRAY_TILE_FALLBACK = 7, |
| 40 | 40 |
| 41 // The visuals of that tile's fallback are handled externally. | 41 // The visuals of that tile's fallback are handled externally. |
| 42 NTP_EXTERNAL_TILE_FALLBACK = 8, | 42 // Deleted: NTP_EXTERNAL_TILE_FALLBACK = 8, |
| 43 | 43 |
| 44 // Deleted: NTP_MOUSEOVER = 9 | 44 // Deleted: NTP_MOUSEOVER = 9 |
| 45 | 45 |
| 46 // A NTP Tile has finished loading (successfully or failing). | 46 // A NTP Tile has finished loading (successfully or failing). |
| 47 NTP_TILE_LOADED = 10, | 47 NTP_TILE_LOADED = 10, |
| 48 | 48 |
| 49 NTP_EVENT_TYPE_LAST = NTP_TILE_LOADED | 49 NTP_EVENT_TYPE_LAST = NTP_TILE_LOADED |
| 50 }; | 50 }; |
| 51 | 51 |
| 52 // The source of an NTP tile. | 52 // The source of an NTP tile. |
| 53 // Note: Keep in sync with browser/resources/local_ntp/most_visited_util.js and | 53 // Note: Keep in sync with browser/resources/local_ntp/most_visited_util.js and |
| 54 // browser/resources/local_ntp/most_visited_single.js. | 54 // browser/resources/local_ntp/most_visited_single.js. |
| 55 // TODO(treib): Merge this into MostVisitedSource from components/ntp_tiles. | 55 // TODO(treib): Merge this into MostVisitedSource from components/ntp_tiles. |
| 56 enum class NTPLoggingTileSource { | 56 enum class NTPLoggingTileSource { |
| 57 CLIENT = 0, | 57 CLIENT = 0, |
| 58 SERVER = 1, | 58 SERVER = 1, |
| 59 LAST = SERVER | 59 LAST = SERVER |
| 60 }; | 60 }; |
| 61 | 61 |
| 62 #endif // CHROME_COMMON_SEARCH_NTP_LOGGING_EVENTS_H_ | 62 #endif // CHROME_COMMON_SEARCH_NTP_LOGGING_EVENTS_H_ |
| OLD | NEW |