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

Side by Side Diff: content/public/browser/speech_recognition_manager_delegate.h

Issue 9972008: Refactoring of chrome speech recognition architecture (CL1.6) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased from master (incl. leak patch) Created 8 years, 8 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 | Annotate | Revision Log
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 #ifndef CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ 6 #define CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 20 matching lines...) Expand all
31 virtual ~SpeechRecognitionManagerDelegate() {} 31 virtual ~SpeechRecognitionManagerDelegate() {}
32 32
33 // Get the optional request information if available. 33 // Get the optional request information if available.
34 virtual void GetRequestInfo(bool* can_report_metrics, 34 virtual void GetRequestInfo(bool* can_report_metrics,
35 std::string* request_info) = 0; 35 std::string* request_info) = 0;
36 36
37 // Called when recognition has been requested from point |element_rect_| on 37 // Called when recognition has been requested from point |element_rect_| on
38 // the view port for the given caller. The embedder should call the 38 // the view port for the given caller. The embedder should call the
39 // StartRecognition or CancelRecognition methods on SpeechInutManager in 39 // StartRecognition or CancelRecognition methods on SpeechInutManager in
40 // response. 40 // response.
41 virtual void ShowRecognitionRequested(int caller_id, 41 virtual void ShowRecognitionRequested(int session_id,
42 int render_process_id, 42 int render_process_id,
43 int render_view_id, 43 int render_view_id,
44 const gfx::Rect& element_rect) = 0; 44 const gfx::Rect& element_rect) = 0;
45 45
46 // Called when recognition is starting up. 46 // Called when recognition is starting up.
47 virtual void ShowWarmUp(int caller_id) = 0; 47 virtual void ShowWarmUp(int session_id) = 0;
48 48
49 // Called when recognition has started. 49 // Called when recognition has started.
50 virtual void ShowRecognizing(int caller_id) = 0; 50 virtual void ShowRecognizing(int session_id) = 0;
51 51
52 // Called when recording has started. 52 // Called when recording has started.
53 virtual void ShowRecording(int caller_id) = 0; 53 virtual void ShowRecording(int session_id) = 0;
54 54
55 // Continuously updated with the current input volume. 55 // Continuously updated with the current input volume.
56 virtual void ShowInputVolume(int caller_id, 56 virtual void ShowInputVolume(int session_id,
57 float volume, 57 float volume,
58 float noise_volume) = 0; 58 float noise_volume) = 0;
59 59
60 // Called when no microphone has been found. 60 // Called when no microphone has been found.
61 virtual void ShowMicError(int caller_id, MicError error) = 0; 61 virtual void ShowMicError(int session_id, MicError error) = 0;
62 62
63 // Called when there has been a error with the recognition. 63 // Called when there has been a error with the recognition.
64 virtual void ShowRecognizerError(int caller_id, 64 virtual void ShowRecognizerError(int session_id,
65 SpeechRecognitionErrorCode error) = 0; 65 SpeechRecognitionErrorCode error) = 0;
66 66
67 // Called when recognition has ended or has been canceled. 67 // Called when recognition has ended or has been canceled.
68 virtual void DoClose(int caller_id) = 0; 68 virtual void DoClose(int session_id) = 0;
69 }; 69 };
70 70
71 } // namespace content 71 } // namespace content
72 72
73 #endif // CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_ 73 #endif // CONTENT_PUBLIC_BROWSER_SPEECH_RECOGNITION_MANAGER_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698