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

Side by Side Diff: chrome/browser/speech/tts_controller_impl.h

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 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
« no previous file with comments | « chrome/browser/speech/tts_chromeos.cc ('k') | chrome/browser/speech/tts_controller_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_ 5 #ifndef CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_
6 #define CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_ 6 #define CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_
7 7
8 #include <queue> 8 #include <queue>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 void FinishCurrentUtterance(); 68 void FinishCurrentUtterance();
69 69
70 // Start speaking the next utterance in the queue. 70 // Start speaking the next utterance in the queue.
71 void SpeakNextUtterance(); 71 void SpeakNextUtterance();
72 72
73 // Given an utterance and a vector of voices, return the 73 // Given an utterance and a vector of voices, return the
74 // index of the voice that best matches the utterance. 74 // index of the voice that best matches the utterance.
75 int GetMatchingVoice(const Utterance* utterance, 75 int GetMatchingVoice(const Utterance* utterance,
76 std::vector<VoiceData>& voices); 76 std::vector<VoiceData>& voices);
77 77
78 friend struct DefaultSingletonTraits<TtsControllerImpl>; 78 friend struct base::DefaultSingletonTraits<TtsControllerImpl>;
79 79
80 // The current utterance being spoken. 80 // The current utterance being spoken.
81 Utterance* current_utterance_; 81 Utterance* current_utterance_;
82 82
83 // Whether the queue is paused or not. 83 // Whether the queue is paused or not.
84 bool paused_; 84 bool paused_;
85 85
86 // A queue of utterances to speak after the current one finishes. 86 // A queue of utterances to speak after the current one finishes.
87 std::queue<Utterance*> utterance_queue_; 87 std::queue<Utterance*> utterance_queue_;
88 88
89 // A set of delegates that want to be notified when the voices change. 89 // A set of delegates that want to be notified when the voices change.
90 std::set<VoicesChangedDelegate*> voices_changed_delegates_; 90 std::set<VoicesChangedDelegate*> voices_changed_delegates_;
91 91
92 // A pointer to the platform implementation of text-to-speech, for 92 // A pointer to the platform implementation of text-to-speech, for
93 // dependency injection. 93 // dependency injection.
94 TtsPlatformImpl* platform_impl_; 94 TtsPlatformImpl* platform_impl_;
95 95
96 // The delegate that processes TTS requests with user-installed extensions. 96 // The delegate that processes TTS requests with user-installed extensions.
97 TtsEngineDelegate* tts_engine_delegate_; 97 TtsEngineDelegate* tts_engine_delegate_;
98 98
99 DISALLOW_COPY_AND_ASSIGN(TtsControllerImpl); 99 DISALLOW_COPY_AND_ASSIGN(TtsControllerImpl);
100 }; 100 };
101 101
102 #endif // CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_ 102 #endif // CHROME_BROWSER_SPEECH_TTS_CONTROLLER_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/speech/tts_chromeos.cc ('k') | chrome/browser/speech/tts_controller_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698