summaryrefslogtreecommitdiffstats
path: root/src/network/access/qnetworkaccessmanager.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/network/access/qnetworkaccessmanager.h')
-rw-r--r--src/network/access/qnetworkaccessmanager.h17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/network/access/qnetworkaccessmanager.h b/src/network/access/qnetworkaccessmanager.h
index 694a54f..c57c9c6 100644
--- a/src/network/access/qnetworkaccessmanager.h
+++ b/src/network/access/qnetworkaccessmanager.h
@@ -70,7 +70,7 @@ class Q_NETWORK_EXPORT QNetworkAccessManager: public QObject
{
Q_OBJECT
- Q_PROPERTY(bool networkAccess READ networkAccessEnabled WRITE setNetworkAccessEnabled NOTIFY networkAccessChanged)
+ Q_PROPERTY(NetworkAccessibility networkAccessible READ networkAccessible WRITE setNetworkAccessible NOTIFY networkAccessibleChanged)
public:
enum Operation {
@@ -84,6 +84,12 @@ public:
UnknownOperation = 0
};
+ enum NetworkAccessibility {
+ UnknownAccessibility = -1,
+ NotAccessible = 0,
+ Accessible = 1
+ };
+
explicit QNetworkAccessManager(QObject *parent = 0);
~QNetworkAccessManager();
@@ -113,8 +119,8 @@ public:
QNetworkConfiguration configuration() const;
QNetworkConfiguration activeConfiguration() const;
- void setNetworkAccessEnabled(bool enabled);
- bool networkAccessEnabled() const;
+ void setNetworkAccessible(NetworkAccessibility accessible);
+ NetworkAccessibility networkAccessible() const;
Q_SIGNALS:
#ifndef QT_NO_NETWORKPROXY
@@ -126,9 +132,9 @@ Q_SIGNALS:
void sslErrors(QNetworkReply *reply, const QList<QSslError> &errors);
#endif
- void networkSessionOnline();
+ void networkSessionConnected();
- void networkAccessChanged(bool enabled);
+ void networkAccessibleChanged(QNetworkAccessManager::NetworkAccessibility accessible);
protected:
virtual QNetworkReply *createRequest(Operation op, const QNetworkRequest &request,
@@ -142,6 +148,7 @@ private:
Q_PRIVATE_SLOT(d_func(), void _q_networkSessionClosed())
Q_PRIVATE_SLOT(d_func(), void _q_networkSessionNewConfigurationActivated())
Q_PRIVATE_SLOT(d_func(), void _q_networkSessionPreferredConfigurationChanged(QNetworkConfiguration,bool))
+ Q_PRIVATE_SLOT(d_func(), void _q_networkSessionStateChanged(QNetworkSession::State))
};
QT_END_NAMESPACE