mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-27 21:00:50 +00:00
content sink uses nsWebShell::GetIsFrame to set scrolling on nsWebShell
This commit is contained in:
parent
44d24e235a
commit
29d75b2c52
@ -1928,13 +1928,17 @@ HTMLContentSink::StartLayout()
|
||||
NS_IF_RELEASE(rootWebShell);
|
||||
}
|
||||
|
||||
// If it's a top level frameset document then disable scrolling; otherwise, let the
|
||||
// style dictate. We need to do this before the initial reflow...
|
||||
// If it's a top level frameset document then disable scrolling. If it is a non frame
|
||||
// document, then let the style dictate. We need to do this before the initial reflow...
|
||||
if (mWebShell) {
|
||||
if (topLevelFrameset) {
|
||||
mWebShell->SetScrolling(NS_STYLE_OVERFLOW_HIDDEN);
|
||||
} else if (mBody) {
|
||||
// mWebShell->SetScrolling(-1);
|
||||
PRBool isFrameDoc = PR_FALSE;
|
||||
mWebShell->GetIsFrame(isFrameDoc);
|
||||
if (!isFrameDoc) {
|
||||
mWebShell->SetScrolling(-1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -651,6 +651,7 @@ nsHTMLFrameInnerFrame::CreateWebShell(nsIPresContext& aPresContext,
|
||||
nsCompatibility mode;
|
||||
aPresContext.GetCompatibilityMode(mode);
|
||||
mWebShell->SetScrolling(GetScrolling(content, mode));
|
||||
mWebShell->SetIsFrame(PR_TRUE);
|
||||
|
||||
nsString frameName;
|
||||
if (GetName(content, frameName)) {
|
||||
|
@ -651,6 +651,7 @@ nsHTMLFrameInnerFrame::CreateWebShell(nsIPresContext& aPresContext,
|
||||
nsCompatibility mode;
|
||||
aPresContext.GetCompatibilityMode(mode);
|
||||
mWebShell->SetScrolling(GetScrolling(content, mode));
|
||||
mWebShell->SetIsFrame(PR_TRUE);
|
||||
|
||||
nsString frameName;
|
||||
if (GetName(content, frameName)) {
|
||||
|
@ -1928,13 +1928,17 @@ HTMLContentSink::StartLayout()
|
||||
NS_IF_RELEASE(rootWebShell);
|
||||
}
|
||||
|
||||
// If it's a top level frameset document then disable scrolling; otherwise, let the
|
||||
// style dictate. We need to do this before the initial reflow...
|
||||
// If it's a top level frameset document then disable scrolling. If it is a non frame
|
||||
// document, then let the style dictate. We need to do this before the initial reflow...
|
||||
if (mWebShell) {
|
||||
if (topLevelFrameset) {
|
||||
mWebShell->SetScrolling(NS_STYLE_OVERFLOW_HIDDEN);
|
||||
} else if (mBody) {
|
||||
// mWebShell->SetScrolling(-1);
|
||||
PRBool isFrameDoc = PR_FALSE;
|
||||
mWebShell->GetIsFrame(isFrameDoc);
|
||||
if (!isFrameDoc) {
|
||||
mWebShell->SetScrolling(-1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user