| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 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 27 matching lines...) Expand all Loading... |
| 38 : Event(type, initializer) | 38 : Event(type, initializer) |
| 39 { | 39 { |
| 40 if (initializer.hasDetail()) | 40 if (initializer.hasDetail()) |
| 41 m_detail = initializer.detail(); | 41 m_detail = initializer.detail(); |
| 42 } | 42 } |
| 43 | 43 |
| 44 CustomEvent::~CustomEvent() | 44 CustomEvent::~CustomEvent() |
| 45 { | 45 { |
| 46 } | 46 } |
| 47 | 47 |
| 48 void CustomEvent::initCustomEvent(const AtomicString& type, bool canBubble, bool
cancelable, const ScriptValue& detail) |
| 49 { |
| 50 initEvent(type, canBubble, cancelable); |
| 51 m_detail = detail; |
| 52 } |
| 53 |
| 48 void CustomEvent::initCustomEvent(const AtomicString& type, bool canBubble, bool
cancelable, PassRefPtr<SerializedScriptValue> serializedDetail) | 54 void CustomEvent::initCustomEvent(const AtomicString& type, bool canBubble, bool
cancelable, PassRefPtr<SerializedScriptValue> serializedDetail) |
| 49 { | 55 { |
| 50 if (dispatched()) | 56 if (dispatched()) |
| 51 return; | 57 return; |
| 52 | 58 |
| 53 initEvent(type, canBubble, cancelable); | 59 initEvent(type, canBubble, cancelable); |
| 54 | 60 |
| 55 m_serializedDetail = serializedDetail; | 61 m_serializedDetail = serializedDetail; |
| 56 } | 62 } |
| 57 | 63 |
| 58 const AtomicString& CustomEvent::interfaceName() const | 64 const AtomicString& CustomEvent::interfaceName() const |
| 59 { | 65 { |
| 60 return EventNames::CustomEvent; | 66 return EventNames::CustomEvent; |
| 61 } | 67 } |
| 62 | 68 |
| 63 DEFINE_TRACE(CustomEvent) | 69 DEFINE_TRACE(CustomEvent) |
| 64 { | 70 { |
| 65 Event::trace(visitor); | 71 Event::trace(visitor); |
| 66 } | 72 } |
| 67 | 73 |
| 68 } // namespace blink | 74 } // namespace blink |
| OLD | NEW |