Line data Source code
1 : /* THIS FILE IS AUTOGENERATED FROM DecoderDoctorNotification.webidl BY Codegen.py - DO NOT EDIT */
2 :
3 : #ifndef mozilla_dom_DecoderDoctorNotificationBinding_h
4 : #define mozilla_dom_DecoderDoctorNotificationBinding_h
5 :
6 : #include "js/RootingAPI.h"
7 : #include "jspubtd.h"
8 : #include "mozilla/ErrorResult.h"
9 : #include "mozilla/dom/BindingDeclarations.h"
10 : #include "mozilla/dom/Nullable.h"
11 :
12 : namespace mozilla {
13 : namespace dom {
14 :
15 : struct DecoderDoctorNotificationAtoms;
16 : struct NativePropertyHooks;
17 : class ProtoAndIfaceCache;
18 :
19 : } // namespace dom
20 : } // namespace mozilla
21 :
22 : namespace mozilla {
23 : namespace dom {
24 :
25 : enum class DecoderDoctorNotificationType : uint8_t {
26 : Cannot_play,
27 : Platform_decoder_not_found,
28 : Can_play_but_some_missing_decoders,
29 : Cannot_initialize_pulseaudio,
30 : Unsupported_libavcodec,
31 : Decode_error,
32 : Decode_warning,
33 : EndGuard_
34 : };
35 :
36 : namespace DecoderDoctorNotificationTypeValues {
37 : extern const EnumEntry strings[8];
38 : } // namespace DecoderDoctorNotificationTypeValues
39 :
40 : bool
41 : ToJSValue(JSContext* aCx, DecoderDoctorNotificationType aArgument, JS::MutableHandle<JS::Value> aValue);
42 :
43 :
44 0 : struct DecoderDoctorNotification : public DictionaryBase
45 : {
46 : MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mDecodeIssue;
47 : MOZ_INIT_OUTSIDE_CTOR nsString mDecoderDoctorReportId;
48 : MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mDocURL;
49 : MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mFormats;
50 : MOZ_INIT_OUTSIDE_CTOR bool mIsSolved;
51 : MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mResourceURL;
52 : MOZ_INIT_OUTSIDE_CTOR DecoderDoctorNotificationType mType;
53 :
54 : DecoderDoctorNotification();
55 :
56 : explicit inline DecoderDoctorNotification(const FastDictionaryInitializer& )
57 : {
58 : // Do nothing here; this is used by our "Fast" subclass
59 : }
60 :
61 : explicit inline DecoderDoctorNotification(const DecoderDoctorNotification& aOther)
62 : {
63 : *this = aOther;
64 : }
65 :
66 : bool
67 : Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
68 :
69 : bool
70 : Init(const nsAString& aJSON);
71 :
72 : bool
73 : ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
74 :
75 : bool
76 : ToJSON(nsAString& aJSON) const;
77 :
78 : void
79 : TraceDictionary(JSTracer* trc);
80 :
81 : DecoderDoctorNotification&
82 : operator=(const DecoderDoctorNotification& aOther);
83 :
84 : private:
85 : static bool
86 : InitIds(JSContext* cx, DecoderDoctorNotificationAtoms* atomsCache);
87 : };
88 :
89 : namespace binding_detail {
90 : struct FastDecoderDoctorNotification : public DecoderDoctorNotification
91 : {
92 : inline FastDecoderDoctorNotification()
93 : : DecoderDoctorNotification(FastDictionaryInitializer())
94 : {
95 : // Doesn't matter what int we pass to the parent constructor
96 : }
97 : };
98 : } // namespace binding_detail
99 :
100 :
101 : } // namespace dom
102 : } // namespace mozilla
103 :
104 : #endif // mozilla_dom_DecoderDoctorNotificationBinding_h
|