| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2013 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 | 48 |
| 49 bool pending() const; | 49 bool pending() const; |
| 50 bool speaking() const; | 50 bool speaking() const; |
| 51 bool paused() const; | 51 bool paused() const; |
| 52 | 52 |
| 53 void speak(SpeechSynthesisUtterance*, ExceptionState&); | 53 void speak(SpeechSynthesisUtterance*, ExceptionState&); |
| 54 void cancel(); | 54 void cancel(); |
| 55 void pause(); | 55 void pause(); |
| 56 void resume(); | 56 void resume(); |
| 57 | 57 |
| 58 const HeapVector<Member<SpeechSynthesisVoice> >& getVoices(); | 58 const HeapVector<Member<SpeechSynthesisVoice>>& getVoices(); |
| 59 | 59 |
| 60 // Used in testing to use a mock platform synthesizer | 60 // Used in testing to use a mock platform synthesizer |
| 61 void setPlatformSynthesizer(PlatformSpeechSynthesizer*); | 61 void setPlatformSynthesizer(PlatformSpeechSynthesizer*); |
| 62 | 62 |
| 63 DEFINE_ATTRIBUTE_EVENT_LISTENER(voiceschanged); | 63 DEFINE_ATTRIBUTE_EVENT_LISTENER(voiceschanged); |
| 64 | 64 |
| 65 virtual ExecutionContext* executionContext() const override; | 65 virtual ExecutionContext* executionContext() const override; |
| 66 | 66 |
| 67 virtual void trace(Visitor*) override; | 67 virtual void trace(Visitor*) override; |
| 68 | 68 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 79 virtual void boundaryEventOccurred(PlatformSpeechSynthesisUtterance*, Speech
Boundary, unsigned charIndex) override; | 79 virtual void boundaryEventOccurred(PlatformSpeechSynthesisUtterance*, Speech
Boundary, unsigned charIndex) override; |
| 80 | 80 |
| 81 void startSpeakingImmediately(); | 81 void startSpeakingImmediately(); |
| 82 void handleSpeakingCompleted(SpeechSynthesisUtterance*, bool errorOccurred); | 82 void handleSpeakingCompleted(SpeechSynthesisUtterance*, bool errorOccurred); |
| 83 void fireEvent(const AtomicString& type, SpeechSynthesisUtterance*, unsigned
long charIndex, const String& name); | 83 void fireEvent(const AtomicString& type, SpeechSynthesisUtterance*, unsigned
long charIndex, const String& name); |
| 84 | 84 |
| 85 // Returns the utterance at the front of the queue. | 85 // Returns the utterance at the front of the queue. |
| 86 SpeechSynthesisUtterance* currentSpeechUtterance() const; | 86 SpeechSynthesisUtterance* currentSpeechUtterance() const; |
| 87 | 87 |
| 88 Member<PlatformSpeechSynthesizer> m_platformSpeechSynthesizer; | 88 Member<PlatformSpeechSynthesizer> m_platformSpeechSynthesizer; |
| 89 HeapVector<Member<SpeechSynthesisVoice> > m_voiceList; | 89 HeapVector<Member<SpeechSynthesisVoice>> m_voiceList; |
| 90 HeapDeque<Member<SpeechSynthesisUtterance> > m_utteranceQueue; | 90 HeapDeque<Member<SpeechSynthesisUtterance>> m_utteranceQueue; |
| 91 bool m_isPaused; | 91 bool m_isPaused; |
| 92 | 92 |
| 93 // EventTarget | 93 // EventTarget |
| 94 virtual const AtomicString& interfaceName() const override; | 94 virtual const AtomicString& interfaceName() const override; |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 } // namespace blink | 97 } // namespace blink |
| 98 | 98 |
| 99 #endif // SpeechSynthesisEvent_h | 99 #endif // SpeechSynthesisEvent_h |
| OLD | NEW |