Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(593)

Side by Side Diff: chrome/common/search/instant_types.h

Issue 2532103002: Add support for components/ntp_tiles in InstantService (Closed)
Patch Set: rebase Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/common/render_messages.h ('k') | chrome/common/search/instant_types.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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_INSTANT_TYPES_H_ 5 #ifndef CHROME_COMMON_SEARCH_INSTANT_TYPES_H_
6 #define CHROME_COMMON_SEARCH_INSTANT_TYPES_H_ 6 #define CHROME_COMMON_SEARCH_INSTANT_TYPES_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
11 #include <utility> 11 #include <utility>
12 12
13 #include "base/strings/string16.h" 13 #include "base/strings/string16.h"
14 #include "components/ntp_tiles/ntp_tile_source.h"
14 #include "url/gurl.h" 15 #include "url/gurl.h"
15 16
16 // ID used by Instant code to refer to objects (e.g. Autocomplete results, Most 17 // ID used by Instant code to refer to objects (e.g. Autocomplete results, Most
17 // Visited items) that the Instant page needs access to. 18 // Visited items) that the Instant page needs access to.
18 typedef int InstantRestrictedID; 19 typedef int InstantRestrictedID;
19 20
20 // A wrapper to hold Instant suggested text and its metadata. Used to tell the 21 // A wrapper to hold Instant suggested text and its metadata. Used to tell the
21 // server what suggestion to prefetch. 22 // server what suggestion to prefetch.
22 struct InstantSuggestion { 23 struct InstantSuggestion {
23 InstantSuggestion(); 24 InstantSuggestion();
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 // The title of the Most Visited page. May be empty, in which case the |url| 135 // The title of the Most Visited page. May be empty, in which case the |url|
135 // is used as the title. 136 // is used as the title.
136 base::string16 title; 137 base::string16 title;
137 138
138 // The external URL of the thumbnail associated with this page. 139 // The external URL of the thumbnail associated with this page.
139 GURL thumbnail; 140 GURL thumbnail;
140 141
141 // The external URL of the favicon associated with this page. 142 // The external URL of the favicon associated with this page.
142 GURL favicon; 143 GURL favicon;
143 144
144 // True if it's a server side suggestion. 145 // The source of the item, e.g. server-side or client-side.
145 // Otherwise, it's a client side suggestion. 146 ntp_tiles::NTPTileSource source;
146 bool is_server_side_suggestion;
147 }; 147 };
148 148
149 // An InstantMostVisitedItem along with its assigned restricted ID. 149 // An InstantMostVisitedItem along with its assigned restricted ID.
150 typedef std::pair<InstantRestrictedID, InstantMostVisitedItem> 150 typedef std::pair<InstantRestrictedID, InstantMostVisitedItem>
151 InstantMostVisitedItemIDPair; 151 InstantMostVisitedItemIDPair;
152 152
153 // Embedded search request logging stats params. 153 // Embedded search request logging stats params.
154 extern const char kSearchQueryKey[]; 154 extern const char kSearchQueryKey[];
155 extern const char kOriginalQueryKey[]; 155 extern const char kOriginalQueryKey[];
156 extern const char kRLZParameterKey[]; 156 extern const char kRLZParameterKey[];
(...skipping 23 matching lines...) Expand all
180 180
181 // The optional assisted query stats, aka AQS, used for logging purposes. 181 // The optional assisted query stats, aka AQS, used for logging purposes.
182 // This string contains impressions of all autocomplete matches shown 182 // This string contains impressions of all autocomplete matches shown
183 // at the query submission time. For privacy reasons, we require the 183 // at the query submission time. For privacy reasons, we require the
184 // search provider to support HTTPS protocol in order to receive the AQS 184 // search provider to support HTTPS protocol in order to receive the AQS
185 // param. 185 // param.
186 // For more details, see http://goto.google.com/binary-clients-logging. 186 // For more details, see http://goto.google.com/binary-clients-logging.
187 base::string16 assisted_query_stats; 187 base::string16 assisted_query_stats;
188 }; 188 };
189 #endif // CHROME_COMMON_SEARCH_INSTANT_TYPES_H_ 189 #endif // CHROME_COMMON_SEARCH_INSTANT_TYPES_H_
OLDNEW
« no previous file with comments | « chrome/common/render_messages.h ('k') | chrome/common/search/instant_types.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698