| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All Rights Reserved. | 2 * Copyright (C) 2010 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 24 matching lines...) Expand all Loading... |
| 35 class Event; | 35 class Event; |
| 36 class Node; | 36 class Node; |
| 37 | 37 |
| 38 class EventContext { | 38 class EventContext { |
| 39 public: | 39 public: |
| 40 // FIXME: Use ContainerNode instead of Node. | 40 // FIXME: Use ContainerNode instead of Node. |
| 41 EventContext(PassRefPtr<Node>, PassRefPtr<EventTarget> currentTarget, PassRe
fPtr<EventTarget> target); | 41 EventContext(PassRefPtr<Node>, PassRefPtr<EventTarget> currentTarget, PassRe
fPtr<EventTarget> target); |
| 42 | 42 |
| 43 Node* node() const; | 43 Node* node() const; |
| 44 EventTarget* target() const; | 44 EventTarget* target() const; |
| 45 void defaultEventHandler(Event*) const; | |
| 46 void handleLocalEvents(Event*) const; | 45 void handleLocalEvents(Event*) const; |
| 47 | 46 |
| 48 private: | 47 private: |
| 49 RefPtr<Node> m_node; | 48 RefPtr<Node> m_node; |
| 50 RefPtr<EventTarget> m_currentTarget; | 49 RefPtr<EventTarget> m_currentTarget; |
| 51 RefPtr<EventTarget> m_target; | 50 RefPtr<EventTarget> m_target; |
| 52 }; | 51 }; |
| 53 | 52 |
| 54 inline Node* EventContext::node() const | 53 inline Node* EventContext::node() const |
| 55 { | 54 { |
| 56 return m_node.get(); | 55 return m_node.get(); |
| 57 } | 56 } |
| 58 | 57 |
| 59 inline EventTarget* EventContext::target() const | 58 inline EventTarget* EventContext::target() const |
| 60 { | 59 { |
| 61 return m_target.get(); | 60 return m_target.get(); |
| 62 } | 61 } |
| 63 | 62 |
| 64 } | 63 } |
| 65 | 64 |
| 66 #endif // EventContext_h | 65 #endif // EventContext_h |
| OLD | NEW |