зеркало из https://github.com/mozilla/gecko-dev.git
Fixed somecomments which had been copied from elsewhere and we not
completely accurate
This commit is contained in:
Родитель
2017acf95a
Коммит
afea3ec53b
|
@ -215,18 +215,17 @@ nsHTMLContainerFrame::CreateWrapperFrame(nsIPresContext& aPresContext,
|
||||||
nsIFrame* aFrame,
|
nsIFrame* aFrame,
|
||||||
nsIFrame*& aWrapperFrame)
|
nsIFrame*& aWrapperFrame)
|
||||||
{
|
{
|
||||||
// If the floated element can contain children then wrap it in a
|
// If the frame can contain children then wrap it in a BODY frame
|
||||||
// BODY frame before floating it
|
|
||||||
nsIContent* content;
|
nsIContent* content;
|
||||||
PRBool isContainer;
|
PRBool isContainer;
|
||||||
|
|
||||||
aFrame->GetContent(content);
|
aFrame->GetContent(content);
|
||||||
content->CanContainChildren(isContainer);
|
content->CanContainChildren(isContainer);
|
||||||
if (isContainer) {
|
if (isContainer) {
|
||||||
// Wrap the floated element in a BODY frame.
|
// Wrap the frame in a BODY frame.
|
||||||
NS_NewBodyFrame(content, this, aWrapperFrame, NS_BODY_SHRINK_WRAP);/* XXX auto margins? */
|
NS_NewBodyFrame(content, this, aWrapperFrame, NS_BODY_SHRINK_WRAP);/* XXX auto margins? */
|
||||||
|
|
||||||
// The body wrapper frame gets the original style context, and the floated
|
// The body wrapper frame gets the original style context, and the wrapped
|
||||||
// frame gets a pseudo style context
|
// frame gets a pseudo style context
|
||||||
nsIStyleContext* kidStyle;
|
nsIStyleContext* kidStyle;
|
||||||
aFrame->GetStyleContext(&aPresContext, kidStyle);
|
aFrame->GetStyleContext(&aPresContext, kidStyle);
|
||||||
|
|
|
@ -215,18 +215,17 @@ nsHTMLContainerFrame::CreateWrapperFrame(nsIPresContext& aPresContext,
|
||||||
nsIFrame* aFrame,
|
nsIFrame* aFrame,
|
||||||
nsIFrame*& aWrapperFrame)
|
nsIFrame*& aWrapperFrame)
|
||||||
{
|
{
|
||||||
// If the floated element can contain children then wrap it in a
|
// If the frame can contain children then wrap it in a BODY frame
|
||||||
// BODY frame before floating it
|
|
||||||
nsIContent* content;
|
nsIContent* content;
|
||||||
PRBool isContainer;
|
PRBool isContainer;
|
||||||
|
|
||||||
aFrame->GetContent(content);
|
aFrame->GetContent(content);
|
||||||
content->CanContainChildren(isContainer);
|
content->CanContainChildren(isContainer);
|
||||||
if (isContainer) {
|
if (isContainer) {
|
||||||
// Wrap the floated element in a BODY frame.
|
// Wrap the frame in a BODY frame.
|
||||||
NS_NewBodyFrame(content, this, aWrapperFrame, NS_BODY_SHRINK_WRAP);/* XXX auto margins? */
|
NS_NewBodyFrame(content, this, aWrapperFrame, NS_BODY_SHRINK_WRAP);/* XXX auto margins? */
|
||||||
|
|
||||||
// The body wrapper frame gets the original style context, and the floated
|
// The body wrapper frame gets the original style context, and the wrapped
|
||||||
// frame gets a pseudo style context
|
// frame gets a pseudo style context
|
||||||
nsIStyleContext* kidStyle;
|
nsIStyleContext* kidStyle;
|
||||||
aFrame->GetStyleContext(&aPresContext, kidStyle);
|
aFrame->GetStyleContext(&aPresContext, kidStyle);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче