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

Side by Side Diff: chrome/browser/ui/webui/options/browser_options_handler.cc

Issue 1020473003: Hotword: Check for a speaker model before launching the opt-in flow (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review Comments 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ui/webui/options/browser_options_handler.h" 5 #include "chrome/browser/ui/webui/options/browser_options_handler.h"
6 6
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 1863 matching lines...) Expand 10 before | Expand all | Expand 10 after
1874 } else { 1874 } else {
1875 DCHECK(!profile->GetPrefs()->GetBoolean( 1875 DCHECK(!profile->GetPrefs()->GetBoolean(
1876 prefs::kHotwordAlwaysOnSearchEnabled)); 1876 prefs::kHotwordAlwaysOnSearchEnabled));
1877 } 1877 }
1878 1878
1879 HotwordService* hotword_service = 1879 HotwordService* hotword_service =
1880 HotwordServiceFactory::GetForProfile(profile); 1880 HotwordServiceFactory::GetForProfile(profile);
1881 if (!hotword_service) 1881 if (!hotword_service)
1882 return; 1882 return;
1883 1883
1884 hotword_service->LaunchHotwordAudioVerificationApp(launch_mode); 1884 hotword_service->OptIntoHotwording(launch_mode);
1885 } 1885 }
1886 1886
1887 void BrowserOptionsHandler::HandleLaunchEasyUnlockSetup( 1887 void BrowserOptionsHandler::HandleLaunchEasyUnlockSetup(
1888 const base::ListValue* args) { 1888 const base::ListValue* args) {
1889 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->LaunchSetup(); 1889 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->LaunchSetup();
1890 } 1890 }
1891 1891
1892 void BrowserOptionsHandler::HandleRefreshExtensionControlIndicators( 1892 void BrowserOptionsHandler::HandleRefreshExtensionControlIndicators(
1893 const base::ListValue* args) { 1893 const base::ListValue* args) {
1894 SetupExtensionControlledIndicators(); 1894 SetupExtensionControlledIndicators();
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
2183 void BrowserOptionsHandler::OnPolicyUpdated(const policy::PolicyNamespace& ns, 2183 void BrowserOptionsHandler::OnPolicyUpdated(const policy::PolicyNamespace& ns,
2184 const policy::PolicyMap& previous, 2184 const policy::PolicyMap& previous,
2185 const policy::PolicyMap& current) { 2185 const policy::PolicyMap& current) {
2186 std::set<std::string> different_keys; 2186 std::set<std::string> different_keys;
2187 current.GetDifferingKeys(previous, &different_keys); 2187 current.GetDifferingKeys(previous, &different_keys);
2188 if (ContainsKey(different_keys, policy::key::kMetricsReportingEnabled)) 2188 if (ContainsKey(different_keys, policy::key::kMetricsReportingEnabled))
2189 SetupMetricsReportingCheckbox(); 2189 SetupMetricsReportingCheckbox();
2190 } 2190 }
2191 2191
2192 } // namespace options 2192 } // namespace options
OLDNEW
« chrome/browser/search/hotword_service.h ('K') | « chrome/browser/search/hotword_service.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698