Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(48)

Side by Side Diff: Source/core/html/HTMLMediaElement.cpp

Issue 575563002: Fix adopting a video element with controls (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix TestExpectations and add expected test results Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 809 matching lines...) Expand 10 before | Expand all | Expand 10 after
820 820
821 // FIXME: Investigate whether these can be moved into m_networkState != NETW ORK_EMPTY block above 821 // FIXME: Investigate whether these can be moved into m_networkState != NETW ORK_EMPTY block above
822 // so they are closer to the relevant spec steps. 822 // so they are closer to the relevant spec steps.
823 m_lastSeekTime = 0; 823 m_lastSeekTime = 0;
824 m_duration = std::numeric_limits<double>::quiet_NaN(); 824 m_duration = std::numeric_limits<double>::quiet_NaN();
825 825
826 // The spec doesn't say to block the load event until we actually run the as ynchronous section 826 // The spec doesn't say to block the load event until we actually run the as ynchronous section
827 // algorithm, but do it now because we won't start that until after the time r fires and the 827 // algorithm, but do it now because we won't start that until after the time r fires and the
828 // event may have already fired by then. 828 // event may have already fired by then.
829 setShouldDelayLoadEvent(true); 829 setShouldDelayLoadEvent(true);
830
831 configureMediaControls();
832 } 830 }
833 831
834 void HTMLMediaElement::loadInternal() 832 void HTMLMediaElement::loadInternal()
835 { 833 {
834 configureMediaControls();
philipj_slow 2014/09/16 11:59:39 All existing tests and the one you've added pass i
aberent 2014/09/16 14:45:40 Having failed to create a test in a bit more than
836 // HTMLMediaElement::textTracksAreReady will need "... the text tracks whose mode was not in the 835 // HTMLMediaElement::textTracksAreReady will need "... the text tracks whose mode was not in the
837 // disabled state when the element's resource selection algorithm last start ed". 836 // disabled state when the element's resource selection algorithm last start ed".
838 m_textTracksWhenResourceSelectionBegan.clear(); 837 m_textTracksWhenResourceSelectionBegan.clear();
839 if (m_textTracks) { 838 if (m_textTracks) {
840 for (unsigned i = 0; i < m_textTracks->length(); ++i) { 839 for (unsigned i = 0; i < m_textTracks->length(); ++i) {
841 TextTrack* track = m_textTracks->item(i); 840 TextTrack* track = m_textTracks->item(i);
842 if (track->mode() != TextTrack::disabledKeyword()) 841 if (track->mode() != TextTrack::disabledKeyword())
843 m_textTracksWhenResourceSelectionBegan.append(track); 842 m_textTracksWhenResourceSelectionBegan.append(track);
844 } 843 }
845 } 844 }
(...skipping 3137 matching lines...) Expand 10 before | Expand all | Expand 10 after
3983 3982
3984 #if ENABLE(WEB_AUDIO) 3983 #if ENABLE(WEB_AUDIO)
3985 void HTMLMediaElement::clearWeakMembers(Visitor* visitor) 3984 void HTMLMediaElement::clearWeakMembers(Visitor* visitor)
3986 { 3985 {
3987 if (!visitor->isAlive(m_audioSourceNode) && audioSourceProvider()) 3986 if (!visitor->isAlive(m_audioSourceNode) && audioSourceProvider())
3988 audioSourceProvider()->setClient(0); 3987 audioSourceProvider()->setClient(0);
3989 } 3988 }
3990 #endif 3989 #endif
3991 3990
3992 } 3991 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698