Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(146)

Unified Diff: Source/WebCore/rendering/mathml/RenderMathMLSubSup.cpp

Issue 11418230: Merge 133221 - REGRESSION (r128837): mathml/presentation/subsup.xhtml became flaky (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1312/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebCore/rendering/mathml/RenderMathMLSubSup.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/rendering/mathml/RenderMathMLSubSup.cpp
===================================================================
--- Source/WebCore/rendering/mathml/RenderMathMLSubSup.cpp (revision 136093)
+++ Source/WebCore/rendering/mathml/RenderMathMLSubSup.cpp (working copy)
@@ -61,8 +61,12 @@
return toRenderBoxModelObject(base);
}
-void RenderMathMLSubSup::fixScriptsStyle()
+void RenderMathMLSubSup::fixAnonymousStyles()
{
+ // Set the base wrapper's style so that baseHeight in layout() will be an unstretched height.
+ ASSERT(firstChild() && firstChild()->style()->refCount() == 1);
+ firstChild()->style()->setAlignSelf(AlignFlexStart);
+
ASSERT(m_scripts && m_scripts->style()->refCount() == 1);
RenderStyle* scriptsStyle = m_scripts->style();
scriptsStyle->setFlexDirection(FlowColumn);
@@ -80,7 +84,8 @@
m_scripts = createAnonymousMathMLBlock();
RenderMathMLBlock::addChild(m_scripts);
- fixScriptsStyle();
+
+ fixAnonymousStyles();
}
if (firstChild()->isEmpty())
@@ -93,8 +98,8 @@
{
RenderMathMLBlock::styleDidChange(diff, oldStyle);
- if (m_scripts)
- fixScriptsStyle();
+ if (!isEmpty())
+ fixAnonymousStyles();
}
RenderMathMLOperator* RenderMathMLSubSup::unembellishedOperator()
« no previous file with comments | « Source/WebCore/rendering/mathml/RenderMathMLSubSup.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698