Remove QNetworkConfiguration::bearerName().
It was added only to maintain source compatibility with Qt Mobility. Change-Id: Iea8d40e401bd1f8d5115268e09b256eacca69ea0 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
This commit is contained in:
parent
44cf5592ac
commit
8ecc2da31d
2
dist/changes-5.0.0
vendored
2
dist/changes-5.0.0
vendored
@ -157,6 +157,8 @@ information about a particular change.
|
|||||||
|
|
||||||
- QTcpServer::incomingConnection() now takes a qintptr instead of an int.
|
- QTcpServer::incomingConnection() now takes a qintptr instead of an int.
|
||||||
|
|
||||||
|
- QNetworkConfiguration::bearerName() removed, and bearerTypeName() should be used.
|
||||||
|
|
||||||
|
|
||||||
****************************************************************************
|
****************************************************************************
|
||||||
* General *
|
* General *
|
||||||
|
@ -396,14 +396,6 @@ QList<QNetworkConfiguration> QNetworkConfiguration::children() const
|
|||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
|
||||||
\fn QString QNetworkConfiguration::bearerName() const
|
|
||||||
\deprecated
|
|
||||||
|
|
||||||
This function is deprecated. It is equivalent to calling bearerTypeName(), however
|
|
||||||
bearerType() should be used in preference.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
Returns the type of bearer used by this network configuration.
|
Returns the type of bearer used by this network configuration.
|
||||||
|
|
||||||
|
@ -108,10 +108,6 @@ public:
|
|||||||
Type type() const;
|
Type type() const;
|
||||||
Purpose purpose() const;
|
Purpose purpose() const;
|
||||||
|
|
||||||
#ifdef QT_DEPRECATED
|
|
||||||
// Required to maintain source compatibility with Qt Mobility.
|
|
||||||
QT_DEPRECATED inline QString bearerName() const { return bearerTypeName(); }
|
|
||||||
#endif
|
|
||||||
BearerType bearerType() const;
|
BearerType bearerType() const;
|
||||||
QString bearerTypeName() const;
|
QString bearerTypeName() const;
|
||||||
|
|
||||||
|
@ -273,17 +273,17 @@ void tst_QNetworkSession::sessionProperties()
|
|||||||
<< QLatin1String("WiMAX");
|
<< QLatin1String("WiMAX");
|
||||||
|
|
||||||
if (!configuration.isValid()) {
|
if (!configuration.isValid()) {
|
||||||
QVERIFY(configuration.bearerName().isEmpty());
|
QVERIFY(configuration.bearerTypeName().isEmpty());
|
||||||
} else {
|
} else {
|
||||||
switch (configuration.type())
|
switch (configuration.type())
|
||||||
{
|
{
|
||||||
case QNetworkConfiguration::ServiceNetwork:
|
case QNetworkConfiguration::ServiceNetwork:
|
||||||
case QNetworkConfiguration::UserChoice:
|
case QNetworkConfiguration::UserChoice:
|
||||||
default:
|
default:
|
||||||
QVERIFY(configuration.bearerName().isEmpty());
|
QVERIFY(configuration.bearerTypeName().isEmpty());
|
||||||
break;
|
break;
|
||||||
case QNetworkConfiguration::InternetAccessPoint:
|
case QNetworkConfiguration::InternetAccessPoint:
|
||||||
QVERIFY(validBearerNames.contains(configuration.bearerName()));
|
QVERIFY(validBearerNames.contains(configuration.bearerTypeName()));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1016,15 +1016,15 @@ QNetworkConfiguration suitableConfiguration(QString bearerType, QNetworkConfigur
|
|||||||
discoveredConfigs.removeOne(config);
|
discoveredConfigs.removeOne(config);
|
||||||
} else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
|
} else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
|
||||||
bearerType == "cellular") { // 'cellular' bearertype is for convenience
|
bearerType == "cellular") { // 'cellular' bearertype is for convenience
|
||||||
if (config.bearerName() != "2G" &&
|
if (config.bearerTypeName() != "2G" &&
|
||||||
config.bearerName() != "CDMA2000" &&
|
config.bearerTypeName() != "CDMA2000" &&
|
||||||
config.bearerName() != "WCDMA" &&
|
config.bearerTypeName() != "WCDMA" &&
|
||||||
config.bearerName() != "HSPA") {
|
config.bearerTypeName() != "HSPA") {
|
||||||
// qDebug() << "Dumping config because bearer mismatches (cellular): " << config.name();
|
// qDebug() << "Dumping config because bearer mismatches (cellular): " << config.name();
|
||||||
discoveredConfigs.removeOne(config);
|
discoveredConfigs.removeOne(config);
|
||||||
}
|
}
|
||||||
} else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
|
} else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
|
||||||
bearerType != config.bearerName()) {
|
bearerType != config.bearerTypeName()) {
|
||||||
// qDebug() << "Dumping config because bearer mismatches (WLAN): " << config.name();
|
// qDebug() << "Dumping config because bearer mismatches (WLAN): " << config.name();
|
||||||
discoveredConfigs.removeOne(config);
|
discoveredConfigs.removeOne(config);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user