Line data Source code
1 : /* THIS FILE IS AUTOGENERATED FROM PluginCrashedEvent.webidl BY Codegen.py - DO NOT EDIT */
2 :
3 : #ifndef mozilla_dom_PluginCrashedEventBinding_h
4 : #define mozilla_dom_PluginCrashedEventBinding_h
5 :
6 : #include "EventBinding.h"
7 : #include "js/RootingAPI.h"
8 : #include "jspubtd.h"
9 : #include "mozilla/ErrorResult.h"
10 : #include "mozilla/dom/BindingDeclarations.h"
11 : #include "mozilla/dom/Nullable.h"
12 :
13 : namespace mozilla {
14 : namespace dom {
15 :
16 : struct NativePropertyHooks;
17 : class PluginCrashedEvent;
18 : struct PluginCrashedEventAtoms;
19 : struct PluginCrashedEventInitAtoms;
20 : class ProtoAndIfaceCache;
21 :
22 : } // namespace dom
23 : } // namespace mozilla
24 :
25 : namespace mozilla {
26 : namespace dom {
27 :
28 0 : struct PluginCrashedEventInit : public EventInit
29 : {
30 : MOZ_INIT_OUTSIDE_CTOR nsString mBrowserDumpID;
31 : MOZ_INIT_OUTSIDE_CTOR bool mGmpPlugin;
32 : MOZ_INIT_OUTSIDE_CTOR nsString mPluginDumpID;
33 : MOZ_INIT_OUTSIDE_CTOR nsString mPluginFilename;
34 : MOZ_INIT_OUTSIDE_CTOR uint32_t mPluginID;
35 : MOZ_INIT_OUTSIDE_CTOR nsString mPluginName;
36 : MOZ_INIT_OUTSIDE_CTOR bool mSubmittedCrashReport;
37 :
38 : PluginCrashedEventInit();
39 :
40 0 : explicit inline PluginCrashedEventInit(const FastDictionaryInitializer& )
41 0 : : EventInit(FastDictionaryInitializer())
42 : {
43 : // Do nothing here; this is used by our "Fast" subclass
44 0 : }
45 :
46 : explicit inline PluginCrashedEventInit(const PluginCrashedEventInit& aOther)
47 : {
48 : *this = aOther;
49 : }
50 :
51 : bool
52 : Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
53 :
54 : bool
55 : Init(const nsAString& aJSON);
56 :
57 : bool
58 : ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
59 :
60 : bool
61 : ToJSON(nsAString& aJSON) const;
62 :
63 : void
64 : TraceDictionary(JSTracer* trc);
65 :
66 : PluginCrashedEventInit&
67 : operator=(const PluginCrashedEventInit& aOther);
68 :
69 : private:
70 : static bool
71 : InitIds(JSContext* cx, PluginCrashedEventInitAtoms* atomsCache);
72 : };
73 :
74 : namespace binding_detail {
75 0 : struct FastPluginCrashedEventInit : public PluginCrashedEventInit
76 : {
77 0 : inline FastPluginCrashedEventInit()
78 0 : : PluginCrashedEventInit(FastDictionaryInitializer())
79 : {
80 : // Doesn't matter what int we pass to the parent constructor
81 0 : }
82 : };
83 : } // namespace binding_detail
84 :
85 :
86 : namespace PluginCrashedEventBinding {
87 :
88 : typedef mozilla::dom::PluginCrashedEvent NativeType;
89 :
90 : bool
91 : ConstructorEnabled(JSContext* aCx, JS::Handle<JSObject*> aObj);
92 :
93 : JSObject*
94 : DefineDOMInterface(JSContext* aCx, JS::Handle<JSObject*> aGlobal, JS::Handle<jsid> id, bool aDefineOnGlobal);
95 :
96 : const JSClass*
97 : GetJSClass();
98 :
99 : bool
100 : Wrap(JSContext* aCx, mozilla::dom::PluginCrashedEvent* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
101 :
102 : template <class T>
103 0 : inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
104 : {
105 0 : JS::Rooted<JSObject*> reflector(aCx);
106 0 : return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
107 : }
108 :
109 : // We declare this as an array so that retrieving a pointer to this
110 : // binding's property hooks only requires compile/link-time resolvable
111 : // address arithmetic. Declaring it as a pointer instead would require
112 : // doing a run-time load to fetch a pointer to this binding's property
113 : // hooks. And then structures which embedded a pointer to this structure
114 : // would require a run-time load for proper initialization, which would
115 : // then induce static constructors. Lots of static constructors.
116 : extern const NativePropertyHooks sNativePropertyHooks[];
117 :
118 : void
119 : CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
120 :
121 : JS::Handle<JSObject*>
122 : GetProtoObjectHandle(JSContext* aCx);
123 :
124 : JS::Handle<JSObject*>
125 : GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true);
126 :
127 : JSObject*
128 : GetConstructorObject(JSContext* aCx);
129 :
130 : } // namespace PluginCrashedEventBinding
131 :
132 :
133 :
134 : } // namespace dom
135 : } // namespace mozilla
136 :
137 : #endif // mozilla_dom_PluginCrashedEventBinding_h
|