Index: chrome/browser/resources/hotword_audio_verification/main.js |
diff --git a/chrome/browser/resources/hotword_audio_verification/main.js b/chrome/browser/resources/hotword_audio_verification/main.js |
index c180e0732dc54560cc21b9c5057cbc87be29400c..b7e335f5c96ee180040d5f4abfe81400900962f5 100644 |
--- a/chrome/browser/resources/hotword_audio_verification/main.js |
+++ b/chrome/browser/resources/hotword_audio_verification/main.js |
@@ -40,16 +40,21 @@ document.addEventListener('DOMContentLoaded', function() { |
}); |
$('hw-agree-button').addEventListener('click', function(e) { |
- // TODO(kcarattini): Set the Audio History setting. |
- flow.advanceStep(); |
+ if (chrome.hotwordPrivate && chrome.hotwordPrivate.setAudioLoggingEnabled) { |
+ chrome.hotwordPrivate.setAudioLoggingEnabled(true, |
+ flow.advanceStep.bind(flow)); |
rpetterson
2014/09/11 20:14:17
Based on the discussion with Hwi, should this move
kcarattini
2014/09/12 01:02:07
Done.
|
+ } |
e.stopPropagation(); |
}); |
// TODO(kcarattini): Remove this once speech training is implemented. The |
// way to get to the next page will be to complete the speech training. |
$('training').addEventListener('click', function(e) { |
- // TODO(kcarattini): Set the always-on-hotword setting. |
- flow.advanceStep(); |
+ if (chrome.hotwordPrivate && |
+ chrome.hotwordPrivate.setHotwordAlwaysOnSearchEnabled) { |
+ chrome.hotwordPrivate.setHotwordAlwaysOnSearchEnabled(true, |
+ flow.advanceStep.bind(flow)); |
+ } |
e.stopPropagation(); |
}); |