Bug 548523 - Don't show throbber on video controls if we're not loading a resource. r=dolske a=blocking2.0

This commit is contained in:
Chris Pearce 2010-08-18 10:49:14 +12:00
Родитель 0ea19dfe4e
Коммит 21fcdf317d
2 изменённых файлов: 6 добавлений и 4 удалений

Просмотреть файл

@ -687,6 +687,7 @@ void nsHTMLMediaElement::ResumeLoad(PreloadAction aAction)
mPreloadURI = nsnull;
mPreloadAction = aAction;
ChangeDelayLoadStatus(PR_TRUE);
mNetworkState = nsIDOMHTMLMediaElement::NETWORK_LOADING;
if (mIsLoadingFromSrcAttribute) {
// We were loading from the element's src attribute.
if (NS_FAILED(LoadResource(uri))) {

Просмотреть файл

@ -310,12 +310,13 @@
setupStatusFader : function(immediate) {
var show = false;
if (this.video.seeking || this.video.error ||
(this.video.paused || this.video.ended
? this.video.readyState < this.video.HAVE_CURRENT_DATA
: this.video.readyState < this.video.HAVE_FUTURE_DATA) ||
(this.video.networkState == this.video.NETWORK_LOADING &&
(this.video.paused || this.video.ended
? this.video.readyState < this.video.HAVE_CURRENT_DATA
: this.video.readyState < this.video.HAVE_FUTURE_DATA)) ||
(this.timeUpdateCount <= 1 && !this.video.ended &&
this.video.readyState < this.video.HAVE_ENOUGH_DATA &&
this.video.networkState >= this.video.NETWORK_LOADING))
this.video.networkState == this.video.NETWORK_LOADING))
show = true;
this.log("Status overlay: seeking=" + this.video.seeking +