]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Simplified addAreasAndFlushRow
authorVincent Hennebert <vhennebert@apache.org>
Thu, 10 Jan 2008 17:54:16 +0000 (17:54 +0000)
committerVincent Hennebert <vhennebert@apache.org>
Thu, 10 Jan 2008 17:54:16 +0000 (17:54 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@610853 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/layoutmgr/table/RowPainter.java

index 3df06e482dbfa40a9975d10ee4b4cddcaac6635c..f31076537dbecfc0f9c439ceb7fe46d8d9f64902 100644 (file)
@@ -169,27 +169,11 @@ class RowPainter {
         tclm.addRowBackgroundArea(rowFO, actualRowHeight, layoutContext.getRefIPD(), yoffset);
         for (int i = 0; i < primaryGridUnits.length; i++) {
             GridUnit currentGU = lastRow.getGridUnit(i);            
-            if (primaryGridUnits[i] != null) {
-                if (forcedFlush || currentGU.isLastGridUnitRowSpan()) {
-                    //the last line in the "if" above is to avoid a premature end of a
-                    //row-spanned cell because no CellParts are generated after a cell is
-                    //finished with its content.
-                    //See table-cell_number-rows-spanned_bug38397.xml
-                    addAreasForCell(primaryGridUnits[i], start[i], end[i], lastRow, partBPD[i],
-                            actualRowHeight);
-                    primaryGridUnits[i] = null;
-                    start[i] = 0;
-                    end[i] = -1;
-                    partBPD[i] = 0;
-                }
-            } else if (!currentGU.isEmpty()
-                    && currentGU.getColSpanIndex() == 0
+            if (!currentGU.isEmpty() && currentGU.getColSpanIndex() == 0
                     && (forcedFlush || currentGU.isLastGridUnitRowSpan())) {
-                //A row-spanned cell has finished contributing content on the previous page
-                //and now still has to cause grid units to be painted.
-                //See table-cell_page-break_span.xml
                 addAreasForCell(currentGU.getPrimary(), start[i], end[i], lastRow, partBPD[i],
                         actualRowHeight);
+                primaryGridUnits[i] = null;
                 start[i] = 0;
                 end[i] = -1;
                 partBPD[i] = 0;