Bug 1594529: Infer nsDocShell::IsFrame from BrowsingContext. r=nika
This fixes the content policy type for document loads in these frames, where the explicit mIsFrame flag was not set, due to DocShell creation taking a different code path in remote frames than in in-process frames. Differential Revision: https://phabricator.services.mozilla.com/D52093
This commit is contained in:
@@ -360,8 +360,6 @@ class nsDocShell final : public nsDocLoader,
|
||||
void SetInFrameSwap(bool aInSwap) { mInFrameSwap = aInSwap; }
|
||||
bool InFrameSwap();
|
||||
|
||||
void SetIsFrame() { mIsFrame = true; };
|
||||
|
||||
const mozilla::Encoding* GetForcedCharset() { return mForcedCharset; }
|
||||
|
||||
mozilla::HTMLEditor* GetHTMLEditorInternal();
|
||||
@@ -1002,7 +1000,7 @@ class nsDocShell final : public nsDocLoader,
|
||||
void RecomputeCanExecuteScripts();
|
||||
void ClearFrameHistory(nsISHEntry* aEntry);
|
||||
void UpdateGlobalHistoryTitle(nsIURI* aURI);
|
||||
bool IsFrame();
|
||||
bool IsFrame() { return mBrowsingContext->GetParent(); }
|
||||
bool CanSetOriginAttributes();
|
||||
bool ShouldBlockLoadingForBackButton();
|
||||
bool ShouldDiscardLayoutState(nsIHttpChannel* aChannel);
|
||||
@@ -1333,8 +1331,6 @@ class nsDocShell final : public nsDocLoader,
|
||||
// This flag indicates when the title is valid for the current URI.
|
||||
bool mTitleValidForCurrentURI : 1;
|
||||
|
||||
bool mIsFrame : 1;
|
||||
|
||||
// If mWillChangeProcess is set to true, then when the docshell is destroyed,
|
||||
// we prepare the browsing context to change process.
|
||||
bool mWillChangeProcess : 1;
|
||||
|
||||
Reference in New Issue
Block a user