OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2009, 2010 Apple 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 inline HTMLVideoElement::HTMLVideoElement(Document& document) | 48 inline HTMLVideoElement::HTMLVideoElement(Document& document) |
49 : HTMLMediaElement(videoTag, document) | 49 : HTMLMediaElement(videoTag, document) |
50 { | 50 { |
51 ScriptWrappable::init(this); | 51 ScriptWrappable::init(this); |
52 if (document.settings()) | 52 if (document.settings()) |
53 m_defaultPosterURL = AtomicString(document.settings()->defaultVideoPoste
rURL()); | 53 m_defaultPosterURL = AtomicString(document.settings()->defaultVideoPoste
rURL()); |
54 } | 54 } |
55 | 55 |
56 PassRefPtrWillBeRawPtr<HTMLVideoElement> HTMLVideoElement::create(Document& docu
ment) | 56 PassRefPtrWillBeRawPtr<HTMLVideoElement> HTMLVideoElement::create(Document& docu
ment) |
57 { | 57 { |
58 RefPtrWillBeRawPtr<HTMLVideoElement> video = adoptRefWillBeRefCountedGarbage
Collected(new HTMLVideoElement(document)); | 58 RefPtrWillBeRawPtr<HTMLVideoElement> video = adoptRefWillBeNoop(new HTMLVide
oElement(document)); |
59 video->ensureUserAgentShadowRoot(); | 59 video->ensureUserAgentShadowRoot(); |
60 video->suspendIfNeeded(); | 60 video->suspendIfNeeded(); |
61 return video.release(); | 61 return video.release(); |
62 } | 62 } |
63 | 63 |
64 void HTMLVideoElement::trace(Visitor* visitor) | 64 void HTMLVideoElement::trace(Visitor* visitor) |
65 { | 65 { |
66 visitor->trace(m_imageLoader); | 66 visitor->trace(m_imageLoader); |
67 HTMLMediaElement::trace(visitor); | 67 HTMLMediaElement::trace(visitor); |
68 } | 68 } |
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
307 { | 307 { |
308 return !hasSingleSecurityOrigin() || (!(webMediaPlayer() && webMediaPlayer()
->didPassCORSAccessCheck()) && destinationSecurityOrigin->taintsCanvas(currentSr
c())); | 308 return !hasSingleSecurityOrigin() || (!(webMediaPlayer() && webMediaPlayer()
->didPassCORSAccessCheck()) && destinationSecurityOrigin->taintsCanvas(currentSr
c())); |
309 } | 309 } |
310 | 310 |
311 FloatSize HTMLVideoElement::sourceSize() const | 311 FloatSize HTMLVideoElement::sourceSize() const |
312 { | 312 { |
313 return FloatSize(videoWidth(), videoHeight()); | 313 return FloatSize(videoWidth(), videoHeight()); |
314 } | 314 } |
315 | 315 |
316 } | 316 } |
OLD | NEW |