UI/CompareDialog.py

changeset 5596
4550d8e34765
parent 5389
9b1c800daff3
child 5603
4f2dd0850803
--- a/UI/CompareDialog.py	Thu Mar 09 17:42:44 2017 +0100
+++ b/UI/CompareDialog.py	Thu Mar 09 17:56:06 2017 +0100
@@ -73,12 +73,12 @@
             yield ('e', linenumberformat.format(ln1), l1,
                    linenumberformat.format(ln2), l2)
             continue
-        if ln2 == "" and l2 == "\n":
+        if ln2 == "" and l2 in ("\r\n", "\n", "\r"):
             yield ('d', linenumberformat.format(ln1), removeMarkers(l1),
-                   emptylineno, '\n')
+                   emptylineno, l2)
             continue
-        if ln1 == "" and l1 == "\n":
-            yield ('i', emptylineno, '\n',
+        if ln1 == "" and l1 in ("\r\n", "\n", "\r"):
+            yield ('i', emptylineno, l1,
                    linenumberformat.format(ln2), removeMarkers(l2))
             continue
         yield ('r', linenumberformat.format(ln1), l1,

eric ide

mercurial