| 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 3025 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3036 | 3036 |
| 3037 if (m_networkState == NETWORK_EMPTY || m_completelyLoaded || m_isFinalizing) | 3037 if (m_networkState == NETWORK_EMPTY || m_completelyLoaded || m_isFinalizing) |
| 3038 return; | 3038 return; |
| 3039 | 3039 |
| 3040 // 2 - Set the error attribute to a new MediaError object whose code attribu
te is set to MEDIA_ERR_ABORTED. | 3040 // 2 - Set the error attribute to a new MediaError object whose code attribu
te is set to MEDIA_ERR_ABORTED. |
| 3041 m_error = MediaError::create(MediaError::MEDIA_ERR_ABORTED); | 3041 m_error = MediaError::create(MediaError::MEDIA_ERR_ABORTED); |
| 3042 | 3042 |
| 3043 // 3 - Queue a task to fire a simple event named error at the media element. | 3043 // 3 - Queue a task to fire a simple event named error at the media element. |
| 3044 scheduleEvent(EventTypeNames::abort); | 3044 scheduleEvent(EventTypeNames::abort); |
| 3045 | 3045 |
| 3046 closeMediaSource(); | |
| 3047 | |
| 3048 // 4 - If the media element's readyState attribute has a value equal to HAVE
_NOTHING, set the | 3046 // 4 - If the media element's readyState attribute has a value equal to HAVE
_NOTHING, set the |
| 3049 // element's networkState attribute to the NETWORK_EMPTY value and queue a t
ask to fire a | 3047 // element's networkState attribute to the NETWORK_EMPTY value and queue a t
ask to fire a |
| 3050 // simple event named emptied at the element. Otherwise, set the element's n
etworkState | 3048 // simple event named emptied at the element. Otherwise, set the element's n
etworkState |
| 3051 // attribute to the NETWORK_IDLE value. | 3049 // attribute to the NETWORK_IDLE value. |
| 3052 if (m_readyState == HAVE_NOTHING) { | 3050 if (m_readyState == HAVE_NOTHING) { |
| 3053 m_networkState = NETWORK_EMPTY; | 3051 m_networkState = NETWORK_EMPTY; |
| 3054 scheduleEvent(EventTypeNames::emptied); | 3052 scheduleEvent(EventTypeNames::emptied); |
| 3055 } else { | 3053 } else { |
| 3056 m_networkState = NETWORK_IDLE; | 3054 m_networkState = NETWORK_IDLE; |
| 3057 } | 3055 } |
| (...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3789 visitor->trace(m_client); | 3787 visitor->trace(m_client); |
| 3790 } | 3788 } |
| 3791 | 3789 |
| 3792 DEFINE_TRACE(HTMLMediaElement::AudioSourceProviderImpl) | 3790 DEFINE_TRACE(HTMLMediaElement::AudioSourceProviderImpl) |
| 3793 { | 3791 { |
| 3794 visitor->trace(m_client); | 3792 visitor->trace(m_client); |
| 3795 } | 3793 } |
| 3796 #endif | 3794 #endif |
| 3797 | 3795 |
| 3798 } | 3796 } |
| OLD | NEW |