| Index: chrome/browser/autocomplete/search_provider.cc
|
| diff --git a/chrome/browser/autocomplete/search_provider.cc b/chrome/browser/autocomplete/search_provider.cc
|
| index 25d08c0047505874e5484d05ee0bb8303af42dae..331a498f53666329f59a7096842933c0306eec03 100644
|
| --- a/chrome/browser/autocomplete/search_provider.cc
|
| +++ b/chrome/browser/autocomplete/search_provider.cc
|
| @@ -404,14 +404,6 @@ void SearchProvider::Start(const AutocompleteInput& input,
|
| UpdateMatches();
|
| }
|
|
|
| -void SearchProvider::Stop(bool clear_cached_results) {
|
| - StopSuggest();
|
| - done_ = true;
|
| -
|
| - if (clear_cached_results)
|
| - ClearAllResults();
|
| -}
|
| -
|
| void SearchProvider::OnURLFetchComplete(const net::URLFetcher* source) {
|
| DCHECK(!done_);
|
| suggest_results_pending_--;
|
| @@ -493,6 +485,23 @@ bool SearchProvider::ShouldAppendExtraParams(
|
| providers_.default_provider().empty();
|
| }
|
|
|
| +void SearchProvider::StopSuggest() {
|
| + // Increment the appropriate field in the histogram by the number of
|
| + // pending requests that were invalidated.
|
| + for (int i = 0; i < suggest_results_pending_; ++i)
|
| + LogOmniboxSuggestRequest(REQUEST_INVALIDATED);
|
| + suggest_results_pending_ = 0;
|
| + timer_.Stop();
|
| + // Stop any in-progress URL fetches.
|
| + keyword_fetcher_.reset();
|
| + default_fetcher_.reset();
|
| +}
|
| +
|
| +void SearchProvider::ClearAllResults() {
|
| + keyword_results_.Clear();
|
| + default_results_.Clear();
|
| +}
|
| +
|
| void SearchProvider::OnDeletionComplete(bool success,
|
| SuggestionDeletionHandler* handler) {
|
| RecordDeletionResult(success);
|
| @@ -711,23 +720,6 @@ bool SearchProvider::IsQuerySuitableForSuggest() const {
|
| return true;
|
| }
|
|
|
| -void SearchProvider::StopSuggest() {
|
| - // Increment the appropriate field in the histogram by the number of
|
| - // pending requests that were invalidated.
|
| - for (int i = 0; i < suggest_results_pending_; i++)
|
| - LogOmniboxSuggestRequest(REQUEST_INVALIDATED);
|
| - suggest_results_pending_ = 0;
|
| - timer_.Stop();
|
| - // Stop any in-progress URL fetches.
|
| - keyword_fetcher_.reset();
|
| - default_fetcher_.reset();
|
| -}
|
| -
|
| -void SearchProvider::ClearAllResults() {
|
| - keyword_results_.Clear();
|
| - default_results_.Clear();
|
| -}
|
| -
|
| void SearchProvider::RemoveAllStaleResults() {
|
| // We only need to remove stale results (which ensures the top-scoring
|
| // match is inlineable) if the user is not in reorder mode. In reorder
|
|
|