mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 758481 - When seeking in an unbuffered range after having ended a media, networkState is NETWORK_IDLE r=chris.double
--HG-- extra : rebase_source : e62887187ed20ad6e832bd0211c50392759bb321
This commit is contained in:
parent
55454a183d
commit
0e0ad7b069
@ -153,7 +153,11 @@ public:
|
||||
// Called by the media stream, on the main thread, when the download
|
||||
// has been resumed by the cache or because the element itself
|
||||
// asked the decoder to resumed the download.
|
||||
void DownloadResumed();
|
||||
// If aForceNetworkLoading is True, ignore the fact that the download has
|
||||
// previously finished. We are downloading the middle of the media after
|
||||
// having downloaded the end, we need to notify the element a download in
|
||||
// ongoing.
|
||||
void DownloadResumed(bool aForceNetworkLoading = false);
|
||||
|
||||
// Called by the media decoder to indicate that the download has stalled
|
||||
// (no data has arrived for a while).
|
||||
|
@ -2779,9 +2779,9 @@ void nsHTMLMediaElement::DownloadSuspended()
|
||||
}
|
||||
}
|
||||
|
||||
void nsHTMLMediaElement::DownloadResumed()
|
||||
void nsHTMLMediaElement::DownloadResumed(bool aForceNetworkLoading)
|
||||
{
|
||||
if (mBegun) {
|
||||
if (mBegun || aForceNetworkLoading) {
|
||||
mNetworkState = nsIDOMHTMLMediaElement::NETWORK_LOADING;
|
||||
AddRemoveSelfReference();
|
||||
}
|
||||
|
@ -451,6 +451,8 @@ nsresult ChannelMediaResource::OpenChannel(nsIStreamListener** aStreamListener)
|
||||
|
||||
nsresult rv = mChannel->AsyncOpen(listener, nsnull);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
// Tell the media element that we are fetching data from a channel.
|
||||
element->DownloadResumed(true);
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
|
Loading…
Reference in New Issue
Block a user