OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights
reserved. | 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 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 2176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2187 m_paused = true; | 2187 m_paused = true; |
2188 scheduleTimeupdateEvent(false); | 2188 scheduleTimeupdateEvent(false); |
2189 scheduleEvent(EventTypeNames::pause); | 2189 scheduleEvent(EventTypeNames::pause); |
2190 scheduleRejectPlayPromises(AbortError); | 2190 scheduleRejectPlayPromises(AbortError); |
2191 } | 2191 } |
2192 | 2192 |
2193 updatePlayState(); | 2193 updatePlayState(); |
2194 } | 2194 } |
2195 | 2195 |
2196 void HTMLMediaElement::requestRemotePlayback() { | 2196 void HTMLMediaElement::requestRemotePlayback() { |
2197 DCHECK(m_remoteRoutesAvailable); | 2197 if (webMediaPlayer()) |
2198 webMediaPlayer()->requestRemotePlayback(); | 2198 webMediaPlayer()->requestRemotePlayback(); |
2199 } | 2199 } |
2200 | 2200 |
2201 void HTMLMediaElement::requestRemotePlaybackControl() { | 2201 void HTMLMediaElement::requestRemotePlaybackControl() { |
2202 DCHECK(m_remoteRoutesAvailable); | 2202 if (webMediaPlayer()) |
2203 webMediaPlayer()->requestRemotePlaybackControl(); | 2203 webMediaPlayer()->requestRemotePlaybackControl(); |
2204 } | 2204 } |
2205 | 2205 |
2206 void HTMLMediaElement::closeMediaSource() { | 2206 void HTMLMediaElement::closeMediaSource() { |
2207 if (!m_mediaSource) | 2207 if (!m_mediaSource) |
2208 return; | 2208 return; |
2209 | 2209 |
2210 m_mediaSource->close(); | 2210 m_mediaSource->close(); |
2211 m_mediaSource = nullptr; | 2211 m_mediaSource = nullptr; |
2212 } | 2212 } |
2213 | 2213 |
(...skipping 1776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3990 | 3990 |
3991 IntRect HTMLMediaElement::AutoplayHelperClientImpl::absoluteBoundingBoxRect() | 3991 IntRect HTMLMediaElement::AutoplayHelperClientImpl::absoluteBoundingBoxRect() |
3992 const { | 3992 const { |
3993 IntRect result; | 3993 IntRect result; |
3994 if (LayoutObject* object = m_element->layoutObject()) | 3994 if (LayoutObject* object = m_element->layoutObject()) |
3995 result = object->absoluteBoundingBoxRect(); | 3995 result = object->absoluteBoundingBoxRect(); |
3996 return result; | 3996 return result; |
3997 } | 3997 } |
3998 | 3998 |
3999 } // namespace blink | 3999 } // namespace blink |
OLD | NEW |