|
|
|
@ -175,14 +175,18 @@ int main(int argv, char** argc) try { |
|
|
|
|
appTranslator.load(":/language/swisssurfer_"+ QLocale::system().name()); |
|
|
|
|
app.installTranslator(&appTranslator); |
|
|
|
|
//............................................................................
|
|
|
|
|
QNetworkProxy::setApplicationProxy |
|
|
|
|
(QNetworkProxy |
|
|
|
|
((env["PROXY_TYPE"]=="http" |
|
|
|
|
? QNetworkProxy::HttpProxy |
|
|
|
|
: (env["PROXY_TYPE"]=="socks" |
|
|
|
|
? QNetworkProxy::Socks5Proxy |
|
|
|
|
: QNetworkProxy::NoProxy)), |
|
|
|
|
env["PROXY_HOST"], env["PROXY_PORT"].toInt())); |
|
|
|
|
if (env["PROXY_TYPE"]=="http") |
|
|
|
|
QNetworkProxy::setApplicationProxy |
|
|
|
|
(QNetworkProxy |
|
|
|
|
(QNetworkProxy::HttpProxy, |
|
|
|
|
env["PROXY_HOST"], env["PROXY_PORT"].toInt())); |
|
|
|
|
if (env["PROXY_TYPE"]=="socks") |
|
|
|
|
QNetworkProxy::setApplicationProxy |
|
|
|
|
(QNetworkProxy |
|
|
|
|
(QNetworkProxy::Socks5Proxy, |
|
|
|
|
env["PROXY_HOST"], env["PROXY_PORT"].toInt())); |
|
|
|
|
else |
|
|
|
|
QNetworkProxyFactory::setUseSystemConfiguration(true); |
|
|
|
|
qDebug()<<"***************************************************************"; |
|
|
|
|
qDebug()<<"Start - Proxy:" |
|
|
|
|
<<(QNetworkProxy::applicationProxy().type()==QNetworkProxy::NoProxy |
|
|
|
|