| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ |
| 6 #define CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ | 6 #define CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "chrome/common/speech_input_result.h" | 9 #include "chrome/common/speech_input_result.h" |
| 10 #include "gfx/rect.h" | 10 #include "gfx/rect.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 // its |DidCompleteRecognition| method is called or recognition is cancelled. | 47 // its |DidCompleteRecognition| method is called or recognition is cancelled. |
| 48 // |render_process_id| is the ID of the renderer process initiating the | 48 // |render_process_id| is the ID of the renderer process initiating the |
| 49 // request. | 49 // request. |
| 50 // |element_rect| is the display bounds of the html element requesting speech | 50 // |element_rect| is the display bounds of the html element requesting speech |
| 51 // input (in page coordinates). | 51 // input (in page coordinates). |
| 52 virtual void StartRecognition(Delegate* delegate, | 52 virtual void StartRecognition(Delegate* delegate, |
| 53 int caller_id, | 53 int caller_id, |
| 54 int render_process_id, | 54 int render_process_id, |
| 55 int render_view_id, | 55 int render_view_id, |
| 56 const gfx::Rect& element_rect, | 56 const gfx::Rect& element_rect, |
| 57 const std::string& language, |
| 57 const std::string& grammar) = 0; | 58 const std::string& grammar) = 0; |
| 58 virtual void CancelRecognition(int caller_id) = 0; | 59 virtual void CancelRecognition(int caller_id) = 0; |
| 59 virtual void StopRecording(int caller_id) = 0; | 60 virtual void StopRecording(int caller_id) = 0; |
| 60 }; | 61 }; |
| 61 | 62 |
| 62 // This typedef is to workaround the issue with certain versions of | 63 // This typedef is to workaround the issue with certain versions of |
| 63 // Visual Studio where it gets confused between multiple Delegate | 64 // Visual Studio where it gets confused between multiple Delegate |
| 64 // classes and gives a C2500 error. (I saw this error on the try bots - | 65 // classes and gives a C2500 error. (I saw this error on the try bots - |
| 65 // the workaround was not needed for my machine). | 66 // the workaround was not needed for my machine). |
| 66 typedef SpeechInputManager::Delegate SpeechInputManagerDelegate; | 67 typedef SpeechInputManager::Delegate SpeechInputManagerDelegate; |
| 67 | 68 |
| 68 } // namespace speech_input | 69 } // namespace speech_input |
| 69 | 70 |
| 70 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ | 71 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ |
| OLD | NEW |