File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -547,12 +547,7 @@ void ImageLoader::updatedHasPendingEvent()
547
547
// destroyed by DOM manipulation or garbage collection.
548
548
// If such an Element wishes for the load to stop when removed from the DOM it needs to stop the ImageLoader explicitly.
549
549
bool wasProtected = m_elementIsProtected;
550
-
551
- // Because of lazy image loading, an image's load may be deferred indefinitely. To avoid leaking the element, we only
552
- // protect it once the load has actually started.
553
- bool imageWillBeLoadedLater = m_image && !m_image->isLoading () && m_image->stillNeedsLoad ();
554
-
555
- m_elementIsProtected = (m_hasPendingLoadEvent && !imageWillBeLoadedLater) || m_hasPendingErrorEvent;
550
+ m_elementIsProtected = hasPendingActivity ();
556
551
if (wasProtected == m_elementIsProtected)
557
552
return ;
558
553
You can’t perform that action at this time.
0 commit comments