Bug 1734181 - Part 1: Carry hasUserInteraction over to newly-created SessionHistoryEntrys. r=jjaschke,peterv,dom-core

Differential Revision: https://phabricator.services.mozilla.com/D209014
This commit is contained in:
Adam Vandolder 2024-08-24 19:43:30 +00:00
Родитель 053674ca01
Коммит d072800d01
1 изменённых файлов: 2 добавлений и 1 удалений

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

@ -52,7 +52,7 @@ SessionHistoryInfo::SessionHistoryInfo(nsDocShellLoadState* aLoadState,
: Some(aLoadState->SrcdocData())),
mBaseURI(aLoadState->BaseURI()),
mLoadReplace(aLoadState->LoadReplace()),
mHasUserInteraction(false),
mHasUserInteraction(aLoadState->HasValidUserGestureActivation()),
mHasUserActivation(aLoadState->HasValidUserGestureActivation()),
mSharedState(SharedState::Create(
aLoadState->TriggeringPrincipal(), aLoadState->PrincipalToInherit(),
@ -79,6 +79,7 @@ SessionHistoryInfo::SessionHistoryInfo(
const SessionHistoryInfo& aSharedStateFrom, nsIURI* aURI)
: mURI(aURI), mSharedState(aSharedStateFrom.mSharedState) {
MaybeUpdateTitleFromURI();
mHasUserInteraction = aSharedStateFrom.mHasUserInteraction;
}
SessionHistoryInfo::SessionHistoryInfo(