OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 30 matching lines...) Expand all Loading... |
41 return EventNames::FocusEvent; | 41 return EventNames::FocusEvent; |
42 } | 42 } |
43 | 43 |
44 bool FocusEvent::isFocusEvent() const | 44 bool FocusEvent::isFocusEvent() const |
45 { | 45 { |
46 return true; | 46 return true; |
47 } | 47 } |
48 | 48 |
49 FocusEvent::FocusEvent() | 49 FocusEvent::FocusEvent() |
50 { | 50 { |
51 ScriptWrappable::init(this); | |
52 } | 51 } |
53 | 52 |
54 FocusEvent::FocusEvent(const AtomicString& type, bool canBubble, bool cancelable
, PassRefPtrWillBeRawPtr<AbstractView> view, int detail, EventTarget* relatedTar
get) | 53 FocusEvent::FocusEvent(const AtomicString& type, bool canBubble, bool cancelable
, PassRefPtrWillBeRawPtr<AbstractView> view, int detail, EventTarget* relatedTar
get) |
55 : UIEvent(type, canBubble, cancelable, view, detail) | 54 : UIEvent(type, canBubble, cancelable, view, detail) |
56 , m_relatedTarget(relatedTarget) | 55 , m_relatedTarget(relatedTarget) |
57 { | 56 { |
58 ScriptWrappable::init(this); | |
59 } | 57 } |
60 | 58 |
61 FocusEvent::FocusEvent(const AtomicString& type, const FocusEventInit& initializ
er) | 59 FocusEvent::FocusEvent(const AtomicString& type, const FocusEventInit& initializ
er) |
62 : UIEvent(type, initializer) | 60 : UIEvent(type, initializer) |
63 , m_relatedTarget(initializer.relatedTarget) | 61 , m_relatedTarget(initializer.relatedTarget) |
64 { | 62 { |
65 ScriptWrappable::init(this); | |
66 } | 63 } |
67 | 64 |
68 void FocusEvent::trace(Visitor* visitor) | 65 void FocusEvent::trace(Visitor* visitor) |
69 { | 66 { |
70 visitor->trace(m_relatedTarget); | 67 visitor->trace(m_relatedTarget); |
71 UIEvent::trace(visitor); | 68 UIEvent::trace(visitor); |
72 } | 69 } |
73 | 70 |
74 PassRefPtrWillBeRawPtr<FocusEventDispatchMediator> FocusEventDispatchMediator::c
reate(PassRefPtrWillBeRawPtr<FocusEvent> focusEvent) | 71 PassRefPtrWillBeRawPtr<FocusEventDispatchMediator> FocusEventDispatchMediator::c
reate(PassRefPtrWillBeRawPtr<FocusEvent> focusEvent) |
75 { | 72 { |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 { | 126 { |
130 } | 127 } |
131 | 128 |
132 bool FocusOutEventDispatchMediator::dispatchEvent(EventDispatcher* dispatcher) c
onst | 129 bool FocusOutEventDispatchMediator::dispatchEvent(EventDispatcher* dispatcher) c
onst |
133 { | 130 { |
134 event()->eventPath().adjustForRelatedTarget(dispatcher->node(), event()->rel
atedTarget()); | 131 event()->eventPath().adjustForRelatedTarget(dispatcher->node(), event()->rel
atedTarget()); |
135 return EventDispatchMediator::dispatchEvent(dispatcher); | 132 return EventDispatchMediator::dispatchEvent(dispatcher); |
136 } | 133 } |
137 | 134 |
138 } // namespace blink | 135 } // namespace blink |
OLD | NEW |