Fixed an issue in the syntax checker dialog causing a faulty display in batch mode.

Tue, 20 Oct 2015 19:10:13 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Tue, 20 Oct 2015 19:10:13 +0200
changeset 4500
884269e383f7
parent 4499
40b40003a44f
child 4501
3224f20d8eb0

Fixed an issue in the syntax checker dialog causing a faulty display in batch mode.

Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py file | annotate | diff | comparison | revisions
diff -r 40b40003a44f -r 884269e383f7 Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py
--- a/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py	Sun Oct 18 17:41:17 2015 +0200
+++ b/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py	Tue Oct 20 19:10:13 2015 +0200
@@ -95,7 +95,8 @@
         @param sourcecode faulty line of code (string)
         @param isWarning flag indicating a warning message (boolean)
         """
-        if self.__lastFileItem is None:
+        if self.__lastFileItem is None or \
+                self.__lastFileItem.data(0, self.filenameRole) != file:
             # It's a new file
             self.__lastFileItem = QTreeWidgetItem(self.resultList, [file])
             self.__lastFileItem.setFirstColumnSpanned(True)
@@ -306,6 +307,7 @@
                 try:
                     source = Utilities.readEncodedFile(fn)[0]
                     source = Utilities.normalizeCode(source)
+                    source = source.splitlines()
                 except (UnicodeError, IOError):
                     source = ""
             else:

eric ide

mercurial