mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 488287. When playback ends, readyState should change to HAVE_CURRENT_DATA. r=doublec,sr=roc
--HG-- extra : rebase_source : ea224af1634304c40d7e4ea0f564e72ccab65caa
This commit is contained in:
parent
96c6c7a7fe
commit
016153f95a
@ -1205,6 +1205,7 @@ void nsHTMLMediaElement::NetworkError()
|
||||
void nsHTMLMediaElement::PlaybackEnded()
|
||||
{
|
||||
NS_ASSERTION(mDecoder->IsEnded(), "Decoder fired ended, but not in ended state");
|
||||
ChangeReadyState(nsIDOMHTMLMediaElement::HAVE_CURRENT_DATA);
|
||||
DispatchAsyncSimpleEvent(NS_LITERAL_STRING("ended"));
|
||||
}
|
||||
|
||||
|
@ -43,8 +43,9 @@ function playbackEnded() {
|
||||
ok(v.currentTime >= 3.9 && v.currentTime <= 4.0,
|
||||
"Checking currentTime at end: " + v.currentTime);
|
||||
ok(v.ended, "Checking playback has ended");
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
playingCount = 0;
|
||||
if (endCount < 2) {
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
v.currentTime = 0;
|
||||
ok(v.seeking, "Checking that seeking is now true");
|
||||
ok(!v.ended, "Checking ended is no longer set as seeking has begun");
|
||||
|
@ -43,8 +43,9 @@ function playbackEnded() {
|
||||
ok(v.currentTime >= 0.9 && v.currentTime <= 1.1,
|
||||
"Checking currentTime at end: " + v.currentTime);
|
||||
ok(v.ended, "Checking playback has ended");
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
playingCount = 0;
|
||||
if (endCount < 2) {
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
v.currentTime = 0;
|
||||
ok(v.seeking, "Checking that seeking is now true");
|
||||
ok(!v.ended, "Checking ended is no longer set as seeking has begun");
|
||||
|
@ -39,8 +39,9 @@ function playbackEnded() {
|
||||
ok(v.currentTime >= 3.9 && v.currentTime <= 4.0,
|
||||
"Checking currentTime at end: " + v.currentTime);
|
||||
ok(v.ended, "Checking playback has ended");
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
playingCount = 0;
|
||||
if (endCount < 2) {
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
v.play();
|
||||
} else {
|
||||
ok(endCount == 2, "Check playback after ended event");
|
||||
|
@ -40,8 +40,9 @@ function playbackEnded() {
|
||||
ok(v.currentTime >= 0.9 && v.currentTime <= 1.1,
|
||||
"Checking currentTime at end: " + v.currentTime);
|
||||
ok(v.ended, "Checking playback has ended");
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
playingCount = 0;
|
||||
if (endCount < 2) {
|
||||
ok(playingCount > 0, "Expect at least one playing event");
|
||||
v.play();
|
||||
} else {
|
||||
ok(endCount == 2, "Check playback after ended event");
|
||||
|
Loading…
Reference in New Issue
Block a user