summaryrefslogtreecommitdiffstats
path: root/src/network
Commit message (Collapse)AuthorAgeFilesLines
...
| * QFtp: Use UTF-8 encoding.Friedemann Kleint2016-04-071-5/+5
| | | | | | | | | | | | | | | | | | | | According to RFC 2640, FTP uses UTF-8 encoding. Fix the conversions accordingly. Task-number: QTBUG-52303 Change-Id: I615199b3d074fc3861f25df113dda672525766b6 Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com> Reviewed-by: Richard J. Moore <rich@kde.org>
| * Remove superfluous includes from qlocalsocket_win.cppJoerg Bornemann2016-04-061-4/+0
| | | | | | | | | | Change-Id: I4f641966af3443d0c487df95d2e565182a945bf3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | QSslSocket (Mac): optimize string usageAnton Kudryavtsev2016-04-041-10/+10
| | | | | | | | | | | | | | | | | | | | | | Wrap C-string in QL1S to prevent memory allocation. Replace startsWith() with comparing to first element of (existing) splitting result. Change-Id: Id47a0c350e4027abecd1394c1ee5dec8f346af00 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com>
* | QtNetwork: Remove documentation references to QUdpDatagram.Friedemann Kleint2016-04-012-3/+3
| | | | | | | | | | | | | | | | | | | | Fixes documentation warnings: qtbase/src/network/kernel/qnetworkinterface.cpp:528: warning: Can't link to 'QUdpDatagram::interfaceIndex()' qtbase/src/network/kernel/qnetworkinterface.cpp:587: warning: Can't link to 'QUdpDatagram::interfaceIndex()' Change-Id: I6579f7880b5e183b9c68dfe08fa7671f1511fdfa Reviewed-by: Alex Trotsenko <alex1973tr@gmail.com> Reviewed-by: Richard J. Moore <rich@kde.org>
* | QtNetwork: use QStringRef to optimize memory allocationAnton Kudryavtsev2016-03-314-16/+16
| | | | | | | | | | | | | | | | | | | | | | Replace substring functions that return QString with corresponding functions that return QStringRef where it's possible. Create QString from QStringRef only where necessary. Change-Id: I697f776c60003629990cfd197534ffed63bafe2f Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | Adjust include file for native sockets on INTEGRITY.Rolland Dudemaine2016-03-311-0/+3
| | | | | | | | | | Change-Id: Ibe957eb510fd46d828acedd3e66fa0b49c9a42f0 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | Remove the traces of the discontinued android-no-sdk platformEirik Aavitsland2016-03-303-4/+2
| | | | | | | | | | | | | | | | | | Cleaning out the workarounds for the discontinued "Embedded Android" platform of Boot2Qt. Change-Id: I0ff9d770e82a43457fb7e5da0428f4597ead4038 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | Unify license header usage.Jani Heikkinen2016-03-2925-85/+285
| | | | | | | | | | | | | | | | | | Update files using old header.LGPL3 to header.LGPL Update files using old FDL template to use new one Update files using old BSD template to use new one Change-Id: I36a78272516f9953d02956522f285b40adfc8915 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Simon Hausmann2016-03-244-15/+42
|\| | | | | | | Change-Id: I13c7ea6a74eb98606cf45702ae068101943bec6a
| * Add a write buffer to QLocalSocket/WinJoerg Bornemann2016-03-243-14/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 0307c008 removed the buffering of data-to-be-written from QWindowsPipeWriter, because it was assumed that users of this class (QProcess and QLocalSocket) already buffer data internally. This assumption was wrong for QLocalSocket. The following sequence localSocket->write(someData); localSocket->write(someMoreData); would not write anything on the second write. Add a write buffer to the Windows implementation of QLocalSocket. Task-number: QTBUG-52073 Change-Id: I6d0f03a722ec48138cbde3e2f69aae7dafe790d3 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
| * Fix typo in QLocalServer documentationSimon Hausmann2016-03-241-1/+1
| | | | | | | | | | Change-Id: Iceababb1e137c2363ee8a75476ecb4f5dba53b28 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | Merge "Merge remote-tracking branch 'origin/5.6' into 5.7" into refs/staging/5.7Liang Qi2016-03-218-70/+85
|\ \
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-218-70/+85
| |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/styles/qgtkstyle_p.cpp tests/auto/corelib/io/qtextstream/test/test.pro tests/auto/corelib/plugin/plugin.pro Change-Id: I512bc1b36acf3933ed2b96c00f476ee3819c1f4b
| | * Make QWindowsPipeWriter thread-free.Joerg Bornemann2016-03-171-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Re-work QWindowsPipeWriter to not use a thread anymore but the WriteFileEx API, similar to QWindowsPipeReader. This saves us a lot of thread synchronization code and enables us to directly write data without yet another buffering layer. Also, this fixes the dreaded deadlocks in the QWindowsPipeWriter destructor that could occur when the reading end was closed before the write was finished. Task-number: QTBUG-23378 Task-number: QTBUG-38185 Change-Id: If0ae96dcd756f716ddf6fa38016080095bf3bd4e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
| | * Don't include by default ciphers that are not supportedAntonio Larrosa2016-03-141-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There could be cases (mostly when compiled on old systems, since modern openssl versions don't include such insecure ciphers) in which defaultCiphers included a cipher that wasn't in the supported ciphers list. With this patch we make sure that defaultCiphers is a subset of supportedCiphers Change-Id: I545ea21f5fd3a6ed13b366cdd56a1393233f9fc9 Reviewed-by: Richard J. Moore <rich@kde.org>
| | * Do not send the trailing dot of a hostname as part of the SNIRichard J. Moore2016-03-131-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | The SNI extension must not include the trailing dot, even though this is legitimate for the host header. Task-number: QTBUG-51821 Change-Id: Ib7a7d8b1f8f98bc99ae745b03d2b97e507adefaf Reviewed-by: Daniel Molkentin (ownCloud) <danimo@owncloud.com>
| | * QNetworkHeaders: fix UB (invalid enum value) in Private::parseAndSetHeader()Marc Mutz2016-03-121-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Found by UBSan: qnetworkrequest.cpp:1016:19: runtime error: load of value 4294967295, which is not a valid value for type 'KnownHeaders' KnownHeaders does not contain a failure state, and no negative values. -1 is therefore not a valid value for an object of type KnownHeaders, so loading one is considered UB. Fix by returning the result of parseHeaderName() as an int, only casting to KnownHeaders after checking for the failure case. Change-Id: I6b165fe2b15c747344a9b2750bb753582c5bcbeb Reviewed-by: Richard J. Moore <rich@kde.org>
| | * QLocalServer/Win: Fix race condition in listen().Joerg Bornemann2016-03-101-30/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Suppose a client connects while the QLocalServer is still in the loop that calls addListener. The connection would SetEvent(eventHandle), but every call to ConnectNamedPipe would ResetEvent(eventHandle). Thus, the connection is never detected by the notifier on eventHandle. Callers of addListener must check the connection state of every listener to make sure that no client connected while setting up listeners. Task-number: QTBUG-49254 Change-Id: Ia961927ea76973708e6e3f73510695eb5d6a0e4c Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
| | * Deduplicate a condition to make clear that several cases ask it.Edward Welbourne2016-03-101-27/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QNetworkAccessManager::createRequest() had three checks relevant only to GET and HEAD requests; rather than testing for this in each of the cases, test for it once and skip all three if it fails. Tidied up the residue of conditionals in the process. Change-Id: I7baee8067a03afdc7cb0a77f1a50759dc4233843 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * Skip spurious .toLower() on returns of QUrl::scheme()Edward Welbourne2016-03-104-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | QUrl::setScheme() parses and canonicalises the scheme, so that scheme() always returns a lower-case string anyway; no need to .toLower() it. Change-Id: Ied00814b63f159386a42552dcf06346ee56f9f97 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
* | | Remove dynamically-loaded use of DNS lookup feature for INTEGRITY.Rolland Dudemaine2016-03-211-2/+4
|/ / | | | | | | | | | | | | | | | | Static libnet is enough for DNS resolution. This commit specializes the removal of dynamic DNS library load, but this should probably also be done when using a static build. Change-Id: I597bdd528649849844a0ee46d0706f22d6f595d4 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | QAbstractSocket: do not fail writing on read buffer overflowAlex Trotsenko2016-03-181-4/+5
| | | | | | | | | | | | | | | | | | | | | | canReadNotification() could return 'false' if either the socket has been closed, or the read buffer has reached the maximum size. Because of this duality, waitForBytesWritten() should not fail as a result of a canReadNotification() call. Change-Id: I9a15fa174a3b982a7ce404913caa38fc19f64622 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | Merge "Merge remote-tracking branch 'origin/5.6' into 5.7" into refs/staging/5.7Liang Qi2016-03-135-36/+24
|\ \
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-115-36/+24
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change partially reverts 1bfc7f68 about QT_HAS_BUILTIN define and undef in src/corelib/tools/qsimd_p.h. This change is also squashed with "Fall back to c++11 standard compiler flag for host builds" which is done by Peter Seiderer. Conflicts: mkspecs/features/default_post.prf src/3rdparty/sqlite/0001-Fixing-the-SQLite3-build-for-WEC2013-again.patch src/3rdparty/sqlite/sqlite3.c src/corelib/tools/qsimd_p.h src/gui/kernel/qevent.cpp src/gui/kernel/qwindowsysteminterface.cpp src/gui/kernel/qwindowsysteminterface_p.h src/plugins/bearer/blackberry/blackberry.pro src/plugins/platforms/cocoa/qcocoasystemsettings.mm src/plugins/platformthemes/gtk2/gtk2.pro src/plugins/styles/bb10style/bb10style.pro src/sql/drivers/sqlite2/qsql_sqlite2.cpp tools/configure/configureapp.cpp Task-number: QTBUG-51644 Done-with: Peter Seiderer <ps.report@gmx.net> Change-Id: I6100d6ace31b2e8d41a95f0b5d5ebf8f1fd88b44
| | * Accept LFCRLF to mark end of HTTP HeadersDyami Caliri2016-03-092-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some embedded servers use LF to mark the end of an individual header, but use CRLF to mark the end of all the headers. The GoPro WiFi interface does this, as an example. Change-Id: I227ab73622c84f439a6cf8703d020393c4d8bf69 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
| | * Use booleans as booleans; don't compare == true to do so !Edward Welbourne2016-03-081-3/+3
| | | | | | | | | | | | | | | Change-Id: Ic900bf000cec52b3ebf0fd0fc61f42252f3200e6 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * Purge a verbose no-op.Edward Welbourne2016-03-081-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | An if with no side-effects in its test and an empty body is a no-op. An else block with nothing but a no-op in it is a no-op. A no-op without even pedagogic value is just a distraction. Change-Id: I224831a325e6b770d0a99d726d96f73da4b8c11f Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * Simplified repeated #if-ery and entangled conditionals.Edward Welbourne2016-03-081-9/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Three checks of the same #if managed to save repetition of (if I felt charitable) three shared lines, compared to combining the three into one, which leaves the code easier to read (and obviates the need for one of the "shared" lines). Split a long line while moving it. Change-Id: I762d10ae1df1224c749206b8eb490bafd7ea4900 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * Duplicate trivial code for clarity on early return.Edward Welbourne2016-03-081-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Having a variable in which to store a function's return in two branches of a switch in order to return if either was true saved little relative to just testing the function in each case and returning in situ, which reads more clearly. Change-Id: Ibd95a95721eaa6fc4861b10e723038b96caf269a Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * consistently put {qt,qml}_{module,plugin} at the end of project filesOswald Buddenhagen2016-03-071-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | this fixes static builds by ensuring that all dependencies are exported. Task-number: QTBUG-51071 Change-Id: Icbce502dcbcb4d4b4d922c42679f44e2cc930bf3 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| | * QAbstractSocket: fix a possible crash in waitForReadyRead()Alex Trotsenko2016-03-021-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | waitForConnected() could return 'true' even when the socket was disconnected. Change-Id: I99d9c9730f4e9b6c8a54696eb92c24c3ef36d261 Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | QHostInfo: optimize container usageAnton Kudryavtsev2016-03-131-24/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace Java-style iterators with STL-style iterators. Java-style iterators have overhead. Use std::stable_partition with erase() instead of using remove() in a loop, with quadratic complexity. Introduce local template homebrew any_of (analog of std::any_of from C++11) to simplify current code. Also it's needed for following changes in this class. Change-Id: I2b11889ccc7630597c72aa20cdb266ae6ca2471a Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | QHttpNetworkConnection: fix spelling in qWarning()Marc Mutz2016-03-121-1/+1
|/ / | | | | | | | | Change-Id: I87dcdc1b81e90d4bac180731fd78d0fea38191b6 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* | QtNetwork: use printf-style qWarning/qDebug where possible (I)Marc Mutz2016-03-047-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The printf-style version of QDebug expands to a lot less code than the std::ostream-style version. Of course, you pay in type safety (but compilers warn about it these days), you cannot stream complex Qt types and streaming QStrings is awkward, but in many cases you actually improve on readability. But the main reason is that something that's not supposed to be executed under normal operation has no business bloating executable code size. This is not an attempt at converting all qWarnings() to printf-style, only the low-hanging fruit. In this first part, replace qWarning() << "" with qWarning("..."). Saves ~850b in text size on optimized GCC 5.3 AMD64 builds. Change-Id: Ib1a087795a03b2a6b432e2c499968df779aaea37 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* | QHttpNetworkConnection: fix expensive iteration over QMultiMap::values()Marc Mutz2016-03-041-3/+2
| | | | | | | | | | | | | | | | Just iterate over the container instead, saving one iteration and the creation of a temporary QList. Change-Id: I564e3e83cb247a12c413fc5a9dc17299ae089e30 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | QtNetwork: optimize container usageAnton Kudryavtsev2016-03-037-43/+61
| | | | | | | | | | | | | | | | | | Don't perform lookup twice. Just cache iterator or position. Change-Id: I454fd292614dee62167ff248fc3ddec0f79435b0 Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | QBearerEngine: break out repeated loops as methods.Anton Kudryavtsev2016-03-031-45/+25
| | | | | | | | | | | | | | | | | | | | Three hashes are handled similarly; so extract the loops over them as methods hasUsedConfiguration() and cleanUpConfigurations() to avoid duplicate loop code. Change-Id: I1040724c4fc98caa48913fac339c03e60b04bae2 Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | QHostAddress: enable (N)RVO in toString() for gccAnton Kudryavtsev2016-03-031-10/+3
| | | | | | | | | | | | Change-Id: I5f8d72742cc4199bfa73df6037b851c58632ff86 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com>
* | QLocalServer, QLocalSocket: simpler use of startsWith()Anton Kudryavtsev2016-03-032-2/+2
| | | | | | | | | | | | | | | | | | It has a variant accepting QL1S directly, so no need to go via a QString. Change-Id: Ia8f1198ef2af7027bc9f7c2e1dad3a5f78a12eb4 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com>
* | QtNetwork: optimize if-else conditions.Anton Kudryavtsev2016-03-034-15/+14
| | | | | | | | | | | | | | | | De-duplicate calls by caching results. Reorder conditions: call cheap methods first. Change-Id: I27715b935247c6c21bd02f9cc40655d3f9371264 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | Integrate network sockets into the multichannel infrastructureAlex Trotsenko2016-03-0116-19/+123
| | | | | | | | | | | | | | Change-Id: I96974a7460c29b46cae8a28aadb3e50cdcdb7beb Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | Add We-mean-it comment to qnetworkdatagram_p.h.Friedemann Kleint2016-02-251-0/+11
| | | | | | | | | | | | | | | | Fix warning: WARNING: qtbase/src/network/kernel/qnetworkdatagram_p.h does not have the "We mean it." warning Change-Id: I65fc2dc9129b194b08865e3486fae4d0cad3f3d3 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | QtNetwork: don't use Boyer-Moore for single-character needlesMarc Mutz2016-02-242-11/+4
| | | | | | | | | | | | | | | | | | | | | | Using Boyer-Moore for single-character search strings makes no sense since there can be no skipping beyond the normal sequential search anyway. So, port to QByteArray::indexOf(char). Change-Id: I848e2ceea5ceafd0ebae402798b410f682348a75 Reviewed-by: Richard J. Moore <rich@kde.org>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-02-183-15/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also reverts commit 018e670a26ff5a61b949100ae080f5e654e7bee8. The change was introduced in 5.6. After the refactoring, 14960f52, in 5.7 branch and a merge, it is not needed any more. Conflicts: .qmake.conf src/corelib/io/qstandardpaths_mac.mm src/corelib/tools/qsharedpointer_impl.h tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp Change-Id: If4fdff0ebf2b9b5df9f9db93ea0022d5ee3da2a4
| * QtNetwork: Silence Clang on Windows.Friedemann Kleint2016-02-172-14/+1
| | | | | | | | | | | | | | | | | | Remove dead code and fix override. Task-number: QTBUG-50804 Change-Id: I9cc28507e549d56a1f15fcc54bb6f7465beef644 Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
| * Fix QT_DEPRECATED_SINCE usageJędrzej Nowacki2016-02-021-1/+1
| | | | | | | | | | | | | | | | The deprecation was introduced in 5.6 Change-Id: Ief6b749b40ec75c3c9f904caed8447bfb5ef5439 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | Merge "Merge dev into 5.7" into refs/staging/5.7Oswald Buddenhagen2016-02-173-19/+21
|\ \
| * | QHttpNetworkConnectionPrivate: de-duplicate calls in if-else chainsAnton Kudryavtsev2016-02-151-14/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... and loops. Every QNetworkConfiguration::bearerType() call produces lock/unlock of mutex. Fix: cache result. Every QHttpNetworkRequest::contentLength() call contains internal loop. Fix: cache result. Also cache results of QNonContiguousByteDevice::size() and QHostAddress::protocol(). Change-Id: I01124648b1972f480905433d9b3551c2246e1bde Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| * | Use QVector instead of QList for sizeof(T) > sizeof(void*)Sérgio Martins2016-02-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | caught with static analyzer which only warns for trivial cases: - Container must be local - Container isn't passed to any function, assigned to another container or assigned to. Change-Id: I3f3aa73c128a56f067fa8745990977445a495ac4 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| * | Use QFlags::setFlag where prudent in qtbaseAndre Somers2016-02-121-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QFlags::setFlag is most useful to replace explicit constructs like if (condition) { someFlags |= TheConditionFlag; } else { someFlags &= ~TheConditionFlag; } with someFlags.setFlag(TheConditionFlag, condition); Change-Id: Ie4586681c83e0af812d5bbf14965aad51941a960 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>