summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/css
diff options
context:
space:
mode:
authorSteve Block <steveblock@google.com>2012-04-13 07:45:56 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-04-13 07:45:56 -0700
commit11509d7f3708f8559703a5cc689a212af4efee62 (patch)
tree7aee7ea8684ab2604bcbd350309924feaa5cd5f4 /Source/WebCore/css
parent0d7a0fca6004661544e8bdfff9f96a0094eb0d4d (diff)
parentbb0dba49203d72577b8eac34537c9c671ba9bec7 (diff)
downloadexternal_webkit-11509d7f3708f8559703a5cc689a212af4efee62.zip
external_webkit-11509d7f3708f8559703a5cc689a212af4efee62.tar.gz
external_webkit-11509d7f3708f8559703a5cc689a212af4efee62.tar.bz2
Merge "Cherry-pick WebKit change r96122 to fix a LayoutTest crash"
Diffstat (limited to 'Source/WebCore/css')
-rw-r--r--Source/WebCore/css/CSSStyleSelector.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/WebCore/css/CSSStyleSelector.cpp b/Source/WebCore/css/CSSStyleSelector.cpp
index 613bf4a..e49ad2a 100644
--- a/Source/WebCore/css/CSSStyleSelector.cpp
+++ b/Source/WebCore/css/CSSStyleSelector.cpp
@@ -4971,6 +4971,11 @@ void CSSStyleSelector::applyProperty(int id, CSSValue *value)
applyProperty(CSSPropertyFontStyle, font->style.get());
applyProperty(CSSPropertyFontVariant, font->variant.get());
applyProperty(CSSPropertyFontWeight, font->weight.get());
+ // The previous properties can dirty our font but they don't try to read the font's
+ // properties back, which is safe. However if font-size is using the 'ex' unit, it will
+ // need query the dirtied font's x-height to get the computed size. To be safe in this
+ // case, let's just update the font now.
+ updateFont();
applyProperty(CSSPropertyFontSize, font->size.get());
m_lineHeightValue = font->lineHeight.get();