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

Side by Side Diff: content/browser/speech/speech_input_manager.h

Issue 6610022: Enable speech input by default and remove unused code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « content/browser/speech/speech_input_dispatcher_host.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 CONTENT_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ 5 #ifndef CONTENT_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_
6 #define CONTENT_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ 6 #define CONTENT_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 "ui/gfx/rect.h" 10 #include "ui/gfx/rect.h"
(...skipping 13 matching lines...) Expand all
24 virtual void SetRecognitionResult( 24 virtual void SetRecognitionResult(
25 int caller_id, 25 int caller_id,
26 const SpeechInputResultArray& result) = 0; 26 const SpeechInputResultArray& result) = 0;
27 virtual void DidCompleteRecording(int caller_id) = 0; 27 virtual void DidCompleteRecording(int caller_id) = 0;
28 virtual void DidCompleteRecognition(int caller_id) = 0; 28 virtual void DidCompleteRecognition(int caller_id) = 0;
29 29
30 protected: 30 protected:
31 virtual ~Delegate() {} 31 virtual ~Delegate() {}
32 }; 32 };
33 33
34 // Whether the speech input feature is enabled, based on the browser channel
35 // information and command line flags.
36 static bool IsFeatureEnabled();
37
38 // Invokes the platform provided microphone settings UI in a non-blocking way, 34 // Invokes the platform provided microphone settings UI in a non-blocking way,
39 // via the BrowserThread::FILE thread. 35 // via the BrowserThread::FILE thread.
40 static void ShowAudioInputSettings(); 36 static void ShowAudioInputSettings();
41 37
42 // Factory method to access the singleton. We have this method here instead of 38 // Factory method to access the singleton. We have this method here instead of
43 // using Singleton directly in the calling code to aid tests in injection 39 // using Singleton directly in the calling code to aid tests in injection
44 // mocks. 40 // mocks.
45 static SpeechInputManager* Get(); 41 static SpeechInputManager* Get();
46 // Factory method definition useful for tests. 42 // Factory method definition useful for tests.
47 typedef SpeechInputManager* (AccessorMethod)(); 43 typedef SpeechInputManager* (AccessorMethod)();
(...skipping 24 matching lines...) Expand all
72 68
73 // This typedef is to workaround the issue with certain versions of 69 // This typedef is to workaround the issue with certain versions of
74 // Visual Studio where it gets confused between multiple Delegate 70 // Visual Studio where it gets confused between multiple Delegate
75 // classes and gives a C2500 error. (I saw this error on the try bots - 71 // classes and gives a C2500 error. (I saw this error on the try bots -
76 // the workaround was not needed for my machine). 72 // the workaround was not needed for my machine).
77 typedef SpeechInputManager::Delegate SpeechInputManagerDelegate; 73 typedef SpeechInputManager::Delegate SpeechInputManagerDelegate;
78 74
79 } // namespace speech_input 75 } // namespace speech_input
80 76
81 #endif // CONTENT_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_ 77 #endif // CONTENT_BROWSER_SPEECH_SPEECH_INPUT_MANAGER_H_
OLDNEW
« no previous file with comments | « content/browser/speech/speech_input_dispatcher_host.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698