Chromium Code Reviews| Index: Source/core/html/HTMLMediaElement.cpp |
| diff --git a/Source/core/html/HTMLMediaElement.cpp b/Source/core/html/HTMLMediaElement.cpp |
| index 608390e31002930cf2cd7594880257f0dc9ea7d3..e4ef3f1f35d2a0d970c9c05b64d53f20c3285071 100644 |
| --- a/Source/core/html/HTMLMediaElement.cpp |
| +++ b/Source/core/html/HTMLMediaElement.cpp |
| @@ -3477,20 +3477,13 @@ void* HTMLMediaElement::preDispatchEventHandler(Event* event) |
| return nullptr; |
| } |
| -// TODO(srirama.m): Refactor this and other relevant methods and have a |
| -// single method for clearing the mediaplayer and its stuff. |
| +// TODO(srirama.m): Refactor this and clearMediaPlayer to the extent possible. |
| void HTMLMediaElement::resetMediaPlayerAndMediaSource() |
| { |
| - AudioSourceProviderClientLockScope scope(*this); |
| - |
| closeMediaSource(); |
| - if (m_webMediaPlayer) { |
| -#if ENABLE(WEB_AUDIO) |
| - m_audioSourceProvider.wrap(nullptr); |
| -#endif |
| - m_webMediaPlayer.clear(); |
| - } |
| + AudioSourceProviderClientLockScope scope(*this); |
|
philipj_slow
2015/08/18 07:53:50
Maybe wrap this in a scope like in HTMLMediaElemen
Srirama
2015/08/18 08:38:33
That will be an extra call but there shouldn't be
philipj_slow
2015/08/18 09:00:49
Oh, I didn't see that in the diff.
|
| + clearMediaPlayerAndAudioSourceProviderClientWithoutLocking(); |
| // We haven't yet found out if any remote routes are available. |
| m_remoteRoutesAvailable = false; |