summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* CMake: Workaround building DBus 'car' example with qmakeAlexandru Croitor2020-08-232-4/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While trying to implement instructions for building examples with qmake in the CI, an issue has surfaced. When building examples with CMake with -DBUILD_EXAMPLES=ON in the CI, the examples are built in-source, aka source dir == build dir. This means that the header files generated by qdbusxml2cpp will be placed in the qtbase source dir. The instructions that try to build examples with qmake build the examples in a separate build dir after building the examples with CMake. Unfortunately the qtbase/examples/dbus/remotecontrolledcar/car example includes the generated DBus adaptor header via a statement like #include "car_adaptor.h" and the compiler prefers to pick up the header file from the example source dir (the one generated by CMake), rather than the one generated by qmake in the example build dir. Because CMake's DBus integration uses different flags than qmake's DBus integration, the generated header file code is not compatible with the qmake generated cpp file, and the example fails to link when building with qmake, because it can't find an appropriate constructor symbol. In an ideal world, we wouldn't do in-source builds with the CMake build, but that leads to other issues which I currently don't recall. To circumvent the issue, adapt the CMake DBus qt6_add_dbus_adaptor function to allow not passing the problematic '-l' flag by making it optional. This shouldn't break existing code, but allows us to generate a compatible header that will be used by qmake and succeed in linking the example. Task-number: QTBUG-85986 Change-Id: I06759f79aeb66bb32da7f158f55dd4734c4a9887 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* QStringTokenizer: use sliced() instead of mid()Marc Mutz2020-08-231-2/+2
| | | | | | | | The code was developed against the narrow-contract version of mid(), but not updated when mid() became wide-contract. Change-Id: I038054fb3f5acc0085c48fbf36af13dd14c917b8 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Port QLatin1String to qsizetype and add narrow-contract substring functionsMarc Mutz2020-08-233-67/+147
| | | | | | | | | | | | | | | | | | | | | | QLatin1String::mid() etc were changed from narrow to wide contract, but the narrow-contract replacements weren't added. This blocks using the narrow-contract functions in QStringTokenizer. As a drive-by, Q_REQUIRED_RESULT -> [[nodiscard]] and Q_DECL_CONSTEXPR -> constexpr. Also centralize most Q_ASSERT()s in a single function, verify(), in an attempt to reduce the amount of string data generated from the asserts in assertive builds. [ChangeLog][QtCore][QLatin1String] Added from(), sliced(), first(n), last(n) functions. [ChangeLog][QtCore][QLatin1String] size_type/size() is now qsizetype (was: int). This makes QLatin1String(ptr, 0) ambiguous now between the (ptr, ptr) and (ptr, qsizetype) constructors. Change-Id: Ie195f66ae1974eb0752c058aa9f3b0853ed92477 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Drop spurious const from parameterEdward Welbourne2020-08-231-1/+1
| | | | | | | | Quanifying a parameter passed by value (which is correct for QTime, there is no need to pass it by reference) as const is pointless. Change-Id: I86850f65dfac28ffcc4a8633dd6d212259bb33d0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix crash on serializing default-constructed QTimeZoneEdward Welbourne2020-08-231-3/+11
| | | | | | | | | | | | | | The serialization code neglected to check against null. Sinze zones are saved either by IANA ID or in our special OffsetFromUtc format, representing an invalid zone by a string that cannot possibly be a valid IANA ID will do. Fixes: QTBUG-86019 Pick-to: 5.15 Pick-to: 5.12 Change-Id: I6882026403d00f8b254aab34c645f1cf8f9fcc2d Reviewed-by: Taylor Braun-Jones <taylor@braun-jones.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix mistake in AESHASH algorithmAllan Sandfeld Jensen2020-08-231-2/+2
| | | | | | | The read data wasn't encoded into the state correctly. Change-Id: Ib0a3b50bfeb56968de5c5e8353b28383cb586271 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Ignore clang-format for GUI snippetsPaul Wicking2020-08-231-0/+2
| | | | | | | | | | | | Among other things, this allows for ignoring proper indentation of code that's contained in a wrapper function which serves the purpose of compiling the snippet only. This is useful because the extra indentation is included in the output generated by QDoc. Task-number: QTBUG-84470 Change-Id: I3d702e82169a87447939f357cbee15cb0f74a391 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Fix CaseSensitivity handling for QRegularExpression in QSortFilterProxyModelMarcel Krems2020-08-231-1/+2
| | | | | | | | | | | setFilterRegExp retains the caseSensitivity() while setFilterRegularExpression did not. Change setFilterRegularExpression to also retain the case sensitivity. Fixes: QTBUG-83313 Pick-to: 5.15 Change-Id: I46f494d320aee99d50612f01f63558c693276989 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch> Reviewed-by: David Faure <david.faure@kdab.com>
* Fix truncation warning in qversionnumber.hMarcel Krems2020-08-231-1/+1
| | | | | | | qversionnumber.h(390): warning C4310: cast truncates constant value Change-Id: I26f525db84d1c3691d9ac3f91f67be0bc4034b41 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QVariant::metaType(): Add missing \since Qt 6.0Marcel Krems2020-08-231-0/+2
| | | | | | | Amends a68e4f3b96a82a93898f381e8ddc7f50f9c89d40 Change-Id: Ice8f83e11e03db1d76e12ffd2b548a6b69684842 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QSizePolicy: Fix warning about mixing different enumsMarcel Krems2020-08-231-2/+2
| | | | | | | | warning: C5054: operator '&': deprecated between enumerations of different types Pick-to: 5.15 Change-Id: I4e48a44f089d3eaca5d3f876da01335051192b28 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QPixelFormat: Fix warning about mixing different enumsMarcel Krems2020-08-231-14/+14
| | | | | | | | warning: C5054: operator '+': deprecated between enumerations of different types Pick-to: 5.15 Change-Id: If111b076914667fb149e62e051f52f408db9a338 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* xcb: remove QT_XCB_NO_XI2_MOUSE code pathGatis Paeglis2020-08-234-134/+13
| | | | | | | | | | | | | | | This code path was deprecated in 5.12 and scheduled for removal in Qt 6. See 9184384bc9d9d71a146fff535021357258a0295e. According to the source comments from f48170b479df359f47af12b03a501d9d0c386e66, apperantly XInput2 had some issues when running on Xinerama screens and therefore there was a check for it in xi2MouseEventsDisabled(). We plan to remove Xinerama support, therefore Xinerama handling in xi2MouseEventsDisabled() is irrelevant. Task-number: QTBUG-69412 Change-Id: I384d7c46337358caecccf644acc8ffbd381dc69d Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* qwsi: revert parts of 00ae1e6b7bf6efa5f5e57d37844e44d521604fb6Gatis Paeglis2020-08-233-26/+2
| | | | | | | | | | | | | | We actually do not need this "mode" in qwsi API. I think while writing the patch from 00ae1e6b7b I got confused by focusing on my test application. We can't know what the native event filter will filter out, therefore it makes sense that we unconditionally do filtering at qwsi level as well for user input vs other events in QWindowSystemInterface::sendWindowSystemEvents(). Pick-to: 5.15 Pick-to: 5.12 Change-Id: Idb23152a24bf3ba3b91804427a6e78f991969c29 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* QLayout: make its indexOf functions take pointer-to-constGiuseppe D'Angelo2020-08-232-5/+5
| | | | | | | | | | | | | | | | | | | | | Try to fix an API mistake there: there is no reason why these functions should take pointers to non-const widgets, as that actually preventing reasonable code (e.g. finding out the index of "this" inside a const method of a QWidget subclass). Unfortunately, indexOf(QWidget*) is also virtual, meaning that changing its signature is an API break. Hopefully, there are only few users that override this method (Woboq says 0). [ChangeLog][Potentially Source-Incompatible Changes] The QLayout::indexOf(QWidget *) virtual function has changed signature, becoming QLayout::indexOf(const QWidget *). This is source incompatible, although the fix (for the few users that do override indexOf() in their layouts) is straightforward. Change-Id: Id2183f5ecd9dc7e2a37c7355266e8494ef7929f2 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Interbase: Close the cursor before reopening it later onAndy Shaw2020-08-231-3/+3
| | | | | Change-Id: If21d33262b8ca53c17a7d236baaa828907116cab Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QFont: Extend the string description to include the missing elementsAndy Shaw2020-08-221-4/+17
| | | | | | | | | | This extends to/fromString to include style strategy, capitalization, letter and word spacing and stretch. QFont::fromString() keeps compatibility with strings from earlier versions as well. Fixes: QTBUG-67687 Change-Id: I5e95a58f1cd850214af2a7d8906a214facd4e661 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* xcb: Fix flushing of native subwindows when not using shared memoryTor Arne Vestbø2020-08-221-2/+11
| | | | | | | | | | | | | | | | | | | | | When using X-forwarding we're not using shared memory for the backing store image, and end up in a code path where we first copy the updated parts of the backing store from our client side image over to the server, and then flush those parts from the server-side image to the window. The problem was that this code path didn't account for the possibility that we'd flush a sub-window at an offset, and would end up uploading the sub-window local region directly, without applying the offset. This problem was revealed when 79bf1b7e348d started being smarter about what regions we flush and to what windows when we have sub windows. Fixes: QTBUG-81723 Pick-to: 5.15 Pick-to: 5.12 Change-Id: I1c9c8bc53c088cdc1ae8b892e17930f4a468ccad Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* Properly deprecate Qt::MidButton in favor of Qt::MiddleButtonEdward Welbourne2020-08-2216-33/+35
| | | | | | | | | | | | MidButton had its // ### Qt 5: remove me upgraded to Qt 6 at 5.0; but it dates back to 4.7.0 Replace the many remaining uses of MidButton with MiddleButton in the process. Pick-to: 5.15 Change-Id: Idc1b1b1816673dfdb344d703d101febc823a76ff Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QGuiApplication: fix handling of spontaneous events' modifiersNicolas Guichard2020-08-203-53/+58
| | | | | | | | | | | | | | | | | | | | | | | | | QtQuickTest synthetized events can have modifiers, but those modifiers were not accessible globally, from QGuiApplication::keyboardModifiers for instance. eg. calling QML's TestCase::mouseClick with modifiers triggering a call to QGuiApplication::keyboardModifiers did not give the expected result. QtTest synthesised events can also have modifiers and those were correctly handled by QApplication to set modifiers globally. This fix moves the handling code from QApplication::notify to QGuiApplicationPrivate::maybeSimulateModifiers and calls this function from QGuiApplication::notify too. The definite fix would be to do as suggested in the comment attached to the moved code: > Qt Test should not call qapp->notify(), but rather route the events > through the proper QPA interface. This is required to properly > generate all other events such as enter/leave etc. Pick-to: 5.15 5.12 Change-Id: I734e5bbc82232b13828b1a1f82e06ee8eb695417 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Resolve the remaining open ### Qt6 comments of QJsonValueSona Kurazyan2020-08-204-108/+63
| | | | | | | | | Changed QJsonValue to use QCborValue for data storage. Removed unused internal methods. Task-number: QTBUG-85700 Change-Id: I784fc7c0c4407f79eb7ca87a1f5116f00c26155d Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QIODevice: implement a "zero-copy" strategy for buffered writesAlex Trotsenko2020-08-207-8/+38
| | | | | | | | | | | | | | | | | | | | | | | | It works as follows: - user calls write(const QByteArray &); - this function keeps a pointer to the chunk and calls a regular write(data, len); - write(data, len) calls a virtual writeData(); - subclass calls a new QIODevicePrivate::write(); - QIODevicePrivate::write() makes a shallow copy of the byte array. Proposed solution is fully compatible with existing subclasses. By replacing a call to d->writeBuffer.append() with d->write(), subclasses can improve their performance. Bump the TypeInformationVersion field in qtHookData, to notify the Qt Creator developers that the offset of QFilePrivate::fileName was changed and dumpers should be adapted. Change-Id: I24713386cc74a9f37e5223c617e4b1ba97f968dc Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Tidy up qnamespace.qdoc's enums' \omitvalue entriesEdward Welbourne2020-08-201-39/+36
| | | | | | | | | Moved \omitvalue entries to the end (unless there was only one, at the start). Sorted Qt::WidgetAttribute's to match their order in the declaration, as there were many and their order was haphazard. Change-Id: I41d27df0fc293f642f931177b0d8884fbbcb9b77 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QCalendarBackend: format "enum" as code where usedEdward Welbourne2020-08-201-8/+11
| | | | | | | | Also mark some internal methods as \internal. Pick-to: 5.15 Change-Id: I0ae8dc315e5012eea2f3c35ae7d09c3cbb318ab5 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Document QCalendarBackend::name()Edward Welbourne2020-08-201-1/+8
| | | | | | | | Neglected previously. Pick-to: 5.15 Change-Id: I0acd9f77d1623a1fcd8766f734c350316401b3a9 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Mention no_testcase_installs which can be used to prevent installAndy Shaw2020-08-202-0/+9
| | | | | | | Change-Id: If8044a339cab754d427fd7626dd6813c7cc99e56 Pick-to: 5.15 5.12 Fixes: QTBUG-85827 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Turn comments about passing QDate, QTime by value into docsEdward Welbourne2020-08-202-8/+10
| | | | | | | | | | This is already changed throughout qtbase, aside from template specializations where passing by reference is required by the template. Revise QDate and QTime documentation to say they are best passed by value. Change-Id: I0b05f42b273bf1fd4c412247a9372113b7e40561 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix a number of qdoc warningsFriedemann Kleint2020-08-2022-257/+25
| | | | | | | | | | | - Remove obsolete functions and enumeration values - Remove QObject * parameter from QMetaProperty accessors - Fix renamed enumerations in QSsl - Fix list items to be \li - Fix function signatures and variable names Change-Id: I37c7e6bf2c8ff92bc7b82620bae0a27796f866ab Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Fix deprecation warnings in QtSql code snippetsFriedemann Kleint2020-08-201-2/+2
| | | | | | | | Use QMetaType for constructing a QSqlField, fixing: ccode/sqldatabase/sqldatabase.cpp:91:41: warning: ‘QSqlField::QSqlField(const QString&, QVariant::Type)’ is deprecated: Use the constructor using a QMetaType instead [-Wdeprecated-declarations] Change-Id: If420ad3d7f5d9dce05ad892cddf84a1b77a45b3f Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Fix qHash(const QModelIndex &index)Friedemann Kleint2020-08-201-1/+1
| | | | | | | | | The default seed = 0 parameter was missing, so, it was never used. Manifested as a failing test in Qt for Python (bug_PYSIDE-41.py). Amends c6cdf38e752c22babdbe645366bdfb7ce51d01ff. Change-Id: Ia3db8b6123a695d839fbec419b8d316991d18bf7 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* xdgdesktopportal: Avoid dangling pointerMichael Weghorn2020-08-201-2/+2
| | | | | | | | | | | | | | | | Use pointer to newly inserted element in 'filterList' since local variable 'filter' goes out of scope at the end of the block. This is a follow-up for commit 3e09c28101d1af1dd90a4b515d7edbe5a3737f97 ("Filechooser portal: Implement "current_filter"). Thanks to Giuseppe D'Angelo for pointing this out in that commit's Gerrit change. Pick-to: 5.15 Change-Id: I9af35c46315c7f90721d0d39b0fda6384c15786a Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Remove QSslSocket::abort()Alex Trotsenko2020-08-203-39/+11
| | | | | | | | | | | | | | | | QAbstractSocket::abort() is not a virtual function and QSslSocket::abort() does not override it. Having two alternatives requires a dynamic typecasting and violates the principles of object- oriented programming. Due to the BC, we were unable to fix that in Qt5. Now, we can modify QSslSocket::close() to handle QAbstractSocket::abort() requests and remove the duplicate. Change-Id: I49d6f32a571ae6e35b08cb366816f917e580dae8 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Doc: Use https in links that don't redirect properlyPaul Wicking2020-08-201-2/+2
| | | | | Change-Id: If9f28851e8df6ed488590d06db8c0791214c4a95 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: Improve thread safety docsPaul Wicking2020-08-201-1/+15
| | | | | | | | | | | | * Add missing \threadsafe command. * Add missing note for methods callable only from the started thread. * Expand note on excerting care when interacting with objects across threads in QThread's class overview documentation. Fixes: QTBUG-86112 Pick-to: 5.15 Change-Id: I8f181d92ad6196ff0c13f5a866a36793209a75ab Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Move QStringRef and remains to Qt5CompatKarsten Heimrich2020-08-2017-2303/+45
| | | | | | | | | Export some private functions from QUtf8 to resolve undefined symbols in Qt5Compat after moving QStringRef. Task-number: QTBUG-84437 Change-Id: I9046dcb14ed520d8868a511d79da6e721e26f72b Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QSslContext - do a little cleanup (OpenSSL)Timur Pocheptsov2020-08-193-11/+11
| | | | | | | | | | | | | | | 1. Remove a useless forward declaration of a non-existing class. 2. Simplify the cipher filtering. 3. A missing private key (when local cert is present) found by the Qt, not OpenSSL, so no need in asking OpenSSL for errors in queue. 3. Fix a potential double-free (for opaque keys). 4. read/write BIOs normally owned by SSL object, but if we fail to allocate any of them, we return early, potentially failing to free the one that was allocated. Change-Id: Ifb52fbc9fd1a38f101bd7ff02e79b82d6eb7e5b0 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* QFileSystemModel: don't display a modal messagebox on errorVolker Hilsheimer2020-08-191-23/+2
| | | | | | | | | | | A model is the wrong place to display a modal dialog when a call to setData failed. The call returns false already, and the caller can handle the error appropriately, presumably knowing best what failed and how to present the user with options. Task-number: QTBUG-66177 Change-Id: I069209d51a577177bc278aeb08a92c95029dc962 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Clean up itemviews after QStyleOption version cleanupVolker Hilsheimer2020-08-197-28/+22
| | | | | | Change-Id: I56cb1cfd9977dedd89947dfe2bf9edb70297e31f Task-number: QTBUG-84221 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
* QMenu: make less sensitive to mouse jitterVolker Hilsheimer2020-08-191-1/+1
| | | | | | | | | | | | | | On systems where a right-press brings up the menu, the next mouse move will select an action, even if it's just a move by a single pixel. This makes it too easy to activate an action on e.g a context menu accidentially when the button is released. Ignore the first couple of mouse moves, using the same logic that prevents accidental tearing off. Change-Id: Ib4dd448ef2d6ae915b48da62666aa95b37145d63 Fixes: QTBUG-57849 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Port QXmlStreamReader from QStringRef to QStringViewKarsten Heimrich2020-08-196-137/+165
| | | | | | | | | | | Use the new QtPrivate::XmlString class as the container holding the string data internally. It basically a "QStringRef lite", purely used in the implemntation. This replaces all usages of QStringRef in the parser. Fixes: QTBUG-84318 Change-Id: I557bbc6831301866602586d11d53283affd034a8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix QXmlStreamSimpleStack to work also with non POD data typesLars Knoll2020-08-193-14/+24
| | | | | | | | | | The current code is already undefined behavior, as QStringRef is not POD. It happened to work, because the destructor is empty. Fix this and rather let the compiler determine whether it needs to call any constructors or destructors. Change-Id: Idc8710df539603b0ca401a9453f2501f01beaab4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Refactor QXmlStreamStringRefKarsten Heimrich2020-08-194-59/+67
| | | | | | | | | | | | | Use a QStringPrivate inside the implementation. This saves two pointers, and actually makes this a safe replacement for QStringRef inside the implementation of QXmlStreamReader. Unexport the class as all members are inline, and move it into the QtPrivate namespace as class QXmlString. Change-Id: I43fa4684f569514c8c621838dcc346657ac1a915 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* Smaller change towards using QStringViewLars Knoll2020-08-192-4/+4
| | | | | | Change-Id: I6e74a83303e2d9dd278b47aaf488e717eca3fc6d Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Refactor qxmlstream_p.hLars Knoll2020-08-1912-1936/+1818
| | | | | | | | | | Pull the file apart, so that the parts generated from qxmlstream.g are separated from the definition of the private class. This will in the future simplify maintenance and refactoring. Change-Id: I4a9c1bb1e377dee1e6d3b9aa9b0dfa64c5806c45 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Cleanup QXmlStreamStringRefKarsten Heimrich2020-08-191-7/+1
| | | | | | | | Remove unused methods and prepare for changing the implementation so we can get rid of all QStringRef usages in the stream reader. Change-Id: I5964352cad781faf791e360553636076b5818c6d Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Port the QXmlStream API from QStringRef to QStringViewKarsten Heimrich2020-08-198-125/+113
| | | | | | | | | | | | | | This gives some source incompatibilities, most of them can be handled by using auto instead of QStringRef explicitly. [ChangeLog][Important API changes] QXmlStream now uses QStringView insteead of QStringRef in it's API. Using auto forvariables returning a QStringRef in Qt 5 should lead to code that can be used against both Qt versions. Fixes: QTBUG-84317 Change-Id: I6df3a9507276f5d16d044a6bdbe0e4810cf99440 Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* QMetaType: specialize typenameHelper for std::pairFabian Kosmale2020-08-191-27/+68
| | | | | | | | | | | | The string representation of std::pair<T1,T2> is now always "std::pair<T1,T2>". This is in line with how we translate QPair, avoiding typename mismatches that would previoulsy occur, because the full name of pair on libc++ was "std::__1::pair". Fixes: QTBUG-84924 Change-Id: Ia6c044a7327d69e4b4f4a31496c6b2408d85ebb9 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove binary compat sources for qbytearray and qstringAllan Sandfeld Jensen2020-08-197-142/+2
| | | | | | | No longer needed in Qt6. Change-Id: I29567e175e07cc3658f0619acfd604abf64f6459 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make QAbstractSocket::abort() behavior unambiguousAlex Trotsenko2020-08-191-2/+0
| | | | | | | | | | | | | | | | After calling this function, the user expects that the connection is terminated, I/O device is closed and the socket is ready for a new attempt. But, if the socket was disconnected before the call, close() is not called and I/O device remains opened. Because QAbstractSocket::close() and QIODevice::close() can handle reentering, we can call close() unconditionally, which makes the behavior obvious. Change-Id: I90a9cbb1a1fe8f866b55ef0bd68d286b34e853f5 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* CMake Build: Fix libdrm detection and compilation on QNXCristian Adam2020-08-192-0/+14
| | | | | | | | | | | | On QNX 7.1 x86drm.h is located under <...>/usr/include/libdrm, unlike linux where it's present under /usr/include. find_path would not find it on QNX, and instead get /usr/include from host, which resulted in a failure to compile. Task-number: QTBUG-83202 Change-Id: I03d6c2d4dfbe91bb70df0a322e84890bd7c8548a Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>