/work/obj-fuzz/dist/include/mozilla/dom/FocusEvent.h
Line | Count | Source (jump to first uncovered line) |
1 | | /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
2 | | /* vim: set ts=8 sts=2 et sw=2 tw=80: */ |
3 | | /* This Source Code Form is subject to the terms of the Mozilla Public |
4 | | * License, v. 2.0. If a copy of the MPL was not distributed with this |
5 | | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
6 | | #ifndef mozilla_dom_FocusEvent_h_ |
7 | | #define mozilla_dom_FocusEvent_h_ |
8 | | |
9 | | #include "mozilla/dom/FocusEventBinding.h" |
10 | | #include "mozilla/dom/UIEvent.h" |
11 | | #include "mozilla/EventForwards.h" |
12 | | |
13 | | namespace mozilla { |
14 | | namespace dom { |
15 | | |
16 | | class FocusEvent : public UIEvent |
17 | | { |
18 | | public: |
19 | | NS_INLINE_DECL_REFCOUNTING_INHERITED(FocusEvent, UIEvent) |
20 | | |
21 | | virtual JSObject* WrapObjectInternal(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override |
22 | 0 | { |
23 | 0 | return FocusEvent_Binding::Wrap(aCx, this, aGivenProto); |
24 | 0 | } |
25 | | |
26 | | FocusEvent(EventTarget* aOwner, |
27 | | nsPresContext* aPresContext, |
28 | | InternalFocusEvent* aEvent); |
29 | | |
30 | | already_AddRefed<EventTarget> GetRelatedTarget(); |
31 | | |
32 | | static already_AddRefed<FocusEvent> Constructor(const GlobalObject& aGlobal, |
33 | | const nsAString& aType, |
34 | | const FocusEventInit& aParam, |
35 | | ErrorResult& aRv); |
36 | | protected: |
37 | 0 | ~FocusEvent() {} |
38 | | |
39 | | void InitFocusEvent(const nsAString& aType, |
40 | | bool aCanBubble, |
41 | | bool aCancelable, |
42 | | nsGlobalWindowInner* aView, |
43 | | int32_t aDetail, |
44 | | EventTarget* aRelatedTarget); |
45 | | }; |
46 | | |
47 | | } // namespace dom |
48 | | } // namespace mozilla |
49 | | |
50 | | already_AddRefed<mozilla::dom::FocusEvent> |
51 | | NS_NewDOMFocusEvent(mozilla::dom::EventTarget* aOwner, |
52 | | nsPresContext* aPresContext, |
53 | | mozilla::InternalFocusEvent* aEvent); |
54 | | |
55 | | #endif // mozilla_dom_FocusEvent_h_ |