| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "chrome/browser/autocomplete/base_search_provider.h" | 5 #include "chrome/browser/autocomplete/base_search_provider.h" |
| 6 | 6 |
| 7 #include "base/i18n/case_conversion.h" | 7 #include "base/i18n/case_conversion.h" |
| 8 #include "base/i18n/icu_string_conversions.h" | 8 #include "base/i18n/icu_string_conversions.h" |
| 9 #include "base/json/json_string_value_serializer.h" | 9 #include "base/json/json_string_value_serializer.h" |
| 10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
| 11 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
| 12 #include "base/strings/utf_string_conversions.h" | 12 #include "base/strings/utf_string_conversions.h" |
| 13 #include "chrome/browser/autocomplete/autocomplete_provider_listener.h" | 13 #include "chrome/browser/autocomplete/autocomplete_provider_listener.h" |
| 14 #include "chrome/browser/autocomplete/url_prefix.h" | 14 #include "chrome/browser/autocomplete/url_prefix.h" |
| 15 #include "chrome/browser/history/history_service.h" | 15 #include "chrome/browser/history/history_service.h" |
| 16 #include "chrome/browser/history/history_service_factory.h" | 16 #include "chrome/browser/history/history_service_factory.h" |
| 17 #include "chrome/browser/omnibox/omnibox_field_trial.h" | 17 #include "chrome/browser/omnibox/omnibox_field_trial.h" |
| 18 #include "chrome/browser/profiles/profile.h" | 18 #include "chrome/browser/profiles/profile.h" |
| 19 #include "chrome/browser/search/instant_service.h" | 19 #include "chrome/browser/search/instant_service.h" |
| 20 #include "chrome/browser/search/instant_service_factory.h" | 20 #include "chrome/browser/search/instant_service_factory.h" |
| 21 #include "chrome/browser/search/search.h" | 21 #include "chrome/browser/search/search.h" |
| 22 #include "chrome/browser/search_engines/template_url.h" | 22 #include "chrome/browser/search_engines/template_url.h" |
| 23 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" | 23 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" |
| 24 #include "chrome/browser/sync/profile_sync_service.h" | 24 #include "chrome/browser/sync/profile_sync_service.h" |
| 25 #include "chrome/browser/sync/profile_sync_service_factory.h" | 25 #include "chrome/browser/sync/profile_sync_service_factory.h" |
| 26 #include "chrome/common/net/url_fixer_upper.h" | 26 #include "chrome/common/net/url_fixer_upper.h" |
| 27 #include "chrome/common/pref_names.h" | 27 #include "chrome/common/pref_names.h" |
| 28 #include "components/bookmarks/bookmark_pref_names.h" |
| 28 #include "components/sync_driver/sync_prefs.h" | 29 #include "components/sync_driver/sync_prefs.h" |
| 29 #include "content/public/common/url_constants.h" | 30 #include "content/public/common/url_constants.h" |
| 30 #include "net/base/escape.h" | 31 #include "net/base/escape.h" |
| 31 #include "net/base/net_util.h" | 32 #include "net/base/net_util.h" |
| 32 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" | 33 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
| 33 #include "net/http/http_response_headers.h" | 34 #include "net/http/http_response_headers.h" |
| 34 #include "net/url_request/url_fetcher_delegate.h" | 35 #include "net/url_request/url_fetcher_delegate.h" |
| 35 #include "url/gurl.h" | 36 #include "url/gurl.h" |
| 36 | 37 |
| 37 namespace { | 38 namespace { |
| (...skipping 856 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 894 } | 895 } |
| 895 | 896 |
| 896 void BaseSearchProvider::OnDeletionComplete( | 897 void BaseSearchProvider::OnDeletionComplete( |
| 897 bool success, SuggestionDeletionHandler* handler) { | 898 bool success, SuggestionDeletionHandler* handler) { |
| 898 RecordDeletionResult(success); | 899 RecordDeletionResult(success); |
| 899 SuggestionDeletionHandlers::iterator it = std::find( | 900 SuggestionDeletionHandlers::iterator it = std::find( |
| 900 deletion_handlers_.begin(), deletion_handlers_.end(), handler); | 901 deletion_handlers_.begin(), deletion_handlers_.end(), handler); |
| 901 DCHECK(it != deletion_handlers_.end()); | 902 DCHECK(it != deletion_handlers_.end()); |
| 902 deletion_handlers_.erase(it); | 903 deletion_handlers_.erase(it); |
| 903 } | 904 } |
| OLD | NEW |