Utilities/SingleApplication.py

changeset 465
c20e25deb33a
parent 97
c4086afea02b
child 500
c3abc7895a01
--- a/Utilities/SingleApplication.py	Mon Aug 09 15:36:47 2010 +0200
+++ b/Utilities/SingleApplication.py	Mon Aug 09 15:49:03 2010 +0200
@@ -28,7 +28,7 @@
             self.removeServer(name)
             self.listen(name)
         
-        self.connect(self, SIGNAL("newConnection()"), self.__newConnection)
+        self.newConnection[()].connect(self.__newConnection)
 
         self.qsock = None
 
@@ -45,8 +45,8 @@
 
         self.qsock = sock
 
-        self.connect(self.qsock, SIGNAL('readyRead()'), self.__parseLine)
-        self.connect(self.qsock, SIGNAL('disconnected()'), self.__disconnected)
+        self.qsock.readyRead[()].connect(self.__parseLine)
+        self.qsock.disconnected[()].connect(self.__disconnected)
 
     def __parseLine(self):
         """
@@ -78,7 +78,7 @@
         Public method used to shut down the server.
         """
         if self.qsock is not None:
-            self.disconnect(self.qsock, SIGNAL('readyRead()'), self.__parseLine)
+            self.qsock.readyRead[()].disconnect(self.__parseLine)
             self.disconnect(self.qsock, SIGNAL('disconnected()'), self.__disconnected)
         
         self.qsock = None
@@ -164,4 +164,4 @@
         
         @return error string for the last error (string)
         """
-        return self.sock.errorString()
+        return self.sock.errorString()
\ No newline at end of file

eric ide

mercurial