clang-format chromium_src
This commit is contained in:
parent
c090dd2f81
commit
8cc81509d7
38 changed files with 202 additions and 231 deletions
|
@ -40,11 +40,7 @@ enum TtsEventType {
|
|||
TTS_EVENT_RESUME
|
||||
};
|
||||
|
||||
enum TtsGenderType {
|
||||
TTS_GENDER_NONE,
|
||||
TTS_GENDER_MALE,
|
||||
TTS_GENDER_FEMALE
|
||||
};
|
||||
enum TtsGenderType { TTS_GENDER_NONE, TTS_GENDER_MALE, TTS_GENDER_FEMALE };
|
||||
|
||||
// Returns true if this event type is one that indicates an utterance
|
||||
// is finished and can be destroyed.
|
||||
|
@ -167,14 +163,10 @@ class Utterance {
|
|||
}
|
||||
const std::string& voice_name() const { return voice_name_; }
|
||||
|
||||
void set_lang(const std::string& lang) {
|
||||
lang_ = lang;
|
||||
}
|
||||
void set_lang(const std::string& lang) { lang_ = lang; }
|
||||
const std::string& lang() const { return lang_; }
|
||||
|
||||
void set_gender(TtsGenderType gender) {
|
||||
gender_ = gender;
|
||||
}
|
||||
void set_gender(TtsGenderType gender) { gender_ = gender; }
|
||||
TtsGenderType gender() const { return gender_; }
|
||||
|
||||
void set_continuous_parameters(const UtteranceContinuousParameters& params) {
|
||||
|
|
|
@ -35,9 +35,9 @@ class TtsControllerImpl : public TtsController {
|
|||
virtual void Pause() override;
|
||||
virtual void Resume() override;
|
||||
virtual void OnTtsEvent(int utterance_id,
|
||||
TtsEventType event_type,
|
||||
int char_index,
|
||||
const std::string& error_message) override;
|
||||
TtsEventType event_type,
|
||||
int char_index,
|
||||
const std::string& error_message) override;
|
||||
virtual void GetVoices(content::BrowserContext* browser_context,
|
||||
std::vector<VoiceData>* out_voices) override;
|
||||
virtual void VoicesChanged() override;
|
||||
|
|
|
@ -14,18 +14,16 @@ namespace content {
|
|||
class BrowserContext;
|
||||
}
|
||||
|
||||
class TtsMessageFilter
|
||||
: public content::BrowserMessageFilter,
|
||||
public UtteranceEventDelegate,
|
||||
public VoicesChangedDelegate {
|
||||
class TtsMessageFilter : public content::BrowserMessageFilter,
|
||||
public UtteranceEventDelegate,
|
||||
public VoicesChangedDelegate {
|
||||
public:
|
||||
explicit TtsMessageFilter(int render_process_id,
|
||||
content::BrowserContext* browser_context);
|
||||
content::BrowserContext* browser_context);
|
||||
|
||||
// content::BrowserMessageFilter implementation.
|
||||
void OverrideThreadForMessage(
|
||||
const IPC::Message& message,
|
||||
content::BrowserThread::ID* thread) override;
|
||||
void OverrideThreadForMessage(const IPC::Message& message,
|
||||
content::BrowserThread::ID* thread) override;
|
||||
bool OnMessageReceived(const IPC::Message& message) override;
|
||||
void OnChannelClosing() override;
|
||||
void OnDestruct() const override;
|
||||
|
|
|
@ -33,12 +33,11 @@ class TtsPlatformImpl {
|
|||
// The TtsController will only try to speak one utterance at
|
||||
// a time. If it wants to interrupt speech, it will always call Stop
|
||||
// before speaking again.
|
||||
virtual bool Speak(
|
||||
int utterance_id,
|
||||
const std::string& utterance,
|
||||
const std::string& lang,
|
||||
const VoiceData& voice,
|
||||
const UtteranceContinuousParameters& params) = 0;
|
||||
virtual bool Speak(int utterance_id,
|
||||
const std::string& utterance,
|
||||
const std::string& lang,
|
||||
const VoiceData& voice,
|
||||
const UtteranceContinuousParameters& params) = 0;
|
||||
|
||||
// Stop speaking immediately and return true on success.
|
||||
virtual bool StopSpeaking() = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue