diff options
author | Peter Hartmann <phartmann@blackberry.com> | 2013-06-07 14:59:39 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-06-24 15:09:06 +0200 |
commit | 687f002352a02f190591c10fded61b2e566f521e (patch) | |
tree | 756dd32914bfb1dc74ddad7ecfd705834e281b55 /src/plugins/bearer/blackberry | |
parent | 5defb3a36a3a9d71eaefd27a910b23b2fcd65c77 (diff) |
BlackBerry QNetworkConfiguration: Keep track of bearer type
I.e. let the user know whether he is on 2G / 3G / 4G.
Since usually apps are rather interested whether they are on Wifi or
cellular, change of cellular type (i.e. transition from 3G to 4G etc.)
will not trigger emission of the
"QNetworkConfigurationManager::configurationChanged" signal. The
cellular type check will only be performed if the user queries it by
calling the respective member methods (bearerType() and
bearerTypeName()).
Reading the cellular type takes around 1-2 milliseconds.
In addition, add new fields "BearerEVDO" and "BearerLTE" to the public
API for QNetworkConfiguration.
Change-Id: I4c4ec52926f862b84487c91a88b1e20e590dd793
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Diffstat (limited to 'src/plugins/bearer/blackberry')
-rw-r--r-- | src/plugins/bearer/blackberry/qbbengine.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/plugins/bearer/blackberry/qbbengine.cpp b/src/plugins/bearer/blackberry/qbbengine.cpp index ab1ba9aa19..37093a09ec 100644 --- a/src/plugins/bearer/blackberry/qbbengine.cpp +++ b/src/plugins/bearer/blackberry/qbbengine.cpp @@ -98,10 +98,9 @@ interfaceType(netstatus_interface_type_t type) return QNetworkConfiguration::BearerBluetooth; case NETSTATUS_INTERFACE_TYPE_CELLULAR: - //### TODO not sure which BearerType would be the best - //to return here. We need to be able to get more - //information on the bearer type in order to return - //the exact match. + // The exact bearer type is determined in QNetworkConfiguration + // at the time this info is queried, because opposed to the + // information here the type might change quickly. return QNetworkConfiguration::Bearer2G; case NETSTATUS_INTERFACE_TYPE_VPN: |