From d00cbd147146c7872d70d0cdf40d465579991e0f Mon Sep 17 00:00:00 2001 From: Fedor Date: Sun, 21 Jun 2020 01:06:54 +0300 Subject: [PATCH] Fix the wrong position when we calculate the position... --- layout/generic/nsAbsoluteContainingBlock.cpp | 4 +-- .../table-bordercollapse/bug1379306-ref.html | 31 +++++++++++++++++++ .../table-bordercollapse/bug1379306.html | 30 ++++++++++++++++++ .../table-bordercollapse/reftest.list | 1 + .../reftests/table-html/bug1379306-2-ref.html | 21 +++++++++++++ layout/reftests/table-html/bug1379306-2.html | 21 +++++++++++++ .../reftests/table-html/bug1379306-3-ref.html | 23 ++++++++++++++ layout/reftests/table-html/bug1379306-3.html | 23 ++++++++++++++ layout/reftests/table-html/reftest.list | 2 ++ 9 files changed, 154 insertions(+), 2 deletions(-) create mode 100644 layout/reftests/table-bordercollapse/bug1379306-ref.html create mode 100644 layout/reftests/table-bordercollapse/bug1379306.html create mode 100644 layout/reftests/table-html/bug1379306-2-ref.html create mode 100644 layout/reftests/table-html/bug1379306-2.html create mode 100644 layout/reftests/table-html/bug1379306-3-ref.html create mode 100644 layout/reftests/table-html/bug1379306-3.html diff --git a/layout/generic/nsAbsoluteContainingBlock.cpp b/layout/generic/nsAbsoluteContainingBlock.cpp index f444757e8..326468c07 100644 --- a/layout/generic/nsAbsoluteContainingBlock.cpp +++ b/layout/generic/nsAbsoluteContainingBlock.cpp @@ -658,8 +658,8 @@ nsAbsoluteContainingBlock::ReflowAbsoluteFrame(nsIFrame* aDelegat // Get the border values WritingMode outerWM = aReflowInput.GetWritingMode(); - const LogicalMargin border(outerWM, - aReflowInput.mStyleBorder->GetComputedBorder()); + const LogicalMargin border(outerWM, aDelegatingFrame->GetUsedBorder()); + LogicalMargin margin = kidReflowInput.ComputedLogicalMargin().ConvertTo(outerWM, wm); diff --git a/layout/reftests/table-bordercollapse/bug1379306-ref.html b/layout/reftests/table-bordercollapse/bug1379306-ref.html new file mode 100644 index 000000000..76c8ef813 --- /dev/null +++ b/layout/reftests/table-bordercollapse/bug1379306-ref.html @@ -0,0 +1,31 @@ + +Table Cell Testcase, bug 1379306 + +

Table Cell Testcase, bug 1379306

+ +
+ + + + +
+
+
+
\ No newline at end of file diff --git a/layout/reftests/table-bordercollapse/bug1379306.html b/layout/reftests/table-bordercollapse/bug1379306.html new file mode 100644 index 000000000..2d7f4bce4 --- /dev/null +++ b/layout/reftests/table-bordercollapse/bug1379306.html @@ -0,0 +1,30 @@ + +Table Cell Testcase, bug 1379306 + +

Table Cell Testcase, bug 1379306

+ + + + + +
+
+
\ No newline at end of file diff --git a/layout/reftests/table-bordercollapse/reftest.list b/layout/reftests/table-bordercollapse/reftest.list index 2610d202d..2cd93397e 100644 --- a/layout/reftests/table-bordercollapse/reftest.list +++ b/layout/reftests/table-bordercollapse/reftest.list @@ -3,6 +3,7 @@ == bug1375518-3.html bug1375518-ref.html == bug1375518-4.html bug1375518-4-ref.html == bug1375518-5.html bug1375518-5-ref.html +== bug1379306.html bug1379306-ref.html == bug1394226.html bug1394226-ref.html != bug1394226.html bug1394226-notref.html == bc_dyn_cell1.html bc_dyn_cell1_ref.html diff --git a/layout/reftests/table-html/bug1379306-2-ref.html b/layout/reftests/table-html/bug1379306-2-ref.html new file mode 100644 index 000000000..a02d92bb2 --- /dev/null +++ b/layout/reftests/table-html/bug1379306-2-ref.html @@ -0,0 +1,21 @@ + +Table Row Testcase, bug 1379306 + +

Table Row Testcase, bug 1379306

+ + + + + +
+
+
\ No newline at end of file diff --git a/layout/reftests/table-html/bug1379306-2.html b/layout/reftests/table-html/bug1379306-2.html new file mode 100644 index 000000000..f04d0219f --- /dev/null +++ b/layout/reftests/table-html/bug1379306-2.html @@ -0,0 +1,21 @@ + +Testcase, bug 1379306 + +

Table Row Testcase, bug 1379306

+ + + + + +
+
+
\ No newline at end of file diff --git a/layout/reftests/table-html/bug1379306-3-ref.html b/layout/reftests/table-html/bug1379306-3-ref.html new file mode 100644 index 000000000..ffb70b46e --- /dev/null +++ b/layout/reftests/table-html/bug1379306-3-ref.html @@ -0,0 +1,23 @@ + +Testcase, bug 1379306 + +

Table Row Group Testcase, bug 1379306

+ + + + + + + +
+
+
\ No newline at end of file diff --git a/layout/reftests/table-html/bug1379306-3.html b/layout/reftests/table-html/bug1379306-3.html new file mode 100644 index 000000000..3192902ef --- /dev/null +++ b/layout/reftests/table-html/bug1379306-3.html @@ -0,0 +1,23 @@ + +Testcase, bug 1379306 + +

Table Row Group Testcase, bug 1379306

+ + + + + + + +
+
+
\ No newline at end of file diff --git a/layout/reftests/table-html/reftest.list b/layout/reftests/table-html/reftest.list index 362a96096..c3a4010ca 100644 --- a/layout/reftests/table-html/reftest.list +++ b/layout/reftests/table-html/reftest.list @@ -1,2 +1,4 @@ == cell-align-stopped-at-table-1-standards.html cell-align-stopped-at-table-1-standards-ref.html == cell-align-stopped-at-table-1-quirks.html cell-align-stopped-at-table-1-quirks-ref.html +== bug1379306-2.html bug1379306-2-ref.html +== bug1379306-3.html bug1379306-3-ref.html