| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 6 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 6 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 7 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> | 7 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 8 * | 8 * |
| 9 * Redistribution and use in source and binary forms, with or without | 9 * Redistribution and use in source and binary forms, with or without |
| 10 * modification, are permitted provided that the following conditions | 10 * modification, are permitted provided that the following conditions |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 virtual ExecutionContext* executionContext() const = 0; | 115 virtual ExecutionContext* executionContext() const = 0; |
| 116 | 116 |
| 117 virtual Node* toNode(); | 117 virtual Node* toNode(); |
| 118 virtual LocalDOMWindow* toDOMWindow(); | 118 virtual LocalDOMWindow* toDOMWindow(); |
| 119 virtual MessagePort* toMessagePort(); | 119 virtual MessagePort* toMessagePort(); |
| 120 | 120 |
| 121 // FIXME: first 2 args to addEventListener and removeEventListener should | 121 // FIXME: first 2 args to addEventListener and removeEventListener should |
| 122 // be required (per spec), but throwing TypeError breaks legacy content. | 122 // be required (per spec), but throwing TypeError breaks legacy content. |
| 123 // http://crbug.com/353484 | 123 // http://crbug.com/353484 |
| 124 bool addEventListener(); | 124 bool addEventListener(); |
| 125 bool addEventListener(const AtomicString& eventType); | |
| 126 virtual bool addEventListener(const AtomicString& eventType, PassRefPtr<Even
tListener>, bool useCapture = false); | 125 virtual bool addEventListener(const AtomicString& eventType, PassRefPtr<Even
tListener>, bool useCapture = false); |
| 127 bool removeEventListener(); | 126 bool removeEventListener(); |
| 128 bool removeEventListener(const AtomicString& eventType); | |
| 129 virtual bool removeEventListener(const AtomicString& eventType, PassRefPtr<E
ventListener>, bool useCapture = false); | 127 virtual bool removeEventListener(const AtomicString& eventType, PassRefPtr<E
ventListener>, bool useCapture = false); |
| 130 virtual void removeAllEventListeners(); | 128 virtual void removeAllEventListeners(); |
| 131 virtual bool dispatchEvent(PassRefPtrWillBeRawPtr<Event>); | 129 virtual bool dispatchEvent(PassRefPtrWillBeRawPtr<Event>); |
| 132 bool dispatchEvent(PassRefPtrWillBeRawPtr<Event>, ExceptionState&); // DOM A
PI | 130 bool dispatchEvent(PassRefPtrWillBeRawPtr<Event>, ExceptionState&); // DOM A
PI |
| 133 virtual void uncaughtExceptionInEventHandler(); | 131 virtual void uncaughtExceptionInEventHandler(); |
| 134 | 132 |
| 135 // Used for legacy "onEvent" attribute APIs. | 133 // Used for legacy "onEvent" attribute APIs. |
| 136 bool setAttributeEventListener(const AtomicString& eventType, PassRefPtr<Eve
ntListener>); | 134 bool setAttributeEventListener(const AtomicString& eventType, PassRefPtr<Eve
ntListener>); |
| 137 EventListener* getAttributeEventListener(const AtomicString& eventType); | 135 EventListener* getAttributeEventListener(const AtomicString& eventType); |
| 138 | 136 |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 #define DEFINE_EVENT_TARGET_REFCOUNTING_WILL_BE_REMOVED(baseClass) DEFINE_EVENT_
TARGET_REFCOUNTING(baseClass) | 294 #define DEFINE_EVENT_TARGET_REFCOUNTING_WILL_BE_REMOVED(baseClass) DEFINE_EVENT_
TARGET_REFCOUNTING(baseClass) |
| 297 | 295 |
| 298 #endif // ENABLE(OILPAN) | 296 #endif // ENABLE(OILPAN) |
| 299 | 297 |
| 300 // Use this macro if your EventTarget subclass is also a subclass of WTF::RefCou
nted. | 298 // Use this macro if your EventTarget subclass is also a subclass of WTF::RefCou
nted. |
| 301 // A ref-counted class that uses a different method of refcounting should use DE
FINE_EVENT_TARGET_REFCOUNTING directly. | 299 // A ref-counted class that uses a different method of refcounting should use DE
FINE_EVENT_TARGET_REFCOUNTING directly. |
| 302 // Both of these macros are meant to be placed just before the "public:" section
of the class declaration. | 300 // Both of these macros are meant to be placed just before the "public:" section
of the class declaration. |
| 303 #define REFCOUNTED_EVENT_TARGET(className) DEFINE_EVENT_TARGET_REFCOUNTING_WILL_
BE_REMOVED(RefCounted<className>) | 301 #define REFCOUNTED_EVENT_TARGET(className) DEFINE_EVENT_TARGET_REFCOUNTING_WILL_
BE_REMOVED(RefCounted<className>) |
| 304 | 302 |
| 305 #endif // EventTarget_h | 303 #endif // EventTarget_h |
| OLD | NEW |