Removed hack from section splitter
This commit is contained in:
parent
9898cbc5ed
commit
e2d03d7f93
1 changed files with 4 additions and 4 deletions
|
@ -12,6 +12,7 @@ import org.w3c.dom.Element;
|
|||
import org.w3c.dom.Node;
|
||||
import org.w3c.dom.NodeList;
|
||||
|
||||
import pro.litvinovg.xml.Debug;
|
||||
import w2phtml.office.OfficeReader;
|
||||
|
||||
public class SectionSplitter extends BasicSplitter implements ISplitter {
|
||||
|
@ -53,8 +54,11 @@ public class SectionSplitter extends BasicSplitter implements ISplitter {
|
|||
continue;
|
||||
} else if (nodeName.equals(TABLE_TABLE)) {
|
||||
if (factory.split(child).isDataMoved()){
|
||||
//Debug.prettyPrintXml(section.getOwnerDocument());
|
||||
sectionFirstPart.appendChild(child.getPreviousSibling());
|
||||
results.setDataMoved(true);
|
||||
//Debug.prettyPrintXml(section.getOwnerDocument());
|
||||
|
||||
}
|
||||
} else if (nodeName.equals(TEXT_SECTION)) {
|
||||
if (factory.split(child).isDataMoved()){
|
||||
|
@ -66,10 +70,6 @@ public class SectionSplitter extends BasicSplitter implements ISplitter {
|
|||
if (listSplitResults.isDataMoved()){
|
||||
results.setDataMoved(true);
|
||||
sectionFirstPart.appendChild(listSplitResults.getFirstPart());
|
||||
Node textListSpb = listSplitResults.getSPB();
|
||||
if (textListSpb != null) {
|
||||
textListSpb.getParentNode().removeChild(textListSpb);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
System.out.println("Error. SPB in Section child node " + nodeName);
|
||||
|
|
Loading…
Add table
Reference in a new issue