summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused qapplicationpermission.hJoerg Bornemann2021-10-224-82/+0
| | | | | | | | | The app permission API was removed, and this file is a left-over. This amends commit 72e5b36e2e4c79dc7995f0203968503266b4f2f5. Pick-to: 6.2 Change-Id: Ie1bf9465260594864464c4d4ee4dc99593c28cc1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QAbstractItemView: auto-scroll with selection rectangleVolker Hilsheimer2021-10-224-10/+137
| | | | | | | | | | | | | | | | | | | | | | | | | | | Some item views, such as QListView in icon mode, implement a selection rectangle with which the user can "lasso" items. So far, dragging that rectangle did not trigger auto scroll, so unless an item near the edge was selected, the user had to stop the lassoing and scroll manually to reach more items. Since QAbtractItemView implements auto scrolling for drag'n'drop, we can use that mechanism also when the selection rectangle is dragged. This requires some modifications: We need to make sure that scrolling the view during a drag-selection generates mouse move events so that the selection is extended and the rectangle is updated in subclasses. And we need to stop using QCursor::pos to get the position of the mouse pointer, as this makes the auto-scrolling untestable. Instead, record the mouse position last seen during a mouseMove or dragMoveEvent in content-coordinates (identical to pressedPosition). As a drive-by, fix some coding-style issues in nearby code. Done-with: Zhang Hao <zhanghao@uniontech.com> Fixes: QTBUG-96124 Change-Id: I426f786e5842ae9f9fb04e9d34dc6d3379a6207f Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Consistently restore threadpool limit at end of testsVolker Hilsheimer2021-10-221-12/+23
| | | | | | | | | | | Fix warning about unused variable, and use qScopeGuard to make sure that the limit of the global threadpool is restored even if one of the tests fail. Pick-to: 6.2 Change-Id: I36747cb451074cceea961561478210728ed6d313 Reviewed-by: Ievgenii Meshcheriakov <ievgenii.meshcheriakov@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QNI: Add a convenience method for loading the default pluginMårten Nordheim2021-10-228-18/+94
| | | | | | | | | We have some official plugins, we may as well treat them as default and give a convenient function which loads those. Change-Id: I6251c77ac042b795bcf24b86e510e960ee4bab54 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* QNI: Add supportedFeatures getterMårten Nordheim2021-10-224-2/+32
| | | | | | | Which just returns all the supported features Change-Id: I8c3996b00a6ebb114bdbc9db3085a0e27fc8fa79 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Doc: QString: formalize that we now include the QBA's nullsThiago Macieira2021-10-211-7/+36
| | | | | | | | | | | | | | We've been meaning to do this ever since the QByteArray overloads were added some time prior to Qt 4.5.1[1], but had been wary of behavior compatibility issues. Commit 6abdbb65e59779af56ae25372a853efca19eac59 did it and even explained so in the ChangeLog. I'm just being more explicit. [1] https://code.qt.io/cgit/qt/qt.git/tree/src/corelib/tools/qstring.h?h=v4.5.1#n415 Fixes: QTBUG-97451 Change-Id: Icb2516126f674e7b8bb3fffd16ad55e46a9781c8 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* QLatin1String: harmonize null byte handling with the rest of QStringThiago Macieira2021-10-221-3/+3
| | | | | | | | | | | | | | | | | | | | After the introduction of QByteArrayView, all the QString::fromXxx overloads and the constructor will include the null bytes inside QByteArrays and so will QLatin1Strings created from QByteArrayViews. This was the lone stand-out that wasn't fixed in 6.0, so do it now. [ChangeLog][Important Behavior Changes] Since Qt 6.0, all QString and QLatin1String methods consuming QByteArray and QByteArrayView objects will include any embedded null bytes and treat them as U+0000 Unicode characters, whereas in Qt 4.x and 5.x, they would stop at the first null byte like bare C strings. Qt 6.3 contains a fix for a couple of the methods that mistakenly persisted the old behavior in 6.0-6.2, namely the QLatin1String constructor from QByteArray and the equality and inequality operators between QByteArray and QString. Task-number: QTBUG-97451 Change-Id: Icb2516126f674e7b8bb3fffd16ad5621cf3e64ec Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* tst_QVariant: suppress warning about memcpying over QVariantThiago Macieira2021-10-211-1/+1
| | | | | | | tst_qvariant.cpp:3624:15: warning: ‘void* memcpy(void*, const void*, size_t)’ writing to an object of type ‘class QVariant’ with no trivial copy-assignment; use copy-assignment or copy-initialization instead [-Wclass-memaccess] Change-Id: Ic17a33f599b844d8ab5dfffd16aafcbd74823696 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Add QFontMetricsF methods taking text options into accountAllan Sandfeld Jensen2021-10-222-6/+201
| | | | | | | | | | This is needed by Qt Quick to be able to calculate font metrics using design metrics matching Quick text rendering. Task-number: QTBUG-85936 Task-number: QTBUG-94023 Change-Id: I67c74e2a912bd58df7a57349a858f20f04609f0f Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Avoid warnings when compiling bootstrap library without zstdUlf Hermann2021-10-211-0/+4
| | | | | Change-Id: Ic67cd2b582df0464a17f6181157ebbd47986114c Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Fix warnings due to enums in QSizePolicyFan RuiJie2021-10-211-2/+3
| | | | | | | | | | | | | | gcc 11 generates warnings as "bitwise operation between different enumeration types 'QSizePolicy::Policy' and 'QSizePolicy::PolicyFlag' is deprecated" in C++20. Fixes: QTBUG-93810 Pick-to: 6.2 5.15 Change-Id: If8a796b33a772cc1a561eb0b6bc4def8f9f54bc0 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Doc: Enable qdoc warning count limitVenugopal Shivashankar2021-10-218-0/+24
| | | | | | | | This should restrict changes that introduce new warnings. Change-Id: I7e4b5d9d5d84b7c336509c380bc7e6d86e360f4a Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Revert "CMake: Fix rpath-link dependencies when cross-compiling"Alexandru Croitor2021-10-211-10/+2
| | | | | | | | | | | | | This reverts commit 87215c70c0ff0bdc52dfa463f050d2aa049cdd91. Reason for revert: Breaks configuration of standalone tests in leaf modules Pick-to: 6.2 Fixes: QTBUG-97673 Task-number: QTBUG-86533 Change-Id: Idd5014b57a8d10070108f5b235c822863dbac088 Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* macOS: add default Edit menu items, if not added by AppKitVolker Hilsheimer2021-10-212-0/+49
| | | | | | | | | | | | | | | | | | | | | | AppKit automatically appends "Start Dictation..." and "Emoji & Symbols" menu items, after a separator, to a menu in the menu bar that has the title "Edit" in the operating system language. Qt applications might however be translated to some other language, in which case the "Edit" menu is not recognized by AppKit, and the menu items won't be added. This is bad for accessibility and for users wanting to type emojis. If we have a menu that has the title "Edit" as translated in Qt's i18n system, then create those items manually. To prevent a duplication of the system- provided menu items, don't add the items if there already is one with the action being set to the relevant selector. Otherwise, perform the selector or call the NSApplication method ourselves. This then results in the relevant keyboard input through regular code paths. Fixes: QTBUG-79565 Change-Id: Ifd06036211756277550d398034689aca8e770133 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Make QOffscreenX11PlatformNativeInterface a QX11ApplicationMichal Klocek2021-10-212-1/+15
| | | | | | | | | | | | | | Make it possible to use new native interface QX11Application with offscreen plugin in case of x11, which technically is x11 application without xcb connection. This change is motivated by use of new native interface in webengine, where offscreen plugin is used for some tests. Pick-to: 6.2 Change-Id: Ic2ed5b39573062feaa1e8985962d5d9327b371d7 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Android: set allowNativeHeapPointerTagging to false in the manifestAssam Boudjelthia2021-10-211-1/+2
| | | | | | | | | | | | | | | | Android 11 enables pointer tagging by default on arm64 systems [1], which can cause QML to get invalid data, which caused the color issue (and most likely other issues). [1] https://source.android.com/devices/tech/debug/tagged-pointers Fixes: QTBUG-97009 Task-number: QTBUG-91150 Change-Id: Ic4f145bba3345b3bee5445685f03269e3785f514 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> (cherry picked from commit 9fa805f7f8dfe96d561e9ed3170770ad768baf93) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Remove the unnecessary compile-time check for recursive QSetSona Kurazyan2021-10-211-2/+0
| | | | | | | | | | | | It doesn't make sense to have a recursive QSet with deleted operator==, since it's not possible to add elements to it. Consequently declaring a metatype for it also doesn't make sense. Remove the commented compile-time check for it. Task-number: QTBUG-96257 Change-Id: I74ebefb38adcbe36d5c2f317188743e1f37fe16d Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* TLS plugin (OpenSSL): don't use the deprecated functionsTimur Pocheptsov2021-10-214-26/+58
| | | | | | | | | | | If we have OPENSSL_NO_DEPRECATED_3_0 defined. This includes RSA, DSA, EC and DH-related APIs. As of now, we only make sure the code still compiles. Pick-to: 6.2 5.15 Fixes: QTBUG-83733 Change-Id: Id455b851421ce0dcdfb0229fa515ba2b2ed690b1 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Fix inconsistencies between advanceWidth and bounding rectsAllan Sandfeld Jensen2021-10-214-117/+75
| | | | | | | | | | | | | | | | Unify the logic in QTextEngine Ensure tightBoundingRect, and the FreeType boundingRect, calculates from the shaped x offset when calculating the max x coordinate for a glyph. Fixes: QTBUG-7768 Task-number: QTBUG-70184 Task-number: QTBUG-85936 Task-number: QTBUG-94023 Change-Id: I6daafb25c79158dc7e777529abb5e8d3a284dac0 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* androidtestrunner: make sure that system-user is usedBartlomiej Moskal2021-10-211-1/+10
| | | | | | | | | | | | | | | | | | | | | | | It happens on Android Automotive emulator, that output file is in other directory. According android spec [1]: "If a default user isn't specified, each adb subcommand has a different user. The best practice is to retrieve the user ID with am get-current-user and then explicitly use --user <userId> for any command that supports it." That is the reason why output file can be found in /data/user/USER_ID/PACKAGE_NAME directory. Checking path related to current user was added as backup solution. [1]https://source.android.com/devices/tech/admin/multi-user-testing Pick-to: 6.2 Change-Id: Id7e6ddef74f4f20b7469a07bba6a71d3622c4e20 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Move the ABI tag from minimum-linux.S to qlibraryinfo.cppThiago Macieira2021-10-214-111/+44
| | | | | | | | | | | | | | | We don't need the assembly file any more. According to a comment to patchsets 2 in the Gerrit code review for commit bb8a61866ec6a6de2426012f8c4219d41b3a414a, the section ended up as SHT_PROGBITS instead of SHT_NOTE. I didn't know then that the section type is not actually important, only whether it's present in the segment pointed by a PT_NOTE is. That isn't recorded in the review. Since we now depend on the linker properly placing the .note.* sections for Qt plugins, we can rely on this working. Change-Id: Icb2516126f674e7b8bb3fffd16ad659149e34a23 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Doc: QByteArrayMatcher: add note that the pattern must remain on scopeThiago Macieira2021-10-211-4/+9
| | | | | | | | This issue bit me. The API is surprising and very un-Qt-like... Pick-to: 6.2 Change-Id: I2bbf422288924c198645fffd16aa1c58d921bd7e Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QFactoryLoader: continue the port from JSON to CBORThiago Macieira2021-10-206-28/+52
| | | | | | | | | | | | | | This continues the effort from the previous commit, by not passing through the JSON conversion at all, and simply using CBOR directly. The port in qtbase is complete, but in order to support the conversion in other modules without introducing breakages, there's a temporary class used for converting to QPluginParsedMetaData from QJsonObject. It'll be removed once all other modules have finished converting. Change-Id: I2de1b4dfacd443148279fffd16a3ed4ddaf34afc Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QPlugin: keep the CBOR data as CBORThiago Macieira2021-10-206-78/+110
| | | | | | | | | | Since QJsonValue and QCborValue use the same backend, we may as well use the CBOR frontend classes, which means we avoid an unnecessary conversion until later. Change-Id: I2de1b4dfacd443148279fffd16a3e2f56cd74c0b Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove WIN32 and MACOSX_BUNDLE arguments when building Android binaryAlexey Edelev2021-10-201-1/+1
| | | | | | | | | | This fixes the regression introduced in Android multiabi changes. Amends 0a02d845559e4fd9d1bd72942c5118f3bb1307bf Task-number: QTBUG-88841 Change-Id: I09e129361eb760cdc14c2302e821ce4fcbf117c3 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* macOS: Wake up event dispatcher after running modal dialog helpersTor Arne Vestbø2021-10-203-0/+14
| | | | | | | | | | | | | The root event loop may have been exited, so we need to ensure the event dispatcher is woken up so it can evaluate whether it should continue or not. For most applications this happens automatically when e.g. the user moves their mouse or press a key, but for tests this may not be the case, and the test will stall and never exit its event loop. Pick-to: 6.2 Change-Id: Ic241e3f1045481c34150289ff711b921addb18e4 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Centralize maybeLastWindowClosed checking in QWindowTor Arne Vestbø2021-10-208-41/+59
| | | | | | | | | | | | | | | | | Instead of plumbing QWidgetWindow close events via handleCloseEvent, we just implement closeEvent directly. This allows QWindow do save the state of the window/widget before the close event, so that we know whether we should trigger lastWindowClosed handling, even if the window was deleted as a result of the close event. This also relieves QGuiApplication and QApplication from dealing with the close logic in their notify functions, so that these functions can focus on the propagation of events -- not how the event is handled. Change-Id: I8b586b53a53b1df1d8630c1acb635c60f191bb4b Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Make QMainWindow::restoreStateSizeChanged test less time sensitiveVolker Hilsheimer2021-10-201-2/+29
| | | | | | | | | | | | | | | | | Amends 32edae5e268b968aff82f0713612eff2feffb4e1, which introduced a timeout after which the restored state is discarded. If this timeout hits during a CI run, then the test is expected to fail. Implement a lambda that watches for the restored state to disappear. This happens primarily when restoring a fullscreen state, where some desktop environments scroll in a new virtual desktop. It should not happen for other data tags. Change-Id: I5ff43a4e1857eca17a5d4fe2b47add1f70636e8d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* QDateTime: Limit string processing to known boundariesMårten Nordheim2021-10-201-6/+18
| | | | | | | | | | | We were treating the input as if it was always reasonably good. Since we know the max boundaries anyway lets just stop processing when those are reached Fixes: QTBUG-97489 Change-Id: Ibb78d6d51ad58454b2007ab46d54116ca0be5448 Reviewed-by: Robert Löhning <robert.loehning@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* SSL: Update documentation wrt backendsMårten Nordheim2021-10-201-8/+31
| | | | | | | | | Mention the platform-specific backends and add a section on packaging Pick-to: 6.2 Fixes: QTBUG-97532 Change-Id: Ice78e32e81a719ccf237625e542d620662d3073e Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QNI: Windows: support transportMediumMårten Nordheim2021-10-204-1/+102
| | | | | | | | | | | | | Brings support for transportMedium to NetworkListManager backend. Which, with this patch, also uses winrt API because there is no equivalent API available in NLM. This API is so much nicer than NLM... Task-number: QTBUG-91023 Change-Id: I360a3a197caa2aa4848c8f768aea6a09a68b0ed5 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Fix metatype declaration for QHash/QMultiHash with no operator==Sona Kurazyan2021-10-202-12/+18
| | | | | | | | | | | | | | | | | | | | | | | When declaring metatypes, the metatype system tries to detect if the comparison operators for the given type exist and automatically register them. In case of QHash, the equality operator was enabled if the value type provides one. But the implementation needs equality operator of the key type as well. As a result, when the key type has no equality operator, the metatype system detects that the equality operator is available for the QHash itself, but the compilation for metatype registration fails when trying to instantiate the code that uses equality operator for the key. This is fixed by enabling equality operators for the QHash only when both the key and value types provide one. The same issue existed also for QMultiHash, with the difference, that QMultiHash didn't have the constraints even on the value type. So added checks for both. Fixes: QTBUG-96256 Pick-to: 6.2 Change-Id: Ib8b6d365223f2b3515cbcb1843524cd6f867a6ac Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Help the compiler avoid duplicate TLS lookupsUlf Hermann2021-10-201-2/+4
| | | | | | | | | Most compilers are clever enough to optimize this out. Yet, even with optimizations disabled, we don't want to do two TLS lookups here. Change-Id: I822954c7cec591084d6c27c916818dab7e000ea9 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Optimize QObjectCompatProperty::notifyUlf Hermann2021-10-203-25/+44
| | | | | | | | Do the check for inBindingWrapper() last. Change-Id: I3d589c9fba524f465e35cd4cc0e65e3af376b419 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QObjectCompatProperty: Add support for custom gettersIevgenii Meshcheriakov2021-10-204-12/+87
| | | | | | | | | | Add additional template argument to QObjectCompatProperty to specify a custom getter. This may be useful for classes like QAbstractProxyModelPrivate the need to customize property getters. Task-number: QTBUG-89655 Change-Id: I34fe4bdebbbf1446aff60bd20a946454607f52d5 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Make QDir::mkpath() return true when given an existing root pathKarsten Heimrich2021-10-202-4/+6
| | | | | | | | | | On macOs with APFS mkdir sets errno to EISDIR, so take the error code into account. Pick-to: 6.2 Fixes: QTBUG-97110 Change-Id: I8e7d10c95430a2802bdbfbf94dd65219bd9071a7 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Make QDir::mkpath() return true when given an existing drive nameKarsten Heimrich2021-10-202-1/+6
| | | | | | | | | | | | Commit ed48391c592e8ba68c723e3017ac384f0c7a7c23 removed the check for ERROR_ACCESS_DENIED reported by the Windows CreateDirectory(...) function in case an existing windows drive name was passed as argument. This restores the behavior of the function which broke after 5.15. Pick-to: 6.2 Fixes: QTBUG-85997 Change-Id: Ie86188100766f7364acee57b15a250f4a2720b9f Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
* Compile Private API autotests for INTEGRITYTatiana Borisova2021-10-202-4/+2
| | | | | | | | | | | | | | | | | | | | | - GHS's __PRETTY_FUNCTION__ (used by QT as Q_FUNC_INFO) doesn't have spaces round the = operator when indicating the type of the template parameter. The compilation error: qt5/qtbase/src/corelib/kernel/qmetatype.h", line 2104: note #3316-D: cannot access position 53 in array of 49 elements constexpr const char *begin = func + prefix; ^ detected during: instantiation of "auto QtPrivate::typenameHelper<T>() [with T=void]" at line 2186 Task-number: QTBUG-97087 Pick-to: 6.2 Change-Id: I33e61f5d54a61944a5aecf07d149a8dee0ef1e5d Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add missing LIBRARY DESTINATION for examplesAlexey Edelev2021-10-203-0/+3
| | | | | | | Pick-to: 6.2 Fixes: QTBUG-97629 Change-Id: I5b32824693206926de9b4ee6637749a1814fdde7 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* uic: Fix missing Python import when setting tab ordersFriedemann Kleint2021-10-202-2/+3
| | | | | | | | | Add QWidget as default import so that QWidget.setTabOrder() is found. Pick-to: 6.2 Change-Id: I7593008d1395e3fddacf7124d271a0eaf4c345d9 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* CMake: Fix rpath-link dependencies when cross-compilingAlexandru Croitor2021-10-201-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Private Qt module dependencies of a Qt module are recorded in the IMPORTED_LINK_DEPENDENT_LIBRARIES property of a Qt module. This property is used to compute the runtime dependency dir path to be passed to the linker via the -rpath-link option. If the referenced target does not exist in the scope where it's used, no -rpath-link will be generated (or at least that specific dir path won't be passed). The linking operation will either fail saying the library is not found, or a different version of the library might be silently picked up in the sysroot or other implicit lib dir. Make sure that QtFooModuleDependencies.cmake calls find_package() for all Qt module private dependencies (or other Qt provided 3rd party libs in the Qt6:: namespace) so that the targets are in scope and IMPORTED_LINK_DEPENDENT_LIBRARIES does its job. qmake also records the INTERFACE_LINK_LIBRARIES of a private Qt module as the runtime dependencies of the module. It's not clear why it does that. A private Qt module is an INTERFACE_LIBRARY so it shouldn't add any new runtime dependencies. Nevertheless, the find_package part of that has been recently addressed in 2b6500cd15c0a41cf3e5eea8178e2044012dbd97 for a different reason. This change is basically the CMake equivalent of 326b91ea788b013512ae911c51cc19497d88916d Pick-to: 6.2 Fixes: QTBUG-86533 Change-Id: Iaf514a14acaded4e8752149cca0c159a271be188 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* RHI: use the flags we've just calculatedThiago Macieira2021-10-191-1/+1
| | | | | | | Caught by clang 13 detecting we set a variable but never used it. Change-Id: I8c6a0ff3ec184205a544fffd16af3d52b6f172a2 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Fix correspondence between QFileDialog::Option and ↵Alexander Volkov2021-10-193-4/+13
| | | | | | | | | | QFileDialogOption::FileDialogOptions It was broken by fe4a5a27e09b8109381e52aa1b71135a916dff1a. Pick-to: 6.2 Change-Id: I77da7ec9cdedc80a72b7f11980950a8bebfdaf3b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QtGui & its plugins: remove set-but-unused variablesThiago Macieira2021-10-192-6/+0
| | | | | | | | | Found by clang 13: qfontsubset.cpp:1211:10: warning: variable 'sumAdvances' set but not used [-Wunused-but-set-variable] Change-Id: Iea05060bc2c046928536fffd16adf500fb9bc8e5 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* MySQL: only set the charset if the connection has succeededThiago Macieira2021-10-191-13/+14
| | | | | | | | | | No point otherwise. But do it before trying to select the database, in case the database name has non-US-ASCII characters. Task-number: QTBUG-97054 Pick-to: 6.2 6.2.1 Change-Id: Iea05060bc2c046928536fffd16adf036367b07bb Reviewed-by: Liang Qi <liang.qi@qt.io>
* MySQL: fix the check for the return value of mysql_set_character_set()Thiago Macieira2021-10-191-2/+2
| | | | | | | | | It returns zero on success and non-zero on failure. Fixes: QTBUG-97054 Pick-to: 6.2 6.2.1 Change-Id: Iea05060bc2c046928536fffd16adf0177aadb082 Reviewed-by: Liang Qi <liang.qi@qt.io>
* Rhi: Document expectation for setGraphicsPipeline's pipeline argumentChristian Strømme2021-10-191-0/+3
| | | | | | | | | The backed expect the pipeline to be valid, so document it and assert if the set pipeline is a null pointer. Pick-to: 6.2 Change-Id: I72b3d0d11b8dc98240d17e13adf2b6ccbd71891d Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Disable copy and move for QPropertyObserverNodeProtectorUlf Hermann2021-10-191-1/+4
| | | | | | | It's not intended to be copied or moved and static analysis complains. Change-Id: I2ac2eccadb66ea572cf297f16af693b15553a1b9 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Don't render widget to backing store if its parent has graphics effectAntti Määttä2021-10-191-1/+14
| | | | | | | | | | | | If widget parent has graphics effect, it can't render directly to the backing store, because the backing store needs to be updated from the parents effect drawing instead of the widget drawing. Pick-to: 6.2 5.15 Fixes: QTBUG-96240 Change-Id: Ib9b55547f9e5538f32837ec9df45d29fa68d7c1b Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* RHI: suppress annoying warning about deprecated copy constructorsThiago Macieira2021-10-181-0/+1
| | | | | | | | | | | | With clang 13: vk_mem_alloc.h:4360:22: warning: definition of implicit copy constructor for 'VmaStlAllocator<VmaDefragmentationAlgorithm::AllocationInfo>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy] vk_mem_alloc.h:4391:9: note: in implicit copy constructor for 'VmaStlAllocator<VmaDefragmentationAlgorithm::AllocationInfo>' first required here Repeats ad nauseam Change-Id: Iea05060bc2c046928536fffd16adf5181ede7abe Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>