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