Friedrich Horschig | efec081 | 2017-09-28 18:50:17 | [diff] [blame] | 1 | // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #ifndef COMPONENTS_NTP_TILES_TILE_TITLE_SOURCE_H_ |
| 6 | #define COMPONENTS_NTP_TILES_TILE_TITLE_SOURCE_H_ |
| 7 | |
| 8 | namespace ntp_tiles { |
| 9 | |
| 10 | // The source where the displayed title of an NTP tile originates from. |
| 11 | // |
| 12 | // These values must stay in sync with the NTPTileTitleSource enums in |
| 13 | // enums.xml AND in chrome/browser/resources/local_ntp/most_visited_single.js. |
| 14 | // |
| 15 | // A Java counterpart will be generated for this enum. |
Cathy Li | ac1ae0904 | 2019-06-04 23:30:49 | [diff] [blame] | 16 | // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.chrome.browser.suggestions.tile |
Friedrich Horschig | efec081 | 2017-09-28 18:50:17 | [diff] [blame] | 17 | enum class TileTitleSource { |
| 18 | // The title might be invalid, aggregated, user-set, extracted from history, |
| 19 | // not loaded or simply not known. |
| 20 | UNKNOWN = 0, |
| 21 | |
| 22 | // The site's manifest contained a usable "(short_)name" attribute. |
| 23 | MANIFEST = 1, |
| 24 | |
| 25 | // The site provided a meta tag (e.g. OpenGraph's site_name). |
| 26 | META_TAG = 2, |
| 27 | |
| 28 | // The site's title is used as tile title, extracted from the title tag. |
| 29 | TITLE_TAG = 3, |
| 30 | |
| 31 | // The title was inferred from multiple signals (e.g. meta tags, url, title). |
| 32 | INFERRED = 4, |
| 33 | |
| 34 | // The maximum tile title source value that gets recorded in UMA. |
| 35 | LAST = INFERRED |
| 36 | }; |
| 37 | |
| 38 | } // namespace ntp_tiles |
| 39 | |
| 40 | #endif // COMPONENTS_NTP_TILES_TILE_TITLE_SOURCE_H_ |