OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ |
6 #define CHROME_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ | 6 #define CHROME_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 void DecodeSearchTermFromJsonResponse(const std::string& response, | 188 void DecodeSearchTermFromJsonResponse(const std::string& response, |
189 std::string* search_term, | 189 std::string* search_term, |
190 std::string* display_text, | 190 std::string* display_text, |
191 std::string* alternate_term, | 191 std::string* alternate_term, |
192 std::string* mid, | 192 std::string* mid, |
193 std::string* prevent_preload, | 193 std::string* prevent_preload, |
194 int* mention_start, | 194 int* mention_start, |
195 int* mention_end, | 195 int* mention_end, |
196 std::string* context_language, | 196 std::string* context_language, |
197 std::string* thumbnail_url, | 197 std::string* thumbnail_url, |
198 std::string* caption); | 198 std::string* caption, |
| 199 std::string* quick_action_uri, |
| 200 std::string* quick_action_category); |
199 | 201 |
200 // Extracts the start and end location from a mentions list, and sets the | 202 // Extracts the start and end location from a mentions list, and sets the |
201 // integers referenced by |startResult| and |endResult|. | 203 // integers referenced by |startResult| and |endResult|. |
202 void ExtractMentionsStartEnd(const base::ListValue& mentions_list, | 204 void ExtractMentionsStartEnd(const base::ListValue& mentions_list, |
203 int* startResult, | 205 int* startResult, |
204 int* endResult); | 206 int* endResult); |
205 | 207 |
206 // Generates a subset of the given surrounding_text string, for Icing | 208 // Generates a subset of the given surrounding_text string, for Icing |
207 // integration. | 209 // integration. |
208 // |surrounding_text| the entire text context that contains the selection. | 210 // |surrounding_text| the entire text context that contains the selection. |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
241 // The callback for notifications of Icing selection being available. | 243 // The callback for notifications of Icing selection being available. |
242 IcingCallback icing_callback_; | 244 IcingCallback icing_callback_; |
243 | 245 |
244 // Used to hold the context until an upcoming search term request is started. | 246 // Used to hold the context until an upcoming search term request is started. |
245 std::unique_ptr<ContextualSearchContext> context_; | 247 std::unique_ptr<ContextualSearchContext> context_; |
246 | 248 |
247 DISALLOW_COPY_AND_ASSIGN(ContextualSearchDelegate); | 249 DISALLOW_COPY_AND_ASSIGN(ContextualSearchDelegate); |
248 }; | 250 }; |
249 | 251 |
250 #endif // CHROME_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ | 252 #endif // CHROME_BROWSER_ANDROID_CONTEXTUALSEARCH_CONTEXTUAL_SEARCH_DELEGATE_H_ |
OLD | NEW |