13 import zipfile |
13 import zipfile |
14 |
14 |
15 from PyQt4.QtGui import * |
15 from PyQt4.QtGui import * |
16 from PyQt4.QtCore import * |
16 from PyQt4.QtCore import * |
17 from PyQt4.QtNetwork import QNetworkAccessManager, QNetworkRequest, QNetworkReply |
17 from PyQt4.QtNetwork import QNetworkAccessManager, QNetworkRequest, QNetworkReply |
|
18 try: |
|
19 from PyQt4.QtNetwork import QSslError # __IGNORE_WARNING__ |
|
20 SSL_AVAILABLE = True |
|
21 except ImportError: |
|
22 SSL_AVAILABLE = False |
18 |
23 |
19 from .Ui_PluginRepositoryDialog import Ui_PluginRepositoryDialog |
24 from .Ui_PluginRepositoryDialog import Ui_PluginRepositoryDialog |
20 |
25 |
21 from E5Gui import E5MessageBox |
26 from E5Gui import E5MessageBox |
22 |
27 |
74 |
79 |
75 # attributes for the network objects |
80 # attributes for the network objects |
76 self.__networkManager = QNetworkAccessManager(self) |
81 self.__networkManager = QNetworkAccessManager(self) |
77 self.__networkManager.proxyAuthenticationRequired.connect( |
82 self.__networkManager.proxyAuthenticationRequired.connect( |
78 proxyAuthenticationRequired) |
83 proxyAuthenticationRequired) |
79 self.__networkManager.sslErrors.connect(self.__sslErrors) |
84 if SSL_AVAILABLE: |
|
85 self.__networkManager.sslErrors.connect(self.__sslErrors) |
80 self.__replies = [] |
86 self.__replies = [] |
81 |
87 |
82 self.__doneMethod = None |
88 self.__doneMethod = None |
83 self.__inDownload = False |
89 self.__inDownload = False |
84 self.__pluginsToDownload = [] |
90 self.__pluginsToDownload = [] |