summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlex <qt-info@nokia.com>2010-08-05 07:43:52 (GMT)
committerAlex <qt-info@nokia.com>2010-08-05 07:43:52 (GMT)
commitd524da81ee257a6bd67d32d0bc870280a7d5b8a4 (patch)
tree02fb4029b77922e94c82cdcb3c13de5240454a0d /src
parent3d0b7905b18ada0e22e77b9c6670069dfd454adc (diff)
downloadQt-d524da81ee257a6bd67d32d0bc870280a7d5b8a4.zip
Qt-d524da81ee257a6bd67d32d0bc870280a7d5b8a4.tar.gz
Qt-d524da81ee257a6bd67d32d0bc870280a7d5b8a4.tar.bz2
Fix link error when building Bearer application with Qt Mobility
QtMobility uses the Qt header when compiling applications which link against Mobility's Bearer library. Therefore QNetworkConfiguration::bearerName() cannot be inline and refer to the new QNetworkConfiguration::bearerTypeName() function (which doesn't exist in Mobility) Task-number: QTBUG-12378 Reviewed-by: Rohan McGovern
Diffstat (limited to 'src')
-rw-r--r--src/network/bearer/qnetworkconfiguration.cpp7
-rw-r--r--src/network/bearer/qnetworkconfiguration.h2
2 files changed, 8 insertions, 1 deletions
diff --git a/src/network/bearer/qnetworkconfiguration.cpp b/src/network/bearer/qnetworkconfiguration.cpp
index 3190a30..60851ac 100644
--- a/src/network/bearer/qnetworkconfiguration.cpp
+++ b/src/network/bearer/qnetworkconfiguration.cpp
@@ -406,6 +406,13 @@ QList<QNetworkConfiguration> 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 d9d36fd..e4f762a 100644
--- a/src/network/bearer/qnetworkconfiguration.h
+++ b/src/network/bearer/qnetworkconfiguration.h
@@ -120,7 +120,7 @@ public:
Purpose purpose() const;
// Required to maintain source compatibility with Qt Mobility.
- QT_DEPRECATED inline QString bearerName() const { return bearerTypeName(); }
+ QT_DEPRECATED QString bearerName() const;
BearerType bearerType() const;
QString bearerTypeName() const;