Ignore:
Timestamp:
01/29/10 15:16:05 (12 years ago)
Author:
pavelpa <pavelpa@…>
Branches:
master, qt5
Children:
6645e1f
Parents:
5007fde
Message:

implemented 'proxy settings' dialog

  • user can secify proxy for network communication
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gui/mainwindow.cpp

    r5007fde ra023fd2  
    2222
    2323#include <tabcontainer.h>
    24 
    25 const QString PROXY_URL("192.168.0.252");
    26 const quint16 PROXY_PORT = 4040;
     24#include <appsettings.h>
     25
    2726const QString PROXY_USERNAME;
    2827const QString PROXY_PASSWD;
    29 const bool DIRECT_CONNECTION = false;
    3028
    3129MainWindow::MainWindow(int aEventId, QWidget *aParent)
     
    3432    setupUi(this);
    3533
    36     qDebug() << "Setting-up proxy: " << PROXY_URL << ":" << PROXY_PORT;
    37     QNetworkProxy proxy(DIRECT_CONNECTION ? QNetworkProxy::NoProxy : QNetworkProxy::HttpProxy,
    38             PROXY_URL, PROXY_PORT, PROXY_USERNAME, PROXY_PASSWD);
     34    qDebug() << "Setting-up proxy: " << AppSettings::proxyAddress() << ":" << AppSettings::proxyPort();
     35    QNetworkProxy proxy(
     36            AppSettings::isDirectConnection() ? QNetworkProxy::NoProxy : QNetworkProxy::HttpProxy,
     37            AppSettings::proxyAddress(),
     38            AppSettings::proxyPort(),
     39            PROXY_USERNAME,
     40            PROXY_PASSWD);
    3941    QNetworkProxy::setApplicationProxy(proxy);
    4042
Note: See TracChangeset for help on using the changeset viewer.