зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1404422 - Part 3. Disable triggering imgIOnloadBlocker block/unblock events. r=tnikkel
This commit is contained in:
Родитель
0e2b74f9d2
Коммит
3e3c2a5bca
|
@ -333,10 +333,6 @@ SyncNotifyInternal(const T& aObservers,
|
|||
notify([](IProgressObserver* aObs) { aObs->Notify(I::SIZE_AVAILABLE); });
|
||||
}
|
||||
|
||||
if (aProgress & FLAG_ONLOAD_BLOCKED) {
|
||||
notify([](IProgressObserver* aObs) { aObs->BlockOnload(); });
|
||||
}
|
||||
|
||||
if (aHasImage) {
|
||||
// OnFrameUpdate
|
||||
// If there's any content in this frame at all (always true for
|
||||
|
@ -361,13 +357,6 @@ SyncNotifyInternal(const T& aObservers,
|
|||
}
|
||||
}
|
||||
|
||||
// Send UnblockOnload before OnStopDecode and OnStopRequest. This allows
|
||||
// observers that can fire events when they receive those notifications to do
|
||||
// so then, instead of being forced to wait for UnblockOnload.
|
||||
if (aProgress & FLAG_ONLOAD_UNBLOCKED) {
|
||||
notify([](IProgressObserver* aObs) { aObs->UnblockOnload(); });
|
||||
}
|
||||
|
||||
if (aProgress & FLAG_DECODE_COMPLETE) {
|
||||
MOZ_ASSERT(aHasImage, "Stopped decoding without ever having an image?");
|
||||
notify([](IProgressObserver* aObs) { aObs->Notify(I::DECODE_COMPLETE); });
|
||||
|
@ -450,10 +439,6 @@ ProgressTracker::EmulateRequestFinished(IProgressObserver* aObserver)
|
|||
"SyncNotifyState and mObservers are not threadsafe");
|
||||
RefPtr<IProgressObserver> kungFuDeathGrip(aObserver);
|
||||
|
||||
if (mProgress & FLAG_ONLOAD_BLOCKED && !(mProgress & FLAG_ONLOAD_UNBLOCKED)) {
|
||||
aObserver->UnblockOnload();
|
||||
}
|
||||
|
||||
if (!(mProgress & FLAG_LOAD_COMPLETE)) {
|
||||
aObserver->OnLoadComplete(true);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче