summaryrefslogtreecommitdiffstats
path: root/src/network/bearer
Commit message (Collapse)AuthorAgeFilesLines
* Add Q_DECL_OVERRIDE in the src subdirectoryOlivier Goffart2014-12-031-2/+2
| | | | | | | | | | Done automatically with clang-modernize on linux (But does not add Q_DECL_OVERRIDE to the function that are marked as inline because it a compilation error with MSVC2010) Change-Id: I2196ee26e3e6fe20816834ecea5ea389eeab3171 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Doc: Use title case in section1 titlesNico Vertriest2014-09-301-1/+1
| | | | | | | | Using Python script title-cased.py Task-number: QTBUG-41250 Change-Id: I00d3d7a0b30db7304a7904efd6d63abd9a7b493b Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* Update license headers and add new license filesMatti Paaso2014-09-2416-304/+176
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Fix crash in QNetworkAccessManager.Jędrzej Nowacki2014-05-192-4/+12
| | | | | | | | | | Recreating QCoreApplication could cause a crash in QNetworkAccessManager constructor. That was caused by an invalid shutdown detection introduced in f273d6fbc02055ff3999adc0df76360ca0670435. Task-number: QTBUG-36897 Change-Id: Ib5bba773a2a4fcde690a3a93680aef551aae3a5b Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
* network: fix doc typo in QNetworkConfigurationManagerPeter Hartmann2014-02-251-1/+1
| | | | | Change-Id: I6d3e7e4fb62dfc13f3cc156138604cabea119b75 Reviewed-by: Richard J. Moore <rich@kde.org>
* Doc: Fix miscellaneous typosSze Howe Koh2013-10-301-1/+0
| | | | | | Change-Id: Iaf0dd8974c3ad78beffa995c596a76fb3e4cceab Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Kurt Pattyn <pattyn.kurt@gmail.com>
* Doc: Adding mark-up to boolean default values.Jerome Pasion2013-10-084-12/+12
| | | | | | | | | | | | | | | | | Default values should have mark-up to denote that they are code. This commit changes: -"property is true" to "property is \c true". -"Returns true" to "Returns \c true". -"property is false" to "property is \c false". -"returns true" to "returns \c true". -"returns false" to "returns \c false". src/3rdparty and non-documentation instances were ignored. Task-number: QTBUG-33360 Change-Id: Ie87eaa57af947caa1230602b61c5c46292a4cf4e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Fix compilation on BlackBerry PlaybookRafael Roquetto2013-09-031-0/+7
| | | | | | | | | Implement pps_decoder_is_integer() function, which is not present on Playbook by default. Change-Id: Iff0974f3f178bf9c39aa05b4e1be87b2b7a9344e Reviewed-by: Peter Hartmann <phartmann@blackberry.com> Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
* QNetworkConfiguration: add public member bearerTypeFamily()Peter Hartmann2013-06-282-3/+72
| | | | | | | | | | | ... to let the user know whether he is on e.g. Wifi, 2G, 3G or 4G. In most cases, this is what the user wants to know anyhow, while e.g. BearerEVDO or BearerCDMA2000 go into too much detail. Task-number: QTBUG-31828 Change-Id: I244a4473feb40e106cbc08e09afdee07d4ecc8d7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lorn Potter <lorn.potter@jollamobile.com>
* BlackBerry QNetworkConfiguration: Keep track of bearer typePeter Hartmann2013-06-242-1/+118
| | | | | | | | | | | | | | | | | | | | | | 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>
* Silence warning in QtNetwork buildThiago Macieira2013-06-031-0/+1
| | | | | | | | | | qnetworkconfigmanager.cpp:63:9: error: unused variable ‘shutdown’ [-Werror=unused-variable] This warning was introduced by f273d6fbc02055ff3999adc0df76360ca0670435 Change-Id: Ied650a4d94d18495684a8f08ab5f2cd628026fb7 Reviewed-by: Jonas Gastal <gastal@intel.com> Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
* QNetworkConfigurationManager: check whether app is shutting downPeter Hartmann2013-04-101-1/+5
| | | | | | | | | | | | | | | | ... before trying to update the configurations. Before, we would check whether the pointer to the QNetworkConfigurationManagerPrivate instance was 0 and in that case construct it. This would mean that this code path was taken "at app shutdown", i.e. when the qAddPostRoutine had already been called but the other statics were still accessed. Note: This is not thread safe, but neither is the rest of the code; making it thread-safe would require additional changes. Task-number: QTBUG-30585 Change-Id: I8f6cf616e3f3ba1e84b8246589fb7210d2dae57a Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Whitespace cleanup: remove trailing whitespaceAxel Waggershauser2013-03-163-56/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | Remove all trailing whitespace from the following list of files: *.cpp *.h *.conf *.qdoc *.pro *.pri *.mm *.rc *.pl *.qps *.xpm *.txt *README excluding 3rdparty, test-data and auto generated code. Note A): the only non 3rdparty c++-files that still have trailing whitespace after this change are: * src/corelib/codecs/cp949codetbl_p.h * src/corelib/codecs/qjpunicode.cpp * src/corelib/codecs/qbig5codec.cpp * src/corelib/xml/qxmlstream_p.h * src/tools/qdoc/qmlparser/qqmljsgrammar.cpp * src/tools/uic/ui4.cpp * tests/auto/other/qtokenautomaton/tokenizers/* * tests/benchmarks/corelib/tools/qstring/data.cpp * util/lexgen/tokenizer.cpp Note B): in about 30 files some overlapping 'leading tab' and 'TAB character in non-leading whitespace' issues have been fixed to make the sanity bot happy. Plus some general ws-fixes here and there as asked for during review. Change-Id: Ia713113c34d82442d6ce4d93d8b1cf545075d11d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-02-141-0/+11
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/concurrent/doc/qtconcurrent.qdocconf src/corelib/doc/qtcore.qdocconf src/corelib/global/qglobal.h src/dbus/doc/qtdbus.qdocconf src/dbus/qdbusmessage.h src/gui/doc/qtgui.qdocconf src/gui/image/qimagereader.cpp src/network/doc/qtnetwork.qdocconf src/opengl/doc/qtopengl.qdocconf src/opengl/qgl.h src/plugins/platforms/windows/qwindowswindow.cpp src/printsupport/doc/qtprintsupport.qdocconf src/sql/doc/qtsql.qdocconf src/testlib/doc/qttestlib.qdocconf src/tools/qdoc/doc/config/qt-cpp-ignore.qdocconf src/widgets/doc/qtwidgets.qdocconf src/xml/doc/qtxml.qdocconf Change-Id: Ie9a1fa2cc44bec22a0b942e817a1095ca3414629
| * BlackBerry bearer plugin: check whether device is online several timesPeter Hartmann2013-01-311-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is supposed to workaround a race condition in the underlying netstatus API: Sometimes we get an event that the Wifi interface changed, but it is not up, e.g. no gateway (yet). In that case we need to check back (currently: 300 ms) whether the interface has come up or not. This commit can be reverted again once the race condition in the netstatus API has been resolved. Task-number: QTBUG-29421 Change-Id: I215ce8aae4848b6e942e77c6425adba90e9cc526 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* | QtNetwork: give started threads more verbose namingPeter Hartmann2013-02-071-1/+1
| | | | | | | | | | | | | | | | | | | | i.e. make it obvious that they come from Qt. This helps when debugging and trying to differ user created threads from Qt threads. Change-Id: Idd6804246d6676b17cf15de6b644a5be629aa023 Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Remove QT_{BEGIN,END}_HEADER macro usageSergio Ahumada2013-01-294-16/+0
|/ | | | | | | | | | | The macro was made empty in ba3dc5f3b56d1fab6fe37fe7ae08096d7dc68bcb and is no longer necessary or used. Discussed-on: http://lists.qt-project.org/pipermail/development/2013-January/009284.html Change-Id: Id2bb2e2cabde059305d4af5f12593344ba30f001 Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: hjk <hjk121@nokiamail.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-1816-16/+16
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Docs: Fixed enum and parameter links for networkOliver Wolff2012-12-012-3/+3
| | | | | Change-Id: Ie04e09d91e9b0781dc3bcbfe271c851fbe486849 Reviewed-by: David Schulz <david.schulz@digia.com>
* Add more qtbase implictly-shared classes to the listGiuseppe D'Angelo2012-11-301-0/+1
| | | | | | | QText*Format and QDns* ones are still missing. Change-Id: I8e87fba596e87289ca935717e0a90bfc0b0a26c0 Reviewed-by: hjk <qthjk@ovi.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-2216-385/+385
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Fix network doc links.Frederik Gladhorn2012-09-211-1/+1
| | | | | | | | Change-Id: I319644da80d91c5cf6d247410f022fbfd062a1f3 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org> Reviewed-by: Martin Smith <martin.smith@digia.com> Reviewed-by: Peter Hartmann <phartmann@rim.com>
* network: Fix missing or improper include guard in headersSergio Ahumada2012-09-153-7/+7
| | | | | | | | | | Use an include guard in headers to ensure the header is not included more than once. Make the header guard match its file name. Also, cpp files should include their own headers first (but below config.h) Change-Id: Iecf5da23c0f8e6d457f67657b88ef7557bde9669 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QtNetwork: declare some classes as sharedMarc Mutz2012-08-231-0/+2
| | | | | Change-Id: Ib3eaba59836529ad0cf8e4353b54dd0cd31fd1ad Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* QtNetwork: use nullary version of qRegisterMetaType<T>("T")Marc Mutz2012-07-253-2/+7
| | | | | | | | | | | | | | | | | Using the nullary version has the advantage that multiple calls during a program run are much more efficient, since an inlined atomic is used to store the result. It also ensures that Q_DECLARE_METATYPE(T) has been used, whereas qRegisterMetaType<T>("T") will happily register anything. So I've added the macro where it was missing, or moved it to a central place when it existed hidden. In tst_qnetworkreply, this became a bit tricky, because a private header is conditionally included, so moved the Q_DECLARE_METATYPE() into a conditional section, too. Change-Id: I71484523e4277f4697b7d4b2ddc3505375162727 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Remove obsolete or commented use of Q_DECLARE_METATYPE.Stephen Kelly2012-07-241-2/+0
| | | | | Change-Id: I15bc845801b9f84a9252a0092fbd69f0e1b3f4ea Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Avoid loading multiple bearer plugins of the same keyJiang Jiang2012-07-111-0/+5
| | | | | | | | There may be duplicated debug plugins, loading both will cause crash. Change-Id: Icc2a3643c318844bc7f2e149a6434e95de2449b2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QtNetwork: add member-swap to shared classesMarc Mutz2012-07-062-0/+10
| | | | | | | | Implemented as in other shared classes (e.g. QPen). Change-Id: Ib3d87ff99603e617cc8810489f9f5e9fe054cd2a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Remove QFactoryInterface from bearer pluginsLars Knoll2012-06-081-10/+1
| | | | | Change-Id: I8d6736e56f34f49041fff409d040634475eb0bf5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge branch 'docs-refactoring' into masterMarius Storm-Olsen2012-05-101-1/+1
|\ | | | | | | Change-Id: Iebd1966abace3cdf7f9428dcfc1ded5b124ab113
| * Doc: Modularize QtNetwork documentation.Casper van Donderen2012-05-091-1/+1
| | | | | | | | | | | | | | This change moves the snippets and imagesto the modularized directories. Change-Id: If14912692a7f72d7de345eaf88d9ec9752310fca Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
* | No longer use deprecated methods for plugin loading.Friedemann Kleint2012-05-091-8/+9
| | | | | | | | | | Change-Id: I19c66b1c41ea4dd236726c86d7d071b210ec9244 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* | Connect bearer engines to manager with QueuedConnectionShane Kearns2012-05-091-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is to avoid a deadlock that happens when a user thread is accessing the QNetworkConfigurationManager at the same time the plugin emits a signal. i.e. plugin is holding engine lock user thread is holding manager lock and blocked trying to acquire the engine lock In the manager slot, it tries to acquire the manager lock. By using queued connection, there are no locks held at the time the manager slot is called. Change-Id: I95f28028b5e77f77b2b9b7e31cbd1b78a8fe3097 Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
* | The \enum should use the enum name not the flags.Richard Moore2012-05-081-1/+1
|/ | | | | | | Fixes a qdoc warning. Change-Id: Ia8cbad00902a27c24e14910cdc3a87a66839716b Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Document new APIs in 5.0Shane Kearns2012-05-031-0/+2
| | | | | | | | The \since 5.0 directive was missing from many places. Task-number: QTBUG-24001 Change-Id: I191ba8891ae66d78f923164bcab2fccb16eabef9 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Port QNetworkSession to QMetaMethod-based connectNotify()Kent Hansen2012-05-012-6/+11
| | | | | | | | The const char *-based API is deprecated and will be removed in Qt5. Change-Id: I36f6dc761e3b5a087e38db29b761c3e9237958b4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Define usagePolicies API in QNetworkSessionShane Kearns2012-04-113-1/+57
| | | | | | | | | | | | | This allows the system to publish usage restrictions to applications related to the network in use. Currently there is only one restriction defined: NoBackgroundTrafficPolicy, which means that non user initiated traffic should be avoided (e.g. background downloads). For example this policy could be applied to save battery or data transfer charges. Change-Id: I49e26c0f3650d2b92f4ec51981aae9435b717b49 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove the usage of deprecated qdoc macros.Casper van Donderen2012-03-022-30/+30
| | | | | | | | | | | QDoc now has support for Doxygen style commands for italics, bold and list items. This change applies that change in QDoc to the actual documentation. Task-number: QTBUG-24578 Change-Id: I519bf9c29b14092e3ab6067612f42bf749eeedf5 Reviewed-by: Shane Kearns <shane.kearns@accenture.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Name threads properlymae2012-03-021-0/+2
| | | | | | | | When there is no QObject subclass with Q_OBJECT macro, we must at least set an object name Change-Id: Ib429a9b246d9d6b4b4cfb11593e4f358850677f2 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Use QBasicMutex instead of Q_GLOBAL_STATIC QMutexOlivier Goffart2012-02-011-2/+2
| | | | | | | | | | | | | | QBasicMutex is a POD and can be used as a static global object. in qpicture.cpp factoryLoader is used only once, and under the mutex, so there is no need for Q_GLOBAL_STATIC for it, it can be a function static in qhostinfo_unix.cpp the code seemed wrong while compiled with namespace and QT_NO_GETADDRINFO. I also could get rid of one include because it was included earlier. Change-Id: I3c700203c3e067266c20733f4bda8031446dbb86 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-3016-16/+16
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* bearer: run the bearer engines in their own worker threadShane Kearns2012-01-253-18/+30
| | | | | | | | | | | | | | | | | | | | | | | | The original architecture of the QtNetwork bearer support hosted the engines in the application's main thread, but this causes some problems. If the QNetworkConfigurationManager is constructed in a worker thread, then it is populated asynchronously without any notification when it is done (the app gets incomplete or missing results) Fixing that by restoring the earlier behaviour of using blocking queued connections to wait for the lists to be populated caused a regression, as some applications deadlock because the main thread is waiting on the worker thread at this time. By introducing a dedicated worker thread for the bearer engines, QNetworkConfigurationManager can be safely constructed in any thread while using blocking queued connections internally. Task-number: QTBUG-18795 Change-Id: Iaa1706d44b02b42057c100b0b399364175af2ddb Reviewed-by: mread (cherry picked from commit 5f879c55e531165cc2569b03c3796d0f33d0a0b7) Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Murray Read <ext-murray.2.read@nokia.com> Reviewed-by: Alex <alex.blasche@nokia.com>
* Remove use of QT_MODULE from libraryGunnar Sletta2012-01-254-4/+0
| | | | | | | | | | These defines were there to aid in the commercial licensing scheme we used long ago, and are no longer needed. Keep a QT_MODULE(x) define so other modules continue compiling. Change-Id: I8fd76cd5270df8f14aee746b6cf32ebf7c23fec7 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove reference to Symbian in QtNetwork.Xizhi Zhu2012-01-241-2/+0
| | | | | | | Change-Id: Iae377505e36ae1239be7ce52c773dc2a4f4a9767 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-2316-16/+16
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Remove the useless connManager() function.Xizhi Zhu2012-01-191-13/+8
| | | | | | Change-Id: Ifac0796ec22d0656ccfcf31b8d45b2342c2ee646 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: hjk <qthjk@ovi.com>
* Rename all our interfaces from com.trolltech to org.qt-projectLars Knoll2012-01-191-1/+1
| | | | | | Change-Id: I6db7211fcf6b24bd75e360645bbb2fdf1ef8a8bc Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Fix compiler warnings in Qt Network.Friedemann Kleint2012-01-191-2/+3
| | | | | | | | - Missing return value - Wrong format for qint64 Change-Id: Id0de58c85b7c8ed2a62f7237fd23e6c5a5ac92ec Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
* Remove QNetworkConfigurationPrivate::bearerTypeName().Xizhi Zhu2012-01-192-16/+9
| | | | | | | | | Also, use QStringLiteral instead of QLatin1String. Change-Id: I232fc02a56261929864c2ea66993ef1c74bc1237 Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
* Remove the useless undef for "interface".Xizhi Zhu2012-01-191-4/+0
| | | | | | | | "interface" is not used by QNetworkConfiguration. Change-Id: I742fe179d415ab1424bfddb1f6c034fc98c55e61 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>