OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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 /** | 5 /** |
6 * @fileoverview Externs required to closure-compile MD History. | 6 * @fileoverview Externs for objects sent from C++ to chrome://history. |
7 * @externs | 7 * @externs |
8 */ | 8 */ |
9 | 9 |
10 // Types: | 10 /** |
| 11 * The type of the history result object. The definition is based on |
| 12 * chrome/browser/ui/webui/browsing_history_handler.cc: |
| 13 * BrowsingHistoryHandler::HistoryEntry::ToValue() |
| 14 * @typedef {{allTimestamps: Array<number>, |
| 15 * blockedVisit: boolean, |
| 16 * dateRelativeDay: string, |
| 17 * dateShort: string, |
| 18 * dateTimeOfDay: string, |
| 19 * deviceName: string, |
| 20 * deviceType: string, |
| 21 * domain: string, |
| 22 * fallbackFaviconText: string, |
| 23 * hostFilteringBehavior: number, |
| 24 * snippet: string, |
| 25 * starred: boolean, |
| 26 * time: number, |
| 27 * title: string, |
| 28 * url: string}} |
| 29 */ |
| 30 var HistoryEntry; |
| 31 |
| 32 /** |
| 33 * The type of the history results info object. The definition is based on |
| 34 * chrome/browser/ui/webui/browsing_history_handler.cc: |
| 35 * BrowsingHistoryHandler::QueryComplete() |
| 36 * @typedef {{finished: boolean, |
| 37 * hasSyncedResults: boolean, |
| 38 * queryInterval: string, |
| 39 * queryStartMonth: string, |
| 40 * term: string}} |
| 41 */ |
| 42 var HistoryQuery; |
| 43 |
| 44 /** |
| 45 * The type of the foreign session tab object. This definition is based on |
| 46 * chrome/browser/ui/webui/foreign_session_handler.cc: |
| 47 * @typedef {{direction: string, |
| 48 * sessionId: number, |
| 49 * timestamp: number, |
| 50 * title: string, |
| 51 * type: string, |
| 52 * url: string}} |
| 53 */ |
| 54 var ForeignSessionTab; |
| 55 |
| 56 /** |
| 57 * The type of the foreign session tab object. This definition is based on |
| 58 * chrome/browser/ui/webui/foreign_session_handler.cc: |
| 59 * @typedef {{timestamp: number, |
| 60 * userVisibleTimestamp: string, |
| 61 * sessionId: number, |
| 62 * tabs: Array<ForeignSessionTab>}} |
| 63 */ |
| 64 var ForeignSessionWindow; |
| 65 |
| 66 /** |
| 67 * The type of the foreign session info object. This definition is based on |
| 68 * chrome/browser/ui/webui/foreign_session_handler.cc: |
| 69 * @typedef {{collapsed: boolean, |
| 70 * deviceType: string, |
| 71 * name: string, |
| 72 * modifiedTime: string, |
| 73 * tag: string, |
| 74 * timestamp: number, |
| 75 * windows: Array<ForeignSessionWindow>}} |
| 76 */ |
| 77 var ForeignSession; |
| 78 |
11 /** | 79 /** |
12 * @typedef {{incremental: boolean, | 80 * @typedef {{incremental: boolean, |
13 * querying: boolean, | 81 * querying: boolean, |
14 * searchTerm: string}} | 82 * searchTerm: string}} |
15 */ | 83 */ |
16 var QueryState; | 84 var QueryState; |
17 | 85 |
18 /** | 86 /** |
19 * @typedef {{info: ?HistoryQuery, | 87 * @typedef {{info: ?HistoryQuery, |
20 * results: ?Array<!HistoryEntry>, | 88 * results: ?Array<!HistoryEntry>, |
21 * sessionList: ?Array<!ForeignSession>}} | 89 * sessionList: ?Array<!ForeignSession>}} |
22 */ | 90 */ |
23 var QueryResult; | 91 var QueryResult; |
24 | 92 |
25 /** | 93 /** |
26 * @constructor | 94 * @constructor |
27 * @extends {MouseEvent} | 95 * @extends {MouseEvent} |
28 */ | 96 */ |
29 var DomRepeatClickEvent = function() {}; | 97 var DomRepeatClickEvent = function() {}; |
30 | 98 |
31 /** @type {Object} */ | 99 /** @type {Object} */ |
32 DomRepeatClickEvent.prototype.model; | 100 DomRepeatClickEvent.prototype.model; |
OLD | NEW |