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

Side by Side Diff: Source/modules/speech/SpeechSynthesisErrorEvent.h

Issue 1044053002: [WIP] Add SpeechSynthesisErrorevent Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: updated 3rd patch Created 5 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
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/speech/SpeechSynthesisErrorEvent.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1
2 #ifndef SpeechSynthesisErrorEvent_h
3 #define SpeechSynthesisErrorEvent_h
4
5 #include "modules/EventModules.h"
6
7 #include "wtf/text/WTFString.h"
8
9 namespace blink {
10
11 class SpeechSynthesisErrorEvent final : public Event {
12 DEFINE_WRAPPERTYPEINFO();
13 public:
14 enum ErrorCode {
15 ErrorCodeNone = 0,
16 ErrorCodeCanceled = 1,
17 ErrorCodeInterrupted = 2,
18 ErrorCodeAudioBusy = 3,
19 ErrorCodeAudioHardware = 4,
20 ErrorCodeNetwork = 5,
21 ErrorCodeSynthesisUnavailable = 6,
22 ErrorCodeSynthesisFailed = 7,
23 ErrorCodeLanguageUnavailable = 8,
24 ErrorCodeVoiceUnavailable = 9,
25 ErrorCodeTextTooLong = 10,
26 ErrorCodeInvalidArgument = 11,
27 };
28
29 static PassRefPtrWillBeRawPtr<SpeechSynthesisErrorEvent> create();
30 static PassRefPtrWillBeRawPtr<SpeechSynthesisErrorEvent> create(ErrorCode);
31
32 const String& error() { return m_error; }
33
34 virtual const AtomicString& interfaceName() const override;
35
36 DEFINE_INLINE_VIRTUAL_TRACE()
37 {
38 Event::trace(visitor);
39 }
40
41
42 private:
43 SpeechSynthesisErrorEvent(const String&);
44 SpeechSynthesisErrorEvent(const AtomicString&);
45
46 String m_error;
47 };
48
49 } // namespace blink
50
51 #endif // SpeechSynthesisErrorEvent_h
OLDNEW
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/speech/SpeechSynthesisErrorEvent.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698