Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: chrome/browser/extensions/external_component_loader.cc

Issue 992173002: Delete the old hotwording integration. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@hotword-remove-disable-option
Patch Set: Rebase. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/extensions/external_component_loader.h" 5 #include "chrome/browser/extensions/external_component_loader.h"
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "chrome/browser/bookmarks/enhanced_bookmarks_features.h" 8 #include "chrome/browser/bookmarks/enhanced_bookmarks_features.h"
9 #include "chrome/browser/browser_process.h" 9 #include "chrome/browser/browser_process.h"
10 #include "chrome/browser/search/hotword_service.h" 10 #include "chrome/browser/search/hotword_service.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 return false; 50 return false;
51 } 51 }
52 52
53 void ExternalComponentLoader::StartLoading() { 53 void ExternalComponentLoader::StartLoading() {
54 prefs_.reset(new base::DictionaryValue()); 54 prefs_.reset(new base::DictionaryValue());
55 std::string app_id = extension_misc::kInAppPaymentsSupportAppId; 55 std::string app_id = extension_misc::kInAppPaymentsSupportAppId;
56 prefs_->SetString(app_id + ".external_update_url", 56 prefs_->SetString(app_id + ".external_update_url",
57 extension_urls::GetWebstoreUpdateUrl().spec()); 57 extension_urls::GetWebstoreUpdateUrl().spec());
58 58
59 if (HotwordServiceFactory::IsHotwordAllowed(profile_)) { 59 if (HotwordServiceFactory::IsHotwordAllowed(profile_)) {
60 std::string hotword_id = extension_misc::kHotwordExtensionId; 60 std::string hotword_id = extension_misc::kHotwordSharedModuleId;
61 if (HotwordService::IsExperimentalHotwordingEnabled()) {
62 hotword_id = extension_misc::kHotwordSharedModuleId;
63 }
64 prefs_->SetString(hotword_id + ".external_update_url", 61 prefs_->SetString(hotword_id + ".external_update_url",
65 extension_urls::GetWebstoreUpdateUrl().spec()); 62 extension_urls::GetWebstoreUpdateUrl().spec());
66 } 63 }
67 64
68 { 65 {
69 std::string extension_id; 66 std::string extension_id;
70 if (IsEnhancedBookmarksEnabled(&extension_id)) { 67 if (IsEnhancedBookmarksEnabled(&extension_id)) {
71 prefs_->SetString(extension_id + ".external_update_url", 68 prefs_->SetString(extension_id + ".external_update_url",
72 extension_urls::GetWebstoreUpdateUrl().spec()); 69 extension_urls::GetWebstoreUpdateUrl().spec());
73 } 70 }
(...skipping 16 matching lines...) Expand all
90 if (GetGoogleNowExtensionId(&google_now_extension_id)) { 87 if (GetGoogleNowExtensionId(&google_now_extension_id)) {
91 prefs_->SetString(google_now_extension_id + ".external_update_url", 88 prefs_->SetString(google_now_extension_id + ".external_update_url",
92 extension_urls::GetWebstoreUpdateUrl().spec()); 89 extension_urls::GetWebstoreUpdateUrl().spec());
93 } 90 }
94 #endif 91 #endif
95 92
96 LoadFinished(); 93 LoadFinished();
97 } 94 }
98 95
99 } // namespace extensions 96 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/component_loader.cc ('k') | chrome/browser/media/media_capture_devices_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698