Fixed an issue in the web browser when using FTP. 5_2_x

Sat, 15 Sep 2012 20:57:06 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 15 Sep 2012 20:57:06 +0200
branch
5_2_x
changeset 2043
77954c09aacc
parent 2029
51e8278f2c3d
child 2049
966ae2a9069b

Fixed an issue in the web browser when using FTP.

Helpviewer/Network/FtpReply.py file | annotate | diff | comparison | revisions
--- a/Helpviewer/Network/FtpReply.py	Sat Sep 08 18:28:46 2012 +0200
+++ b/Helpviewer/Network/FtpReply.py	Sat Sep 15 20:57:06 2012 +0200
@@ -257,6 +257,8 @@
             else:
                 self.__setListContent()
         elif cmd == QFtp.Get:
+            self.__content.append(512 * b' ')
+            self.readyRead.emit()
             self.finished.emit()
             self.__ftp.close()
     
@@ -273,7 +275,6 @@
         Private slot to process data from the FTP server.
         """
         self.__content += self.__ftp.readAll()
-        self.readyRead.emit()
     
     def __setContent(self):
         """
@@ -401,6 +402,7 @@
             table
         )
         self.__content = QByteArray(content.encode("utf8"))
+        self.__content.append(512 * b' ')
         
         self.open(QIODevice.ReadOnly | QIODevice.Unbuffered)
         self.setHeader(QNetworkRequest.ContentTypeHeader, "text/html; charset=UTF-8")

eric ide

mercurial