Merge pull request #3139 from emanuelschuetze/diff-mode-pdf

Cleanup pdf parsing code for indentation fix in diff mode.
This commit is contained in:
Norman Jäckel 2017-03-24 14:50:46 +01:00 committed by GitHub
commit 33a61cb340

View File

@ -694,8 +694,9 @@ angular.module('OpenSlidesApp.core.pdf', [])
pObjectToPush = stackP; //usually we want to push stackP pObjectToPush = stackP; //usually we want to push stackP
if (lineNumberMode === "outside") { if (lineNumberMode === "outside") {
if (element.childNodes.length > 0) { //if we hit = 0, the code would fail if (element.childNodes.length > 0) { //if we hit = 0, the code would fail
var pChildTagName = element.childNodes[0].tagName; // add empty line number column for inline diff or pragraph diff mode
if (pChildTagName === "INS" || pChildTagName === undefined) { //the desired case if (element.childNodes[0].tagName === "INS" ||
element.getAttribute("class") === "insert") {
var pLineNumberPlaceholder = { var pLineNumberPlaceholder = {
width: 20, width: 20,
text: "", text: "",