| 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 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 196 return webMediaPlayer()->hasVideo() && webMediaPlayer()->readyState() >= bli
nk::WebMediaPlayer::ReadyStateHaveCurrentData; | 196 return webMediaPlayer()->hasVideo() && webMediaPlayer()->readyState() >= bli
nk::WebMediaPlayer::ReadyStateHaveCurrentData; |
| 197 } | 197 } |
| 198 | 198 |
| 199 void HTMLVideoElement::didMoveToNewDocument(Document& oldDocument) | 199 void HTMLVideoElement::didMoveToNewDocument(Document& oldDocument) |
| 200 { | 200 { |
| 201 if (m_imageLoader) | 201 if (m_imageLoader) |
| 202 m_imageLoader->elementDidMoveToNewDocument(); | 202 m_imageLoader->elementDidMoveToNewDocument(); |
| 203 HTMLMediaElement::didMoveToNewDocument(oldDocument); | 203 HTMLMediaElement::didMoveToNewDocument(oldDocument); |
| 204 } | 204 } |
| 205 | 205 |
| 206 unsigned HTMLVideoElement::webkitDecodedFrameCount() const | |
| 207 { | |
| 208 if (!webMediaPlayer()) | |
| 209 return 0; | |
| 210 | |
| 211 return webMediaPlayer()->decodedFrameCount(); | |
| 212 } | |
| 213 | |
| 214 unsigned HTMLVideoElement::webkitDroppedFrameCount() const | |
| 215 { | |
| 216 if (!webMediaPlayer()) | |
| 217 return 0; | |
| 218 | |
| 219 return webMediaPlayer()->droppedFrameCount(); | |
| 220 } | |
| 221 | |
| 222 KURL HTMLVideoElement::posterImageURL() const | 206 KURL HTMLVideoElement::posterImageURL() const |
| 223 { | 207 { |
| 224 String url = stripLeadingAndTrailingHTMLSpaces(imageSourceURL()); | 208 String url = stripLeadingAndTrailingHTMLSpaces(imageSourceURL()); |
| 225 if (url.isEmpty()) | 209 if (url.isEmpty()) |
| 226 return KURL(); | 210 return KURL(); |
| 227 return document().completeURL(url); | 211 return document().completeURL(url); |
| 228 } | 212 } |
| 229 | 213 |
| 230 KURL HTMLVideoElement::mediaPlayerPosterURL() | 214 KURL HTMLVideoElement::mediaPlayerPosterURL() |
| 231 { | 215 { |
| (...skipping 19 matching lines...) Expand all Loading... |
| 251 *status = NormalSourceImageStatus; | 235 *status = NormalSourceImageStatus; |
| 252 return imageBuffer->copyImage(mode == CopySourceImageIfVolatile ? CopyBackin
gStore : DontCopyBackingStore, Unscaled); | 236 return imageBuffer->copyImage(mode == CopySourceImageIfVolatile ? CopyBackin
gStore : DontCopyBackingStore, Unscaled); |
| 253 } | 237 } |
| 254 | 238 |
| 255 FloatSize HTMLVideoElement::sourceSize() const | 239 FloatSize HTMLVideoElement::sourceSize() const |
| 256 { | 240 { |
| 257 return FloatSize(videoWidth(), videoHeight()); | 241 return FloatSize(videoWidth(), videoHeight()); |
| 258 } | 242 } |
| 259 | 243 |
| 260 } | 244 } |
| OLD | NEW |