diff --git a/layout/reftests/bugs/1069716-1-ref.html b/layout/reftests/bugs/1069716-1-ref.html
new file mode 100644
index 00000000000..e2ed8da169b
--- /dev/null
+++ b/layout/reftests/bugs/1069716-1-ref.html
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+ - <---That should be a 'b' character.
diff --git a/layout/reftests/bugs/1069716-1.html b/layout/reftests/bugs/1069716-1.html
new file mode 100644
index 00000000000..2615a1f01e7
--- /dev/null
+++ b/layout/reftests/bugs/1069716-1.html
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
- <---That should be a 'b' character.
diff --git a/layout/reftests/bugs/reftest.list b/layout/reftests/bugs/reftest.list
index 7de2777aa66..71c99829760 100644
--- a/layout/reftests/bugs/reftest.list
+++ b/layout/reftests/bugs/reftest.list
@@ -1834,3 +1834,4 @@ test-pref(layout.css.grid.enabled,true) == 1053035-1-grid.html 1053035-1-ref.htm
== 1059498-2.html 1059498-1-ref.html
== 1059498-3.html 1059498-1-ref.html
test-pref(dom.webcomponents.enabled,true) == 1066554-1.html 1066554-1-ref.html
+== 1069716-1.html 1069716-1-ref.html
diff --git a/layout/style/nsStyleStruct.cpp b/layout/style/nsStyleStruct.cpp
index ab5c0257a66..5c5c77ca2eb 100644
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -704,9 +704,12 @@ nsChangeHint nsStyleList::CalcDifference(const nsStyleList& aOther) const
if (mListStylePosition != aOther.mListStylePosition)
return NS_STYLE_HINT_FRAMECHANGE;
if (EqualImages(mListStyleImage, aOther.mListStyleImage) &&
- mListStyleType == aOther.mListStyleType) {
- if (mImageRegion.IsEqualInterior(aOther.mImageRegion))
+ mCounterStyle == aOther.mCounterStyle) {
+ if (mImageRegion.IsEqualInterior(aOther.mImageRegion)) {
+ if (mListStyleType != aOther.mListStyleType)
+ return nsChangeHint_NeutralChange;
return NS_STYLE_HINT_NONE;
+ }
if (mImageRegion.width == aOther.mImageRegion.width &&
mImageRegion.height == aOther.mImageRegion.height)
return NS_STYLE_HINT_VISUAL;
diff --git a/layout/style/nsStyleStruct.h b/layout/style/nsStyleStruct.h
index 71c883be0f5..59db408fd96 100644
--- a/layout/style/nsStyleStruct.h
+++ b/layout/style/nsStyleStruct.h
@@ -1154,7 +1154,8 @@ struct nsStyleList {
nsChangeHint CalcDifference(const nsStyleList& aOther) const;
static nsChangeHint MaxDifference() {
- return NS_STYLE_HINT_FRAMECHANGE;
+ return NS_CombineHint(NS_STYLE_HINT_FRAMECHANGE,
+ nsChangeHint_NeutralChange);
}
static nsChangeHint MaxDifferenceNeverInherited() {
// CalcDifference never returns nsChangeHint_NeedReflow or