6 """ |
6 """ |
7 Module implementing a network access manager proxy for web pages. |
7 Module implementing a network access manager proxy for web pages. |
8 """ |
8 """ |
9 |
9 |
10 from PyQt4.QtCore import SIGNAL |
10 from PyQt4.QtCore import SIGNAL |
11 from PyQt4.QtNetwork import QNetworkAccessManager, QNetworkRequest |
11 from PyQt4.QtNetwork import QNetworkAccessManager, QNetworkRequest, QNetworkReply |
12 |
12 |
13 class NetworkAccessManagerProxy(QNetworkAccessManager): |
13 class NetworkAccessManagerProxy(QNetworkAccessManager): |
14 """ |
14 """ |
15 Class implementing a network access manager proxy for web pages. |
15 Class implementing a network access manager proxy for web pages. |
16 """ |
16 """ |
58 SIGNAL('proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *)')) |
58 SIGNAL('proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *)')) |
59 self.connect(self, |
59 self.connect(self, |
60 SIGNAL('authenticationRequired(QNetworkReply *, QAuthenticator *)'), |
60 SIGNAL('authenticationRequired(QNetworkReply *, QAuthenticator *)'), |
61 self.__class__.primaryManager, |
61 self.__class__.primaryManager, |
62 SIGNAL('authenticationRequired(QNetworkReply *, QAuthenticator *)')) |
62 SIGNAL('authenticationRequired(QNetworkReply *, QAuthenticator *)')) |
63 self.connect(self, SIGNAL("finished(QNetworkReply *)"), |
63 self.finished[QNetworkReply].connect(self.__class__.primaryManager.finished) |
64 self.__class__.primaryManager, SIGNAL("finished(QNetworkReply *)")) |
|
65 |
64 |
66 def createRequest(self, op, request, outgoingData = None): |
65 def createRequest(self, op, request, outgoingData = None): |
67 """ |
66 """ |
68 Protected method to create a request. |
67 Protected method to create a request. |
69 |
68 |