Bug 1966349 - Make sure NavigateEvent is initialized correctly. r=jjaschke
Make sure the properties downloadRequest and userInitiated get their correct values. Differential Revision: https://phabricator.services.mozilla.com/D249243
This commit is contained in:
committed by
afarre@mozilla.com
parent
86fbf126b4
commit
b81eda9a8a
@@ -12979,6 +12979,7 @@ nsresult nsDocShell::OnLinkClick(
|
||||
loadState->SetTextDirectiveUserActivation(
|
||||
ownerDoc->ConsumeTextDirectiveUserActivation() ||
|
||||
hasValidUserGestureActivation);
|
||||
loadState->SetUserNavigationInvolvement(aUserInvolvement);
|
||||
|
||||
nsCOMPtr<nsIRunnable> ev = new OnLinkClickEvent(
|
||||
this, aContent, loadState, noOpenerImplied, aTriggeringPrincipal);
|
||||
|
||||
@@ -526,7 +526,7 @@ bool Navigation::FireTraverseNavigateEvent(
|
||||
/* aSourceElement */ nullptr,
|
||||
/* aFormDataEntryList*/ Nothing(),
|
||||
/* aClassicHistoryAPIState */ nullptr,
|
||||
/* aDownloadRequestFilename */ u""_ns);
|
||||
/* aDownloadRequestFilename */ VoidString());
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/#fire-a-push/replace/reload-navigate-event
|
||||
@@ -552,7 +552,7 @@ bool Navigation::FirePushReplaceReloadNavigateEvent(
|
||||
aCx, aNavigationType, destination,
|
||||
aUserInvolvement.valueOr(UserNavigationInvolvement::None), aSourceElement,
|
||||
aFormDataEntryList, aClassicHistoryAPIState,
|
||||
/* aDownloadRequestFilename */ u""_ns);
|
||||
/* aDownloadRequestFilename */ VoidString());
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/#fire-a-download-request-navigate-event
|
||||
|
||||
Reference in New Issue
Block a user