From 7e4807fed07e4c96086af00338601223b3353d29 Mon Sep 17 00:00:00 2001 From: Aaron McCarthy Date: Fri, 13 Aug 2010 13:58:46 +1000 Subject: Better fix for d524da81ee257a6bd67d32d0bc870280a7d5b8a4. Wrap new APIs in ifndef QT_MOBILITY_BEARER. --- src/network/bearer/qnetworkconfiguration.cpp | 7 ------- src/network/bearer/qnetworkconfiguration.h | 10 ++++++++-- src/s60installs/eabi/QtNetworku.def | 2 +- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/src/network/bearer/qnetworkconfiguration.cpp b/src/network/bearer/qnetworkconfiguration.cpp index 60851ac..3190a30 100644 --- a/src/network/bearer/qnetworkconfiguration.cpp +++ b/src/network/bearer/qnetworkconfiguration.cpp @@ -406,13 +406,6 @@ QList QNetworkConfiguration::children() const This function is deprecated. It is equivalent to calling bearerTypeName(), however bearerType() should be used in preference. */ -QString QNetworkConfiguration::bearerName() const -{ - // This function cannot be inline as it would break Qt Mobility. - // Qt Mobility uses the Qt header as well and since the Mobility Bearer library - // does not provide bearerTypeName() we cannot use an inline function. - return bearerTypeName(); -} /*! Returns the type of bearer used by this network configuration. diff --git a/src/network/bearer/qnetworkconfiguration.h b/src/network/bearer/qnetworkconfiguration.h index 18b92a9..593dbbe 100644 --- a/src/network/bearer/qnetworkconfiguration.h +++ b/src/network/bearer/qnetworkconfiguration.h @@ -103,6 +103,7 @@ public: Q_DECLARE_FLAGS(StateFlags, StateFlag) +#ifndef QT_MOBILITY_BEARER enum BearerType { BearerUnknown, BearerEthernet, @@ -114,17 +115,22 @@ public: BearerBluetooth, BearerWiMAX }; +#endif StateFlags state() const; Type type() const; Purpose purpose() const; - // Required to maintain source compatibility with Qt Mobility. +#ifndef QT_MOBILITY_BEARER #ifdef QT_DEPRECATED - QT_DEPRECATED QString bearerName() const; + // Required to maintain source compatibility with Qt Mobility. + QT_DEPRECATED inline QString bearerName() const { return bearerTypeName(); } #endif BearerType bearerType() const; QString bearerTypeName() const; +#else + QString bearerName() const; +#endif QString identifier() const; bool isRoamingAvailable() const; diff --git a/src/s60installs/eabi/QtNetworku.def b/src/s60installs/eabi/QtNetworku.def index 2442ee8..6b34a19 100644 --- a/src/s60installs/eabi/QtNetworku.def +++ b/src/s60installs/eabi/QtNetworku.def @@ -1131,7 +1131,7 @@ EXPORTS _ZNK21QNetworkAccessManager13configurationEv @ 1130 NONAME _ZNK21QNetworkAccessManager17networkAccessibleEv @ 1131 NONAME _ZNK21QNetworkAccessManager19activeConfigurationEv @ 1132 NONAME - _ZNK21QNetworkConfiguration10bearerNameEv @ 1133 NONAME + _ZNK21QNetworkConfiguration10bearerNameEv @ 1133 NONAME ABSENT _ZNK21QNetworkConfiguration10identifierEv @ 1134 NONAME _ZNK21QNetworkConfiguration18isRoamingAvailableEv @ 1135 NONAME _ZNK21QNetworkConfiguration4nameEv @ 1136 NONAME -- cgit v0.12