| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 return adoptRef(new MediaStreamEvent(type, canBubble, cancelable, stream)); | 47 return adoptRef(new MediaStreamEvent(type, canBubble, cancelable, stream)); |
| 48 } | 48 } |
| 49 | 49 |
| 50 PassRefPtr<MediaStreamEvent> MediaStreamEvent::create(const AtomicString& type,
const MediaStreamEventInit& initializer) | 50 PassRefPtr<MediaStreamEvent> MediaStreamEvent::create(const AtomicString& type,
const MediaStreamEventInit& initializer) |
| 51 { | 51 { |
| 52 return adoptRef(new MediaStreamEvent(type, initializer)); | 52 return adoptRef(new MediaStreamEvent(type, initializer)); |
| 53 } | 53 } |
| 54 | 54 |
| 55 MediaStreamEvent::MediaStreamEvent() | 55 MediaStreamEvent::MediaStreamEvent() |
| 56 { | 56 { |
| 57 ScriptWrappable::init(this); |
| 57 } | 58 } |
| 58 | 59 |
| 59 MediaStreamEvent::MediaStreamEvent(const AtomicString& type, bool canBubble, boo
l cancelable, PassRefPtr<MediaStream> stream) | 60 MediaStreamEvent::MediaStreamEvent(const AtomicString& type, bool canBubble, boo
l cancelable, PassRefPtr<MediaStream> stream) |
| 60 : Event(type, canBubble, cancelable) | 61 : Event(type, canBubble, cancelable) |
| 61 , m_stream(stream) | 62 , m_stream(stream) |
| 62 { | 63 { |
| 64 ScriptWrappable::init(this); |
| 63 } | 65 } |
| 64 | 66 |
| 65 MediaStreamEvent::MediaStreamEvent(const AtomicString& type, const MediaStreamEv
entInit& initializer) | 67 MediaStreamEvent::MediaStreamEvent(const AtomicString& type, const MediaStreamEv
entInit& initializer) |
| 66 : Event(type, initializer) | 68 : Event(type, initializer) |
| 67 , m_stream(initializer.stream) | 69 , m_stream(initializer.stream) |
| 68 { | 70 { |
| 71 ScriptWrappable::init(this); |
| 69 } | 72 } |
| 70 | 73 |
| 71 MediaStreamEvent::~MediaStreamEvent() | 74 MediaStreamEvent::~MediaStreamEvent() |
| 72 { | 75 { |
| 73 } | 76 } |
| 74 | 77 |
| 75 MediaStream* MediaStreamEvent::stream() const | 78 MediaStream* MediaStreamEvent::stream() const |
| 76 { | 79 { |
| 77 return m_stream.get(); | 80 return m_stream.get(); |
| 78 } | 81 } |
| 79 | 82 |
| 80 const AtomicString& MediaStreamEvent::interfaceName() const | 83 const AtomicString& MediaStreamEvent::interfaceName() const |
| 81 { | 84 { |
| 82 return eventNames().interfaceForMediaStreamEvent; | 85 return eventNames().interfaceForMediaStreamEvent; |
| 83 } | 86 } |
| 84 | 87 |
| 85 } // namespace WebCore | 88 } // namespace WebCore |
| 86 | 89 |
| 87 #endif // ENABLE(MEDIA_STREAM) | 90 #endif // ENABLE(MEDIA_STREAM) |
| 88 | 91 |
| OLD | NEW |