Commit Graph

67037 Commits (7b6f7a80da618b18e5c9a7e65f6cb3b7d48976ae)

Author SHA1 Message Date
Frédéric Lefebvre 7b6f7a80da tst_QButtonGroup::arrowKeyNavigation() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Icd8737a881712bb9192b401a0e318fcec4622ac2
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 18:26:14 +02:00
Frédéric Lefebvre c36aa81264 tst_QAbstractButton::setShortcut() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I027b78c969affe195bd7dde9a3c974586804d1e9
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 18:26:14 +02:00
Frédéric Lefebvre efbac03168 tst_QScroller::mouseEventTimestamp() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I8f118386b861bfab61fa61c9fb4cf5863abcac83
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 18:26:14 +02:00
Frédéric Lefebvre f81fa1de1d tst_QScroller::overshoot() remove QApplicationPrivate::setActiveWindow
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Iabebbeed38c20a5de150d688850e32a361290a90
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 18:26:14 +02:00
Andreas Eliasson f8bc0e7c3b Doc: Remove \note that indicates you can access the source code
There used to be an examples page; this is no longer the case. Thus,
remove the \note that indicates you can access the source code.

Fixes: QTBUG-122166
Pick-to: 6.7 6.6 6.5
Change-Id: I1abe88000ae406e8d2cc9cc1deed42664607626b
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2024-04-29 17:38:52 +02:00
Tor Arne Vestbø 0b494c47d3 Don't quit automatically via QEventLoopLocker if there are open windows
As part of df359bcb70 the semantics and
interaction between QEventLoopLocker and QGuiApplication was changed,
based on the assumption that these two mechanisms were independent
and should not affect each other.

This had a surprising regression where the use of QEventLoopLocker in
combination with the QCoreApplication::isQuitLockEnabled() automatic
quit would end up quitting the app, even if it had open windows, for
example when the last job of some internal job queue finished.

It could be argued that if the app has open windows that should not
be closed, they should ignore the Close event, and that an application
with running QEventLoopLocker jobs should maintain an active window
showing the progress of those jobs, but still, this is regression
that we want to fix.

We now bail out if !lastWindowClosed() in QGuiApplication's
canQuitAutomatically, which is triggered from QEventLoopLocker's
isQuitLockEnabled() behavior. And we do so regardless of whether
quitOnLastWindowClosed is set or not, as the latter property
determines the behavior when closing a window, not the behavior
when a QEventLoopLocker goes out of scope.

Similarly, we now block quitting of the application when triggered
by quitOnLastWindowClosed() if a QEventLoop is active, regardless of
the isQuitLockEnabled(), as the latter property is determining
whether we should trigger a quit, not whether we should block them.

[ChangeLog][Important behavior changes] Fixed a regression where
the last QEventLoopLocker going out of scope would quit the app,
even if there were open windows, if quitOnLastWindowClosed was
false.

[ChangeLog][Important behavior changes] Fixed a regression where
closing the last window would quit the app, even if there were
active QEventLoopLockers, if isQuitLockEnabled was false.

Fixes: QTBUG-124386
Pick-to: 6.7 6.5
Change-Id: I84fd0ddea78a2f417f3a17b326113c880079cf85
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2024-04-29 14:26:38 +00:00
Frédéric Lefebvre d93ec246c7 tst_QGraphicsWidget::verifyFocusPolicy() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I2e3a630036b313696f62bbd3183c0448624395e8
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:38 +02:00
Frédéric Lefebvre 462b85b7e9 tst_QGraphicsWidget::verifyFocusChain() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ie762c7fa6bc4bf15f8580b3569e2196a5bd40b25
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:38 +02:00
Frédéric Lefebvre 3c2062f5ee tst_QGraphicsWidget::setTabOrderAndReparent() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I5bbe1cbd1e00a82504ed040347581264caf5b560
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:38 +02:00
Frédéric Lefebvre bdf136b1b3 tst_QGraphicsWidget::setTabOrder_data() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: If105d1c2db3646c7d31d72aeaa373015f175fd44
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:38 +02:00
Frédéric Lefebvre 2e6a25da7c tst_QGraphicsView::QTBUG_70255_scrollTo() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: If78234df30ca5716bd8bb23eb4297ae461ae88a8
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 02f493f6d8 tst_QGraphicsView::hoverLeave() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I0d16654ed837009391967b187f8dbe5dced0849d
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre c65aebfad6 tst_QGraphicsView::QTBUG_5859_exposedRect() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Iafebaaf4c737c2e07dbc7a5ea1d3a5a4cd335150
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre ec4221a37c task255529_transformationAnchorAndViewportMargins remove setActive
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Id88665c413398c4bca844b178ad24ea23c674d89
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 14:26:37 +00:00
Frédéric Lefebvre 5680789b2f tst_QGraphicsView::inputContextReset remove() setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number:  QTBUG-121488
Change-Id: If4e12607b1fb34fcab10e57d259e876df7ea6949
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 27a40eacf6 tst_QGraphicsView::inputMethodSensitivity() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I9d3645af06caaa457e00798bc099f43f5a282767
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 30e638c877 tst_QGraphicsView::update() remove QApplicationPrivate::setActiveWindow
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Id9d32ad9d346219c24e29dc5f9772ea60cf372a3
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 317fcbf101 tst_QGraphicsView::task239729_noViewUpdate() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I586c77e9bd5dd78c2229bd0483893c12f8601694
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 7f8f27c22a tst_QGraphicsView::task207546_focusCrash() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ic1de76054aed90ad07ee0233c45018afdf2a45c8
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 83668a3762 tast187791_setSceneCausesUpdate() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Iaaff78826e74df119d4c4a8ea376e1b414da3c3d
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:37 +02:00
Frédéric Lefebvre 4232fc5c41 task172231_untransformableItems() remove setActiveWindows()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I61f03a01e6001b0ced0297ff4d9bb0d199585445
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:26:36 +02:00
Frédéric Lefebvre b3ae097a2c tst_QScroller::scroll() remove QApplicationPrivate::setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I3bfbad661ffc157777a1d598b1999b0d8625eec3
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:02 +02:00
Frédéric Lefebvre bcd3a00dfa tst_QScroller::scrollTo() remove QApplicationPrivate::setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ife4096dbe6f196d91f3d865c9e58908c4c30759f
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:02 +02:00
Frédéric Lefebvre 3718c0c320 tst_QCompleter::QTBUG_51889_activateSendTwice remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Id670b3f3cf34438c729afc3c82faf18a45b45d4f
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:02 +02:00
Frédéric Lefebvre ab664ea01a tst_QCompleter::QTBUG_14292_filesystem() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls from the end of the function.

Task-number: QTBUG-121488
Change-Id: I465558f404b5bf656f5ed9c3f4b2ed605da6c6b8
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre d32360cbca tst_QCompleter::QTBUG_14292_filesystem() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I6546dc09a51037d7c3dea5c816273ddfe3a8797e
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre 11a37c6cdd tst_QCompleter::task247560_keyboardNavigation remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I889d5301d44b1ba222aa0392347817a458ff66c3
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre 11f23e346d tst_QCompleter::tast253125_linedEditCompletion remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ie06a9326cb06f4ba657e065a52dfa1d8b319086b
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre 8ba6695c9d tst_QCompleter::task250064_lostFocus() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I45c0d92021f7404298e9836bb6c876fbcc8d7a7a
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre f51402e23d tst_QCompleter:task246056_setCompletionPrefix remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ib4ba40cc668395a1e5d826dab4caac7f307d1de7
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Frédéric Lefebvre 5f1c67dab4 tst_QCompleter::task178797_activedOnReturn() remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ia8a81f7d00131b1a80be9fe65c3e3ed557a149d6
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-29 16:12:01 +02:00
Matthias Rauter 737c6680b4 QRegularExpressionMatch: port API from QString to QAnyStringView keys
The QRegularExpression capture-by-name keys are currently QStringViews,
but are only ever used to compare them against a const char16_t*, so
this API is a perfect candidate for replacing all of these overload sets
with a single QAnyStringView function.

[ChangeLog][QtCore][QRegularExpression] Keys can now be passed as
QAnyStringView (was QStringView).

Fixes: QTBUG-103097
Change-Id: I1a80e85f301cc08370d70b3b5eb0ae10c6a51f33
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
2024-04-29 07:40:29 +00:00
Marc Mutz ab0b2a490e QSignalSpy: fix -Wweak-vtable by removing the QObject inheritance
Normally, we'd fix -Wweak-vtable by exporting the class and making at
least one virtual method out-of-line (typically the dtor), thereby
pinning the vtable to exactly one TU.

We can't export QSignalSpy, though, because it also inherits QList,
and we don't want to export QList subclasses to avoid QList API
becoming part of the ABI.

So remove the vtable, and therefore its being a weak symbol, by moving
the qt_metacall implementation from QSignalSpy into its newly-added
Private, at the cost of an additional memory allocation at
construction (though there was already the wish to make this class
pimpl'ed for extensibility, and this patch accomplishes exactly that).

This class used to be one of few places left that prevents adding
-Wweak-vtable to headersclean, so while this is a breaking change,
QSignalSpy doesn't really model is-a QObject. It uses QObject to
reuse, not to be reused. In fact, no external code should use the
QObject-ness of QSignalSpy, so it should be an acceptable SC break to
drop the inheritance.

We don't need to care about BC here, as we don't promise BC for
QtTest.

This now also allows (and requires) to make the dtor and the private
ctor out-of-line, avoiding the need for the init() hack.

[ChangeLog][QtTest][Potentially Source-Incompatible Changes]
QSignalSpy no longer inherits from QObject. If your code uses the fact
that QSignalSpy is-a QObject, you need to redesign around this now.

Task-number: QTBUG-45582
Fixes: QTBUG-123544
Change-Id: Id93ba0ee6bbb811455d3744a045e38e1b9f9c584
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Jason McDonald <macadder1@gmail.com>
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
2024-04-29 09:23:50 +02:00
Tuomas Vaarala 4946982534 [QNX] Add support for QLoggingCategory in QNX QPA debug log output
Makes it possible to enable debug log outputs via QLoggingCategory.
Earlier it was only possible via buid time flags.

Change-Id: Iaec732e7acdf44a74c9d7c806bf0e6f5a5f87b1c
Reviewed-by: James McDonnell <jmcdonnell@blackberry.com>
2024-04-29 06:39:18 +03:00
Kai Köhne f0633e8237 SQLite: Update identified license
SPDX nowadays has a dedicated license identifier for SQLite. Let's use
this.

[ChangeLog][Third-Party Code] Change identified license for SQLite from
'Public Domain' to more accurate 'SQLite Blessing':
https://spdx.org/licenses/blessing.html

Pick-to: 5.15 6.2 6.5 6.7
Change-Id: I6c3378c45bc5edf498673c1b060f8e8c14d96a62
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
2024-04-28 12:14:17 +02:00
Thiago Macieira 15eb9dccae QTest::test*Operators: test reverse order too
There's no need to condition that comparison only for heterogeneous
types. The reverse comparisons will compile if the types are homogeneous
(it's what we had already tested), but this now ensures the results are
also the expected ones.

Change-Id: If1bf59ecbe014b569ba1fffd17c4a2dd756157b2
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2024-04-27 21:35:38 +00:00
Doris Verria 8c44064f62 QWindowPrivate: Introduce virtual setFocusToTarget
When a window gains focus, the focus will be set to the focusWidget,
if one exists, in the case of QWidgetWindow, and to the window's
contentItem's subFocusItem, in the case of QQuickWindow.
However, we want to be able to customize this as we may want to set
the focus item/widget to the first, last, prev, or next, depending
for example, on the reason the window got focus. Eg.: on a TabKey
we want to focus the next focus object, on a BackTabKey the previous
one, and so on.
To be able to do this, add a virtual method in QWindowPrivate that sets focus to the specified item, and override for QWidgetWindowPrivate.

Task-number: QTBUG-121789
Done-with: axel.spoerl@qt.io
Change-Id: Ib5e17d6ff52c2323a4013c80bf411e92b4c8ce9b
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2024-04-27 20:13:20 +00:00
Thiago Macieira f8359084b9 QString{En,De}coder: add constructors with QString parameters
Because QStringConverter::availableCodecs() returns QString.

Added as Q_WEAK_OVERLOAD so this doesn't create ambiguous overloads when
passing QByteArrays.

Fixes: QTBUG-123919
Change-Id: If1bf59ecbe014b569ba1fffd17c29a253ac22abe
Reviewed-by: Sune Vuorela <sune@vuorela.dk>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2024-04-27 13:03:36 -07:00
Thiago Macieira 99f78eb708 QTimer/QObject::startTimer: improve the detection of overflow
Converting from int milliseconds to int64_t nanoseconds can't overflow
(it won't even for picoseconds, so we'll be fine for a couple more
decades), so we only need to address the cases where the millisecond
value was passed in int64_t: that is, in the std::chrono::milliseconds
overloads. For the other cases, I added a comment.

Amends bfc7535a10 to not allow the
detected overflow to happen at all, which could cause the timer to
become very small. Instead, we saturate to the maximum, which is about
292 years (just under 106752 days). That's longer than computers have
existed, so the chance that some Qt application is still running on a
computer without any reboots from today to 24th century is remote at
best.

This parallels QDeadlineTimer, which already has code to saturate when
using milliseconds.

Change-Id: I6818d78a57394e37857bfffd17b9b1465b6a5d19
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
2024-04-27 16:24:42 +00:00
Christian Ehrlicher 3abb1e7b54 SQL/IBase: factor out applying decimal scale into own function
Move the calculation of the decimal scale into own function and preserve
HighPrecision string values by not converting them into doubles before.

Change-Id: I839923189e9f6b1f8fb9ce234c987423703b79bf
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-27 16:35:11 +02:00
Marc Mutz ab06d402dd QVariant: fix C++20 build with older MSVC 2022
... which claim full C++20 conformance (__cplusplus >= 202002), but
still lack https://wg21.link/P0846.

Fix by extending the existing workaround for lack of P0846 support to
these compilers.

Known to fail: _MSC_VER 1936
Known to pass: _MSC_VER 1939

We might need to check 1938 and 1937, but the workaround should only
show up as an additional get/get_if overload and not disturb normal
operation, so it's not critical to get the boundary version exactly
right.

Amends eb9c8042cf.

Pick-to: 6.7
Task-number: QTQAINFRA-6204
Change-Id: Ia3e0072d606efb7efd6ce0f75239850c7cd925bb
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2024-04-27 06:13:40 +00:00
Thiago Macieira 2289fe932d QResource: use qint64 for lastModified
We pass it to QDateTime::fromMSecsSinceEpoch, which is signed.

Change-Id: I6979d02a7395405cbf23fffd17c992674c6321fc
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2024-04-26 15:26:46 -07:00
Thiago Macieira 860405064e QResource: remove unnecessary mutable markers
These are all modified by ensureInitialized() and ensureChildren(),
which are const. However, ensureInitialized() does a const_cast<> on the
object before calling non-const load(), which is where these are
modified.

Change-Id: I6979d02a7395405cbf23fffd17c992546ecbda49
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
2024-04-26 15:26:46 -07:00
Ingo Klöcker 1685a47f21 Select a list item instead of a row for the list test
In a list view each row contains exactly one element. Using selectRow
feels like wrong API for a list view. Use the select function of the
selection interface instead.

Change-Id: Id53091c797b89f0919b5d6441c98349e4989a495
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2024-04-26 20:57:34 +02:00
Tatiana Borisova 2606c09666 QBitArray: use new comparison helper macros
Replace public friend operators operator==(), operator!=() of
QBitArray to friend method comparesEqual() and
Q_DECLARE_EQUALITY_COMPARABLE macro.

Task-number: QTBUG-120304
Change-Id: I6b47111c144016b3aa05f01c8035c32d164291ad
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2024-04-26 20:11:14 +02:00
Axel Spoerl 913442a75a Widgets focus abstraction: Skip isFocusChainConsistent w/o logging cat
QWidgetPrivate::isFocusChainConsistent() iterates over
QApplication::allWidgets() to identify and log inconsistencies.
In applications with many widgets, this has a major performance
impact.

Disable the check and return true, unless the logging category
qt.widgets.focus is enabled.

Adapt tst_QWidget::focusAbstraction() to enable the logging category.

This amends 58d5d4b7c2.

Fixes: QTBUG-124666
Change-Id: Ia487b381ab45b052638b189bf56acaf4353b1a37
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2024-04-26 17:26:07 +00:00
Frédéric Lefebvre 48a2ee1e9d tst_QGraphicsProxyWidget::hoverEnterLeaveEvent remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Id5e601b2c95a25614149bd54707e9bc070979f89
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-26 19:26:07 +02:00
Frédéric Lefebvre cdde69b2fe tst_QListView::moveLastRow remove QApplicationPrivate::setActiveWindow
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I72a5b4ae7f47374cd6b84b7c212a93b6d1e2f607
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-26 19:26:07 +02:00
Frédéric Lefebvre c8134f617e tst_QListView::task262152_setModelColumnNavigate remove setActiveWindow
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: Ia6f812acd7a32804ad4cd0fc859ac6a507774da8
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-26 19:26:07 +02:00
Frédéric Lefebvre 979182b83b tst_QListView::shiftSelectionWithItemAlignment remove setActiveWindow()
2f6fe3a268 has made calls to
QApplicationPrivate::setActiveWindow() redundant.

Remove redundant calls.

Task-number: QTBUG-121488
Change-Id: I7cf230e46588a47a972dff8f4e40217390dcacc1
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
2024-04-26 19:26:06 +02:00