| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 // This file contains the Search autocomplete provider. This provider is | 5 // This file contains the Search autocomplete provider. This provider is |
| 6 // responsible for all non-keyword autocomplete entries that start with | 6 // responsible for all non-keyword autocomplete entries that start with |
| 7 // "Search <engine> for ...", including searching for the current input string, | 7 // "Search <engine> for ...", including searching for the current input string, |
| 8 // search history, and search suggestions. An instance of it gets created and | 8 // search history, and search suggestions. An instance of it gets created and |
| 9 // managed by the autocomplete controller. | 9 // managed by the autocomplete controller. |
| 10 // | 10 // |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 const std::wstring& suggest_text); | 63 const std::wstring& suggest_text); |
| 64 | 64 |
| 65 // AutocompleteProvider | 65 // AutocompleteProvider |
| 66 virtual void Start(const AutocompleteInput& input, | 66 virtual void Start(const AutocompleteInput& input, |
| 67 bool minimal_changes); | 67 bool minimal_changes); |
| 68 virtual void Stop(); | 68 virtual void Stop(); |
| 69 | 69 |
| 70 // URLFetcher::Delegate | 70 // URLFetcher::Delegate |
| 71 virtual void OnURLFetchComplete(const URLFetcher* source, | 71 virtual void OnURLFetchComplete(const URLFetcher* source, |
| 72 const GURL& url, | 72 const GURL& url, |
| 73 const URLRequestStatus& status, | 73 const net::URLRequestStatus& status, |
| 74 int response_code, | 74 int response_code, |
| 75 const ResponseCookies& cookies, | 75 const ResponseCookies& cookies, |
| 76 const std::string& data); | 76 const std::string& data); |
| 77 | 77 |
| 78 // ID used in creating URLFetcher for default provider's suggest results. | 78 // ID used in creating URLFetcher for default provider's suggest results. |
| 79 static const int kDefaultProviderURLFetcherID; | 79 static const int kDefaultProviderURLFetcherID; |
| 80 | 80 |
| 81 // ID used in creating URLFetcher for keyword provider's suggest results. | 81 // ID used in creating URLFetcher for keyword provider's suggest results. |
| 82 static const int kKeywordProviderURLFetcherID; | 82 static const int kKeywordProviderURLFetcherID; |
| 83 | 83 |
| (...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 314 // Whether suggest_results_ is valid. | 314 // Whether suggest_results_ is valid. |
| 315 bool have_suggest_results_; | 315 bool have_suggest_results_; |
| 316 | 316 |
| 317 // Has FinalizeInstantQuery been invoked since the last |Start|? | 317 // Has FinalizeInstantQuery been invoked since the last |Start|? |
| 318 bool instant_finalized_; | 318 bool instant_finalized_; |
| 319 | 319 |
| 320 DISALLOW_COPY_AND_ASSIGN(SearchProvider); | 320 DISALLOW_COPY_AND_ASSIGN(SearchProvider); |
| 321 }; | 321 }; |
| 322 | 322 |
| 323 #endif // CHROME_BROWSER_AUTOCOMPLETE_SEARCH_PROVIDER_H_ | 323 #endif // CHROME_BROWSER_AUTOCOMPLETE_SEARCH_PROVIDER_H_ |
| OLD | NEW |