Chromium Code Reviews| Index: chrome/browser/intents/cws_intents_registry.cc |
| diff --git a/chrome/browser/intents/cws_intents_registry.cc b/chrome/browser/intents/cws_intents_registry.cc |
| index 96fd943aa1d8c9a30c4234283ffee7c4b484aa0e..bbf194262788887f12d0b07c0b49e0c0b3ecd5f9 100644 |
| --- a/chrome/browser/intents/cws_intents_registry.cc |
| +++ b/chrome/browser/intents/cws_intents_registry.cc |
| @@ -12,7 +12,6 @@ |
| #include "base/utf_string_conversions.h" |
| #include "chrome/common/extensions/extension_l10n_util.h" |
| #include "chrome/common/extensions/message_bundle.h" |
| -#include "chrome/browser/intents/api_key.h" |
| #include "chrome/browser/net/chrome_url_request_context.h" |
| #include "chrome/browser/webdata/web_data_service.h" |
| #include "chrome/common/net/url_util.h" |
| @@ -20,6 +19,11 @@ |
| #include "net/base/mime_util.h" |
| #include "net/url_request/url_fetcher.h" |
| +// Forward declaration. |
|
Jói
2012/09/17 16:56:19
Seems simpler to just #include (and update DEPS if
Greg Billock
2012/09/17 17:52:18
Yes, let's #include
|
| +namespace google_apis { |
| +std::string GetAPIKey(); |
| +} |
| + |
| namespace { |
| // Limit for the number of suggestions we fix from CWS. Ideally, the registry |
| @@ -233,10 +237,8 @@ GURL CWSIntentsRegistry::BuildQueryURL(const string16& action, |
| "0"); |
| request = chrome_common_net::AppendQueryParameter(request, "num_results", |
| kMaxSuggestions); |
| - if (web_intents::kApiKey[0]) { |
| - request = chrome_common_net::AppendQueryParameter(request, "key", |
| - web_intents::kApiKey); |
| - } |
| + request = chrome_common_net::AppendQueryParameter(request, "key", |
| + google_apis::GetAPIKey()); |
|
Steve McKay
2012/09/17 17:01:43
Question, for Jói mostly. In the past when we need
|
| return request; |
| } |