| 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 #ifndef EXTENSIONS_SHELL_BROWSER_SHELL_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ | 5 #ifndef EXTENSIONS_SHELL_BROWSER_SHELL_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ |
| 6 #define EXTENSIONS_SHELL_BROWSER_SHELL_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ | 6 #define EXTENSIONS_SHELL_BROWSER_SHELL_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "content/public/browser/speech_recognition_event_listener.h" | 9 #include "content/public/browser/speech_recognition_event_listener.h" |
| 10 #include "content/public/browser/speech_recognition_manager_delegate.h" | 10 #include "content/public/browser/speech_recognition_manager_delegate.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 int session_id, | 32 int session_id, |
| 33 const content::SpeechRecognitionResults& result) override; | 33 const content::SpeechRecognitionResults& result) override; |
| 34 void OnRecognitionError( | 34 void OnRecognitionError( |
| 35 int session_id, | 35 int session_id, |
| 36 const content::SpeechRecognitionError& error) override; | 36 const content::SpeechRecognitionError& error) override; |
| 37 void OnAudioLevelsChange(int session_id, | 37 void OnAudioLevelsChange(int session_id, |
| 38 float volume, | 38 float volume, |
| 39 float noise_volume) override; | 39 float noise_volume) override; |
| 40 | 40 |
| 41 // SpeechRecognitionManagerDelegate methods. | 41 // SpeechRecognitionManagerDelegate methods. |
| 42 void GetDiagnosticInformation(bool* can_report_metrics, | |
| 43 std::string* hardware_info) override; | |
| 44 void CheckRecognitionIsAllowed( | 42 void CheckRecognitionIsAllowed( |
| 45 int session_id, | 43 int session_id, |
| 46 base::Callback<void(bool ask_user, bool is_allowed)> callback) override; | 44 base::Callback<void(bool ask_user, bool is_allowed)> callback) override; |
| 47 content::SpeechRecognitionEventListener* GetEventListener() override; | 45 content::SpeechRecognitionEventListener* GetEventListener() override; |
| 48 bool FilterProfanities(int render_process_id) override; | 46 bool FilterProfanities(int render_process_id) override; |
| 49 | 47 |
| 50 static void CheckRenderViewType( | 48 static void CheckRenderViewType( |
| 51 base::Callback<void(bool ask_user, bool is_allowed)> callback, | 49 base::Callback<void(bool ask_user, bool is_allowed)> callback, |
| 52 int render_process_id, | 50 int render_process_id, |
| 53 int render_view_id); | 51 int render_view_id); |
| 54 | 52 |
| 55 DISALLOW_COPY_AND_ASSIGN(ShellSpeechRecognitionManagerDelegate); | 53 DISALLOW_COPY_AND_ASSIGN(ShellSpeechRecognitionManagerDelegate); |
| 56 }; | 54 }; |
| 57 | 55 |
| 58 } // namespace speech | 56 } // namespace speech |
| 59 } // namespace extensions | 57 } // namespace extensions |
| 60 | 58 |
| 61 #endif // EXTENSIONS_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ | 59 #endif // EXTENSIONS_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |