Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007 Henry Mason (hmason@mac.com) | 2 * Copyright (C) 2007 Henry Mason (hmason@mac.com) |
| 3 * Copyright (C) 2003, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 3 * Copyright (C) 2003, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 47 : Event(type, initializer) | 47 : Event(type, initializer) |
| 48 , m_dataType(DataTypeScriptValue) | 48 , m_dataType(DataTypeScriptValue) |
| 49 , m_origin(initializer.origin) | 49 , m_origin(initializer.origin) |
| 50 , m_lastEventId(initializer.lastEventId) | 50 , m_lastEventId(initializer.lastEventId) |
| 51 , m_source(initializer.source) | 51 , m_source(initializer.source) |
| 52 , m_ports(adoptPtr(new MessagePortArray(initializer.ports))) | 52 , m_ports(adoptPtr(new MessagePortArray(initializer.ports))) |
| 53 { | 53 { |
| 54 ScriptWrappable::init(this); | 54 ScriptWrappable::init(this); |
| 55 } | 55 } |
| 56 | 56 |
| 57 MessageEvent::MessageEvent(const String& origin, const String& lastEventId, Pass RefPtr<DOMWindow> source, PassOwnPtr<MessagePortArray> ports) | 57 MessageEvent::MessageEvent(const String& origin, const String& lastEventId, Pass RefPtr<EventTarget> source, PassOwnPtr<MessagePortArray> ports) |
| 58 : Event(eventNames().messageEvent, false, false) | 58 : Event(eventNames().messageEvent, false, false) |
| 59 , m_dataType(DataTypeScriptValue) | 59 , m_dataType(DataTypeScriptValue) |
| 60 , m_origin(origin) | 60 , m_origin(origin) |
| 61 , m_lastEventId(lastEventId) | 61 , m_lastEventId(lastEventId) |
| 62 , m_source(source) | 62 , m_source(source) |
| 63 , m_ports(ports) | 63 , m_ports(ports) |
| 64 { | 64 { |
| 65 ScriptWrappable::init(this); | 65 ScriptWrappable::init(this); |
| 66 } | 66 } |
|
abarth-chromium
2013/08/19 19:24:58
For example, the ASSERT could go here (and in othe
| |
| 67 | 67 |
| 68 MessageEvent::MessageEvent(PassRefPtr<SerializedScriptValue> data, const String& origin, const String& lastEventId, PassRefPtr<DOMWindow> source, PassOwnPtr<Mes sagePortArray> ports) | 68 MessageEvent::MessageEvent(PassRefPtr<SerializedScriptValue> data, const String& origin, const String& lastEventId, PassRefPtr<EventTarget> source, PassOwnPtr<M essagePortArray> ports) |
| 69 : Event(eventNames().messageEvent, false, false) | 69 : Event(eventNames().messageEvent, false, false) |
| 70 , m_dataType(DataTypeSerializedScriptValue) | 70 , m_dataType(DataTypeSerializedScriptValue) |
| 71 , m_dataAsSerializedScriptValue(data) | 71 , m_dataAsSerializedScriptValue(data) |
| 72 , m_origin(origin) | 72 , m_origin(origin) |
| 73 , m_lastEventId(lastEventId) | 73 , m_lastEventId(lastEventId) |
| 74 , m_source(source) | 74 , m_source(source) |
| 75 , m_ports(ports) | 75 , m_ports(ports) |
| 76 { | 76 { |
| 77 ScriptWrappable::init(this); | 77 ScriptWrappable::init(this); |
| 78 if (m_dataAsSerializedScriptValue) | 78 if (m_dataAsSerializedScriptValue) |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 144 if (m_dataAsSerializedScriptValue) | 144 if (m_dataAsSerializedScriptValue) |
| 145 m_dataAsSerializedScriptValue->registerMemoryAllocatedWithCurrentScriptC ontext(); | 145 m_dataAsSerializedScriptValue->registerMemoryAllocatedWithCurrentScriptC ontext(); |
| 146 } | 146 } |
| 147 | 147 |
| 148 const AtomicString& MessageEvent::interfaceName() const | 148 const AtomicString& MessageEvent::interfaceName() const |
| 149 { | 149 { |
| 150 return eventNames().interfaceForMessageEvent; | 150 return eventNames().interfaceForMessageEvent; |
| 151 } | 151 } |
| 152 | 152 |
| 153 } // namespace WebCore | 153 } // namespace WebCore |
| OLD | NEW |