This should keep gcc from complaining that they're unused const
variables. Pick to 6.8 required conflict resolutions in non-generated
code and qlocalexml2cpp.py due to dev's updates to handle time zone
name L10n; regeneration of data took care of the other conflicts.
Fixes: QTBUG-128930
Change-Id: I4d0bccc5f158dfc72e4cf38a085b90cb562dc185
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 08ef4d232df82c056d4f5fda636b62b65fc054ad)
If a menu contains no or only invisible actions, then its sizeHint might
become invalid (depending on style), resulting in an invalid geometry.
In that case, return early from popup(). Otherwise we try to show popup
window with an invalid size, which results in unpredictable behavior,
depending on the windowing system.
To minimize possible fallout from this change, don't return early from
QWidget::show (or QWindow::setVisible), but fix this locally in QMenu.
The QMenuBar test used empty menus to confirm that hovering over other
menu bar entries would highlight the menu bar entry under the mojuse,
and close the currently open menu. This can be tested better and more
reliably with menus that are not empty, which is (probably) also going
to fix the test on wayland.
Fixes: QTBUG-129108
Change-Id: Icc52528e89baefea04b3b27e6f02674bf74162b2
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 353ce5344fbde5a6cecbdd2c131e1cf0f4b7f383)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Add PE_IndicatorBranch so the correct arrows are used instead the
windows 10/vista ones.
Change-Id: I5328a91b883078b4564890729f73dbfc573cbf00
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io>
(cherry picked from commit 02bf12072feee46f3b5f966a88f5094c55553b48)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This example is for the animation framework (graphics),
it isn't about multimedia. Use the correct category.
Change-Id: I32f0ce13a5496c8fbc871d8f2454575c25684eba
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
(cherry picked from commit 382fd3010b5ba8038a6bfe4415f06a0f6ed8029b)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Amends commit 41f84f3ddb - in which I
neglected QDTE. It just needs to set defaultCenturyStart to its old
initial year to match the prior behavior.
Fixes: QTBUG-126698
Task-number: QTBUG-46843
Change-Id: If1edafe25778ad064f8f4393c8b1b3bbf5c957dc
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 130e066868634f4663b4640ee1923eece1c171b1)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This is a Qt dependency that the user cannot influence.
Pick-to: 6.8.1 6.5
Change-Id: I6efbfefb5901588f4c99b4edfa05b21b68ab01a7
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit cfefce57a4ff446305cd1f839e7c5203bac7a6c5)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Make the sort indicator arrow drawn in PE_IndicatorHeaderArrow a little
bit smaller (the same size as for PE_IndicatorBranch.
Change-Id: I34035a845b1a0f5ebdb1257d802360ce3df7e703
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io>
(cherry picked from commit 8945f7d6eb6c370ab5992d6250194f7b2c9df969)
We have some patterns for how to document certain functions, but we
also vary the sentences a lot, and you have to look up one
documentation piece and copy it, essentially. If we ever want to
change them, we end up with shotgun surgery.
So apply DRY to the documentation and start a collection of macros to
help with repetitive C++ class documentation tasks.
The first macro is for member-swap(), and this fourth patch is for
documentation that used to be \internal. But the classes are public,
so don't hide the swap() member functions, document them.
Task-number: QTBUG-129573
Pick-to: 6.7 6.5 6.2
Change-Id: Id81b5ace05a7ccaf2a2194ebd56af10e8a98d7be
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 5a9bd64366b2ce2757843db0358cd48e4369b3d7)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
We have some patterns for how to document certain functions, but we
also vary the sentences a lot, and you have to look up one
documentation piece and copy it, essentially. If we ever want to
change them, we end up with shotgun surgery.
So apply DRY to the documentation and start a collection of macros to
help with repetitive C++ class documentation tasks.
The first macro is for member-swap(), and this third patch is for
documentation that used a non-standard phrasing for documenting
member-swap(). By using the macro, the documentation automatically
conforms to what the documentation team picks as the \memberswap
expansion going forward.
As a drive-by, fix doc block indentation to the Qt standard of 4
spaces (only in changed lines), and add a few blank lines where they
were missing before.
Fixes: QTBUG-129573
Pick-to: 6.7 6.5 6.2
Change-Id: If007602d7690572fcbb848a8d0235416c908cfd2
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 82058367923ce164024885854c139ee5e0d89949)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
We have some patterns for how to document certain functions, but we
also vary the sentences a lot, and you have to look up one
documentation piece and copy it, essentially. If we ever want to
change them, we end up with shotgun surgery.
So apply DRY to the documentation and start a collection of macros to
help with repetitive C++ class documentation tasks.
The first macro is for member-swap(), and this second patch is for
documentation that used the simplified phrasing ("Swaps this X with \a
other."), which this patch adopts as the text for \memberswap, too,
because it doesn't repeat the macro argument, making it easier to find a
grammatically-fitting argument than in the traditional phrasing.
This doesn't change the documentation, except as follows:
* standardizes on simpified instead of traditional phrasing for docs
that already use the \memberswap macro
* adds the "very fast and never fails" blurb, if it was missing
* changes the function's argument name to `other`, as required by
the macro.
Task-number: QTBUG-129573
Pick-to: 6.7 6.5 6.2
Change-Id: I1123e783ce0da76c5997ff74007d77504ac5b334
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 5627e113793df3df24742d7af502a075c2c9e95d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
We have some patterns for how to document certain functions, but we
also vary the sentences a lot, and you have to look up one
documentation piece and copy it, essentially. If we ever want to
change them, we end up with shotgun surgery.
So apply DRY to the documentation and start a collection of macros to
help with repetitive C++ class documentation tasks.
The first macro is for member-swap(), and the first patch is for
documentation that used the traditional phrasing ("Swaps the X \a
other with this X.").
This doesn't change the documentation, except as follows:
* adds the "very fast and never fails" blurb, if it was missing
* changes the function's argument name to `other`, as required by
the macro.
Task-number: QTBUG-129573
Pick-to: 6.7 6.5 6.2
Change-Id: Ib494bd218334724b3b43796ba6f71fb52b83aa94
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 3ccb4ce781463f1b8e0cb4c9283b3067fe92a32e)
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The code in QMenu::popup relies on
QGuiApplicationPrivate::lastCursorPosition being up to date to decide
on the final position of the popup being shown. As cursor movements
outside of Qt windows do not trigger an update of that position, we have
to do a forced update of it in QWindowsSystemTrayIcon::winEvent.
Fixes: QTBUG-130832
Pick-to: 6.5
Change-Id: I45523688e21e294819337c69ad5b48eba5178446
Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
(cherry picked from commit 922369844fcb75386237bca3eef59edd5093f58d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
And use from macOS and xcb platform plugins.
Change-Id: I84a2d933551a59cf220ecb6841d8d756e58724a0
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 9d8744c77b03eb091061976dd084cb0ca3f6252b)
On VxWorks 24.03, the `AT_FDCWD` wasn't defined, which happened to
branch to the correct branch. VxWorsk 24.09 TP does define the
`AT_FDCWD`, which causes the preprocessor directives to branch to a
branch where moving files to trash would be supported.
In a sidenote, VxWorks doesn't define `renameat`, `O_DIRECTORY` nor
`O_NOFOLLOW`.
Task-number: QTBUG-130629
Change-Id: I2b850813aeff6f925ab91932efd7aeb13f753f69
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 039b0c6b9b94eb7601fa3b652e8b668d32251f7e)
Ensure we don't end up calling methods from a null m_imm object
inside runAction(), the code was guarded outside the call but not
inside where it can still happen.
Fixes: QTBUG-129684
Change-Id: I41d7e64a028f551bb53d177e16a77e7ae512a84e
Reviewed-by: Tinja Paavoseppä <tinja.paavoseppa@qt.io>
(cherry picked from commit 33ef9330f67dd3c6603fb222e1556c31591f1fd9)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The rect of an empty widget (i.e. 0 width/height) will, after adjusting
by -1, be invalid as it will have a width/height of -1. In turn, calling
contains(p) on that rect can return true even though the rect is empty.
Fixes: QTBUG-131001
Pick-to: 6.8.1
Change-Id: I604f5942589f1c1079cae90bd0d3b104344d2c55
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: David Faure <david.faure@kdab.com>
(cherry picked from commit 1731d8af741a0a6cc6cd293be4aef52103d0899b)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QFileDialog::show()/exec() can be called without having any parent
at all, so the check for 'winGuard' in authorization callback
would prevent image picker from being presented. In the end
we don't need this parent and using 'presentationWindow()' instead.
Check before asking for authorization that we indeed have/no
a parent window.
Fixes: QTBUG-130973
Change-Id: Ie3ba285dfff82ac3f53245a032e133bc26763883
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 6026a5aa21d1c11a87ce76a18e497b9547213e27)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Call d->deleteExtra() in dtor of QWidget to make sure it's cleaned up
before QWidgetPrivate calls it which might access the already deleted
QWidget through deleteTLSysExtra() /
QWindowContainer::toplevelAboutToBeDestroyed(q).
Amends 006cbf658ea1f5986bbe1baafa7c146780320661.
Pick-to: 6.8.1
Task-number: QTBUG-130932
Change-Id: I9109072a457cc01abd5d1b4e844a3ed3309d942b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 482c41fb6187f3ee1df11e7936fb60f65d12995a)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The test function assigns a hard coded rectangle to gestures and uses
the default size of a graphics view at the same time.
The leads to flakiness, where the gestures can't be delivered when their
size is out of bounds of the view's geometry.
Assign size size dynamically, according to the view's geometry.
Task-number: QTBUG-130811
Pick-to: 6.5
Change-Id: If75f59d15f84e610b4ec987daa2a06ce62539228
Reviewed-by: Frederic Lefebvre <frederic.lefebvre@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 6995709992344ac608f2b2a19b2c3883019bfaeb)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This will allow merging the updated toolchain, otherwise qt5 fails
to find OpenGL and friends. The whole block will be removed once the
toolchain file is merged.
Task-number: QTBUG-128455
Change-Id: If355b1c6360dba7b3567023430785c6d109f9fe8
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
(cherry picked from commit c0b9dc00145a6d2123b99ab8b1de692af5ead39a)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The current implementation of QTabWidget::clear is quite poor because it
deletes the tabs from first to last. When I was playing around, I found
out it's much faster to delete from last to first (with a lot of tabs it
goes from two seconds to 200 milliseconds in my testing). I assume this
has to do with the redrawing of all remaining tabs for each removeTab
call, while this is not necessary when removing in the reverse order.
Also, disable the stack widget's layout while we remove all tabs to
avoid unnecessary event posting, and disable updates of the stacked
widget as well as the tab bar.
Change-Id: I04972de05ab71f98da7f74412aaadc69a36efc32
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 8717c1752f9b72ac7c028b722f0a068e84e64eca)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The assert assumes that we are calculating the transformed bounds
of a glyph with exactly the same parameters as the image of the
glyph is later transformed.
However, when calculating the new bounding box of the glyph in
alphaMapBoundingBox, we do:
t.mapRect(QRectF(gx, gy, gw, gh))
And then round the width and height up.
When we transform the image of the glyph, we do:
t.mapRect(QRectF(0, 0, gw, gh)).toAlignedRect()
Note the origin is at origo and we align the rect. This can lead
to the actual transformed image sometimes being larger than what
is returned from alphaMapBoundingBox().
We could change alphaMapBoundingBox() to match the behavior of
the image transform, but it has a risk of missing some corner cases,
especially given that the same code paths are used for scalable
bitmap fonts.
In the end, just removing the assert is safe, since there is a
qMin() protecting against buffer overruns later, and there does
not seem to be any visual difference from actually calculating
the correct bounds.
[ChangeLog][Freetype] Fixed possible assert when transforming
bitmap fonts.
Pick-to: 6.5
Fixes: QTBUG-130930
Change-Id: I0406e6f45e0d436a5248dd986703bb3a9288b9f4
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
(cherry picked from commit fd75a66f3f65f6c8e8bfb933260676b5c18f2df1)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
6ba003f732 fixed transforming
bitmap fonts for the case where 8 bit antialiasing is used.
This is the case when a transform is set on the painter by
the user, but for some reason it is not when high-dpi is
enabled, triggering QTBUG-111796.
An attempt was made at fixing this by drawing the
untransformed glyphs into the cache and then transforming
them as they were put on the screen. This worked with
Qt Quick, but the raster engine does not support this and
instead falls back to QPainterPath rendering in that case.
So b492582b9c caused a
regression and was reverted.
A simpler fix which works for both Qt Quick and QPainter
is to draw the pre-transformed image of the glyph into
the cache for 24-bit AA, same as for 8-bit AA.
In addition, this changes the transformation to nearest
neighbor instead of interpolating, because bitmap fonts
are typically intended to look crisp and it also matches
how native rendered fonts are scaled in Qt Quick.
Fixes: QTBUG-111796
Change-Id: I2d9fd9d98d32820e677916c3d1c744331a72175b
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
(cherry picked from commit b6247ced7e83af4d51ba20be8068f28cc8c006bc)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
With MinGW, GCC and Clang `[=, this]` is acceptable in C++20 mode, but
MSVC on the CI still builds with C++17. So use `[&]`, the other two
variables used inside the lambda are (const) built-in types, taking by
reference is the same as taking by copy.
Amends a90d99d8da9b2be2e6b8e981cd9dabfb1641e985.
Change-Id: Ib1c746ccf1c02b2ee3891eca5bddd7e47f559dc5
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
(cherry picked from commit bac7f20acd37911813bd774afea55823b8320aa2)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Previously we ran some finalizer functions for tests and manual
tests, only for specific platforms, and via different code paths.
This change introduces a new unified way of running all finalizers for
all test-like executables, including benchmarks.
To ensure a smoother transition, the new way is opt-out, and the old
way can be enabled by setting the QT_INTERNAL_SKIP_TEST_FINALIZERS_V2
variable to true in case we encounter some issues in the CI.
The finalizers are only run for test-like executables, and not all
internal executables, because there are some unsolved issues there.
One particular case is in qtdeclarative where that will create a cycle
for qmlimportscanner to depend on itself.
A proper solution here would be to have some kind of mapping or
mechanism to exclude finalizers for targets where they would try to
run themselves.
Task-number: QTBUG-93625
Task-number: QTBUG-112212
Change-Id: I52b3a1c02c298c4a18ce2c75d7e491ae79d191a0
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
(cherry picked from commit 25f575e8513a7e49ac73c7e1cb24dcaf3803358e)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This will be used in a follow up patch to identify them.
Task-number: QTBUG-93625
Task-number: QTBUG-112212
Change-Id: I39d5eb9f79ac67af0808efeda4d7f4e0a6908cc9
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
(cherry picked from commit df040fb1115071fbea80213814b7dc34b17ba085)
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This will allow running the finalizer properly for Android tests in a
qtbase built with in-tree tests.
This is similar to what we do with the
_qt_internal_add_qml_deploy_info_finalizer for the Qml module.
Task-number: QTBUG-93625
Task-number: QTBUG-112212
Change-Id: I233ce229054b5ce15783cf06b9a69aaa68eb8847
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
(cherry picked from commit a72dacce214e394da33529f2501e14c21b13c763)
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
The QT_ANDROID_DEPLOYMENT_SETTINGS_FILE was originally queried and
checked as part of the following commit
080f9ad160
because it was meant to be passed to the test runner executable.
The deployment file argument stopped being passed to the test runner
as part of 29b17fa335 whereas the
check was left in the code.
This check causes problems when trying to allow running deferred
android finalizers for tests, because the deployment file is set only
in the finalizer, but the check for the deployment file existence is
done earlier when trying to get the test runner arguments.
Remove the query and the check for QT_ANDROID_DEPLOYMENT_SETTINGS_FILE
because they prevent the above use case, and also don't serve any
purpose in the given function scope.
Task-number: QTBUG-93625
Task-number: QTBUG-112212
Change-Id: I6e620e452359c94cc7896a98ac5872221f6bb9a2
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
(cherry picked from commit 412e08106c050cd6b3f6bdf4d9303850c32f6232)
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
QWinRegistryKey::stringValue is more readable than
key::value<QString>().value_or(QString()).
This patch also adds developer documentation for the function.
Change-Id: I6a760db77a50ca9fa810196e14af14068df8aee3
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 16ca13e148445b5a18ea768c096dfedfbacce3c4)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QWinRegistryKey::value<T> returns an optional<T> which can make code a
bit more readable than the std::pair<DWORD, bool> return value from
QWinRegistryKey::dwordValue.
This implements part of the "TODO: Remove once all usages are migrated
to new interface." comment in QWinRegistry class because it allows us to
remove the QWinRegistryKey::dwordValue function.
Change-Id: If568de4e31778e91ce7aadadb4aac90e41222826
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 7a63a25ef71fbbe7b3eaa6ecb9a26c3e497e582a)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Android allows to explicitly chose the 24h format even when the selected
locale would not usually use that.
Change-Id: I6181d343a12d8d264c369341ef753d872f573121
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit e1f83e0ffbbd079b41e5a903e35d6cd6a62e6f99)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Remove an outdated paragraph which mentions some 'important inherited
functions' - the list is outdated and therefore wrong, and no other class
has such a paragraph.
Fixes: QTBUG-130916
Change-Id: Ia1d98da35564d542ca2758070cc1d5b5525b6faf
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 423496dcfbcd3a779653a4186a3b49ef8b5d2d7f)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The size calculation for CT_SpinBox was out-of-sync with the rects
calculated in subControlRect() for SC_SpinBoxUp/Down.
Fixes: QTBUG-115451
Change-Id: I140346fa1980e0cf95e0a07499f43467b721f01e
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 60c665d0b320324affa76702b5e5de3d37117809)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Don't load the pixmap used for PE_FrameGroupBox on every call to
drawPrimitive(PE_FrameGroupBox, ...) but store it in the QPixmapCache.
Change-Id: I5be6ce8a18cfc17c72dd5217efd5f446ba10ea64
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
(cherry picked from commit 12e8a7173569d03a98fcd47c593a09e55a96801d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
which happens when we build with SDK 14 (where there is not property
for importing PKCS12 in memory only) and then run on macOS 15
(where our trick with a temporary keychain is not working anymore).
Task-number: QTBUG-130500
Change-Id: I05845fa23dec70d48251f5e4d93084a574d67d92
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit c9d1f18d0b88f3a4c60bf9a1342459fd67f42dbe)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The implementation checks the state and returns without storing the
exception when its canceled or finished.
Add tests for both situations.
Done-with: Ivan Solovev <ivan.solovev@qt.io> (analysis and phrasing)
Pick-to: 6.5 6.2
Fixes: QTBUG-128405
Change-Id: I4610a022ea12e1bc9ce24cb17b972b5b9e051f0a
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 6efec3850da188d3bba075185aa6e5c264c815eb)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QCocoaDrag stores the last NSView that received an input event, which
becomes a dangling pointer when the NSView gets destroyed. Inform the
QCocoaDrag when NSView's destructor runs, so that it can reset the
pointer (and reset the NSEvent pointer as well) when the destroyed
NSView is the stored one.
With this change alone we'd end up triggering the Q_ASSERT later on in
QCocoaDrag::drag, as m_lastEvent is now nil so the NSWindow will be nil
as well. QCocoaDrag::drag cannot do anything useful if m_lastEvent is
nil, so exit early.
Pick-to: 6.5
Fixes: QTBUG-116554
Change-Id: I5949d728d05adcf3d4a32c91f7e181393bef0422
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 720ce9b97b767fdf36eaf78107b23bd017e191f3)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
CMake 3.31 introduced CMP0177 that warns if an install destination is a
not-normalized path. Fix this by normalizing the offending paths before
using them.
Change-Id: I1586bf192a4fd26108aa0448431f19e69df8aacd
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
(cherry picked from commit 14fc7f0852903109fed8357e2df9edc851f31b65)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
CMake 3.31 introduced the policy CMP0174 that triggers a warning if a
single-value argument is passed to a function without a value.
We did this doing this when forwarding arguments in code that doesn't
use _qt_internal_forward_function_args yet, e.g. in qt_internal_add_app:
qt_internal_add_executable(...
TARGET_PRODUCT ${arg_TARGET_PRODUCT}
...)
Forward the warning-triggering arguments with
_qt_internal_forward_function_args now, because that only forwards used
arguments.
In the future, we can offload more forwarding work to the
_qt_internal_forward_function_args command and simplify the forwarding
code in qt_internal_add_app and qt_internal_add_tool. This patch only
fixes the worst offenders for now.
Change-Id: Ie786691e4b236decf4c62f4dd0751ed76b721177
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
(cherry picked from commit 18a217af4a50afd707ed2caed4880d0da19ee120)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The QComboBox dropdown doesnt render when its added to a
QGraphicsProxyWidget and any QGraphicsEffect is added to it.
Fixes: QTBUG-128916
Fixes: QTBUG-128329
Change-Id: I7f9b7ceea9afa819fcd4785250859ea7b7c85f69
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 5fc968ade3120fe7f9d0d01988254fd1fb855262)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The usage in manifest was accidentally removed in
963a31c0f4. To avoid this warning
more explicitly we add "tools:ignore" to the XML files. This
is a false positive because we use it in
src/android/jar/src/org/qtproject/qt/android/QtActivityBase.java.
Pick-to: 6.5
Change-Id: I2fe1d0930b81b3c33e7b6b1ad6f6e152dc3e0740
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 709eb77ff0f32792beb18d3edea9e0aa4436f481)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Re-shuffle the way logcat is handled, so now fetch the logcat by
default after the test run, then manually filter out the test pid
logs. Then try to look in the logs for potential ANR cases, if
found, add also logs belonging to the system_service pid which are
responsible for printing ANR details and usually the reason for the
ANR as well. At last, look for logcat crash marker that ndk-stack uses
and pass only that portion of the logs to ndk-stack command.
Fixes: QTBUG-130818
Change-Id: I162d9d884a977e8f66a3253e33eebad4453c95cb
Reviewed-by: Petri Virkkunen <petri.virkkunen@qt.io>
(cherry picked from commit 5c68af9e1481f56fae962e865a9600dc64c465b1)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Remove string "unsupported_android_version" from string.xml. The
resource `R.string.unsupported_android_version` appears to be unused.
The usage was removed in b8e404f6d0631e04d30a864dc68b0574bfca90f1.
Pick-to: 6.5
Change-Id: Ifc936c070dabe4bc31d45bbb6b261890d5c2e536
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
(cherry picked from commit 0534a566a7d79a674931aefa6cc96a8e9343a1b3)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Instead of removing group separators after conversion, we can omit them
using QLocale. The decimal point and group separators can be the
same character, if the user configures the system locale accordingly.
Add a test that compares the text shown by the spinbox with what the
locale would do. Since the C locale sets the OmitGroupSeperator number
option by default, cover several cases to verify that we explicitly
set the correct number options based on the QDoubleSpinBox property,
and implement a customized system locale that returns the same
character for group separator and decimal point.
Fixes: QTBUG-77939
Change-Id: I257ea44ed988c70cb4fc0cfc81c3b366c0a431eb
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 34b5e43e6259c6362c642a244ceb26d482f35b82)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>