Bug 1229278 - Fix dynamic changes to text-emphasis-style. r=dbaron

This commit is contained in:
Xidorn Quan 2015-12-04 11:58:59 +11:00
parent 30a51036a9
commit d9bb5a130f
4 changed files with 36 additions and 8 deletions

View File

@ -0,0 +1,12 @@
<!doctype html>
<html lang="ja">
<meta charset="UTF-8">
<title>Bug 1229278 - Dynamic change to text-emphasis-style</title>
<style>
div {
line-height: 5;
text-emphasis-style: filled triangle;
}
</style>
<div>テスト</div>
</html>

View File

@ -0,0 +1,20 @@
<!doctype html>
<html lang="ja" class="reftest-wait">
<meta charset="UTF-8">
<title>Bug 1229278 - Dynamic change to text-emphasis-style</title>
<style>
div {
line-height: 5;
text-emphasis-style: filled triangle;
}
.reftest-wait div {
text-emphasis-style: filled circle;
}
</style>
<div>テスト</div>
<script>
document.addEventListener("MozReftestInvalidate", function() {
document.documentElement.className = "";
});
</script>
</html>

View File

@ -109,3 +109,4 @@ fuzzy-if(OSX==1010,1,2) == underline-button-2.html underline-button-2-ref.html
== underline-select-2.html underline-select-2-ref.html
== 1133392.html 1133392-ref.html
!= 1159729-offset-adjustment.html 1159729-offset-adjustment-notref.html
pref(layout.css.text-emphasis.enabled,true) == emphasis-style-dynamic.html emphasis-style-dynamic-ref.html

View File

@ -3640,15 +3640,10 @@ nsChangeHint nsStyleText::CalcDifference(const nsStyleText& aOther) const
nsChangeHint_RepaintFrame;
}
if (!AreShadowArraysEqual(mTextShadow, aOther.mTextShadow)) {
return nsChangeHint_UpdateSubtreeOverflow |
nsChangeHint_SchedulePaint |
nsChangeHint_RepaintFrame;
}
if (mTextEmphasisStyle != aOther.mTextEmphasisStyle ||
if (!AreShadowArraysEqual(mTextShadow, aOther.mTextShadow) ||
mTextEmphasisStyle != aOther.mTextEmphasisStyle ||
mTextEmphasisStyleString != aOther.mTextEmphasisStyleString) {
return nsChangeHint_UpdateOverflow |
return nsChangeHint_UpdateSubtreeOverflow |
nsChangeHint_SchedulePaint |
nsChangeHint_RepaintFrame;
}