mirror of
https://github.com/ManchildProductions/UXP-Fixed.git
synced 2026-05-29 18:24:47 +00:00
[docshell] Stop loading of the document if network load is stopped.
After all, stop means stop.
This commit is contained in:
@@ -5449,11 +5449,19 @@ nsDocShell::Stop(uint32_t aStopFlags)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (nsIWebNavigation::STOP_CONTENT & aStopFlags) {
|
if (nsIWebNavigation::STOP_CONTENT & aStopFlags) {
|
||||||
// Stop the document loading
|
// Stop the document loading and animations
|
||||||
if (mContentViewer) {
|
if (mContentViewer) {
|
||||||
nsCOMPtr<nsIContentViewer> cv = mContentViewer;
|
nsCOMPtr<nsIContentViewer> cv = mContentViewer;
|
||||||
cv->Stop();
|
cv->Stop();
|
||||||
}
|
}
|
||||||
|
} else if (nsIWebNavigation::STOP_NETWORK & aStopFlags) {
|
||||||
|
// Stop the document loading only
|
||||||
|
if (mContentViewer) {
|
||||||
|
RefPtr<nsIDocument> doc = mContentViewer->GetDocument();
|
||||||
|
if (doc) {
|
||||||
|
doc->StopDocumentLoad();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nsIWebNavigation::STOP_NETWORK & aStopFlags) {
|
if (nsIWebNavigation::STOP_NETWORK & aStopFlags) {
|
||||||
|
|||||||
Reference in New Issue
Block a user