Use string concatenation for the long test names.
Split data rows are more << markers.
Change-Id: I502bcc615a53169a4175a09af08ae5f2c3133668
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This both makes the list of headers more readable and keeps the line
of code within our 100-column limit.
Change-Id: I7d53cca5beeeb9f6dd2b2a7c3311362750695d10
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Only one XHR test expects Keep-Alive, Upgrade, HTTP2-Settings as the
Connection: header, which fails when I run it locally, and I can see
no reason why that test [0] would expect it, where all the others just
give "Keep-Alive{{Ignore}}" (or "close") in their .expect files, so do
the same for [0] as well.
[0] sendPropfind:Send PROPFIND "allprop" request for collection.
Pick-to: 6.5
Change-Id: I09cafcf282861b87693b5782f34e2fb84c888ff1
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
We know that 'this' is a QObject* since the metatypes stack frame
mandates it. Whenever you pass 'this' to anything it's loaded from the
special 'This' stack slot which then triggers a DTZ check. A DTZ check
is a noop if we can prove that the type is statically known, though.
In QmlCompiler, if we have a valid register content, then the register
has been set in all code paths that lead to the instruction in question.
Fixes: QTBUG-111439
Change-Id: I81d1cd140eea63f85628c3bef3a8f6db0a12096d
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
The \include command includes the source in its entirety when the
second parameter is omitted. This pulled in also the license header
which was visible in the generated documentation.
Add snippet tags and use them to extract only the content we need.
Pick-to: 6.5
Task-number: QTBUG-113138
Change-Id: Ie3fe2fede1e81d08201ec4353352ef069aebc388
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
When siblings in a StackLayout are reordered, we need to react, since
the sibling order corresponds to the "stack order"
Fixes: QTBUG-112691
Pick-to: 6.5
Change-Id: Ie768af34bf5ee9d15ca67d61a64115f3df31990f
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
isReady() will only return true *after* componentComplete() and *before*
destruction is about to happen
There is no point in rebuilding the layout when an item is added or
removed before the component is ready, because there will be a full
layout rebuild as soon as the component is completed.
This is a preparation for fixing QTBUG-112691
Pick-to: 6.5
Change-Id: I6e19578d847c6d4518479bc00f21442333e0fb07
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
This fixes a bug in the following sequence:
- user opens a window
- the window is hidden whilst under the mouse
- later the window is reopened without the mouse being under the window
- with the lastMousePosition set an item underneath where the mouse
used to be gets activated.
On X11 we get a Leave event for the hidden window, this is not true for
wayland.
Pick-to: 6.5
Change-Id: Ib14e8dbe29f1ad9a71a488b671d226be1d017b8d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
To avoid confusion, all macros that take a class name as an argument should specify that the class name needs to be fully qualified, even
if you're already inside the namespace.
Fixes: QTBUG-110718
Pick-to: 6.5
Change-Id: Icaed4be5df44e8d35ef382a918246ed03b0bb0c5
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
They are equal to QList<QString> and QList<QVariant>, respectively. We
cannot express this fact in qmltypes, but since those are builtin, we
can just hardcode it.
Task-number: QTBUG-112227
Change-Id: Iebeb5f6a5350d1c7184b1d9e6a38647e048c3806
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
In the happy case this just retrieves the internal QList from the list
property. In the sad case it produces a deep copy. That's not worse than
what the interpreter does, though.
Fixes: QTBUG-112227
Change-Id: I8b2b0ac74c90b6dcee876e83a64502756733c1c5
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
This replaces the logging category magic to determine whether we should
output warnings.
Change-Id: Ibc95ed70227e3438504e921693aa4af9a1d0376e
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
It still tends to time out.
Task-number: QTBUG-99168
Change-Id: I6526dca0d991293918bddd90acbc4cf8de7e8525
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
In Unity Build, on OpenSUSE, for some reason compiler confuses
the Node with an `int`. This refactoring resolves the issue by moving
the type into the `icutils` namespace.
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: Id379b9aff21b29115d4503791debd658f034a0cd
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
The general recommendation to handle language changes in QML is to
handle the LanguageChange event. However, if one is willing to tie
themselves to the QQmlEngine, we can offer a way to ensure that calling
a function will result in a traslation binding.
This might also be helpful for anyone implementing a translation system
different from Qt's, e.g. KDE's i18n.
Fixes: QTBUG-102393
Change-Id: Id4d7a401e0be9d65e1769c8471b26689f44bf66a
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This is in line with what we do in the compiler when resolving implicit
list types of other types.
Change-Id: I49b9ab62d0c38228c7c755b8cf47a7a11e2e0984
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Comparison of variables of different types (int or size_t and bool),
missing override, lossy conversion from double to float.
Pick-to: 6.5
Change-Id: Iad4b18450ab0a0a1cab01fa524777e1441986875
Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Add a code snippet, as Item::transform is not a notifying property
so the Scale item has to be instantiated and bound to separately.
Fixes: QTBUG-70939
Pick-to: 6.5 6.2
Change-Id: Ie0ca672dc65f5a44fa2ac2c3f3ee897a6d663d80
Reviewed-by: Matthias Rauter <matthias.rauter@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Lists are internally cleared and each element is pushed to the back
from the source list in QML. Use nonsignaling operations for clear
and push and activate manually having performed the operations.
Fixes: QTBUG-112208
Change-Id: I1a995905f3fa758e4cc8c39b8576db668d84a067
Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
MSVC complains about us comparing a bool to a quint32, which is the
underlying type for the bitfields in QQuickItemPrivate. Fix that by
replacing QCOMPARE(A, true/false) with the corresponding QVERIFY.
Pick-to: 6.5
Change-Id: I7f50e6276b592c9abe8ceaea95c9283a0c431c78
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
Reviewed-by: Øystein Heskestad <oystein.heskestad@qt.io>
QQuickItemPrivate::accessibleRole is virtual and called by the framework
to determine the role of an item. The default implementation checks and
respects a possible Accessible attached object. However, subclasses that
override the virtual don't, so the attached properties are ignored, and
the class-specific implementation wins. This makes it impossible to
change the role of e.g. a checkable button.
To fix that, move the code respecting the attached object into a non-
virtual function that the framework calls instead, and only call the
virtual member if there is no attached object, or if that object is not
initialized with a role. Replace calls to the virtual from the
framework with calls to the non-virtual wrapper.
Do this for both QQuickItem and for QQuickPopup, and adjust the logic
in QQuickControl types that create an attached object and initialize
it's role when accessibility becomes active. Use the non-overridable
effective role value for that as well.
Add a test case, and to avoid any new framework calls to the virtual,
make it private.
Fixes: QTBUG-110114
Pick-to: 6.5 6.2
Change-Id: Ia709cecbd181b6d8ee3297a4af60c1e7db9a2c51
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
HoverHandler does not react to button presses. Images to indicate button
presses are loaded but never shown because of this. This patch adds an
additional PointHandler which reacts to button presses.
Pick-to: 6.5
Change-Id: I60c1daef5144d7431605b0dc7dbedc0723a17fe0
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Hover events are no longer propagated to siblings when they have been
accepted by an item, at least for the time being. This patch changes
the hierarchy such that it works either way.
Fixes: QTBUG-111322
Pick-to: 6.5
Change-Id: Ied953a423954342c02e613af618be0784d6397ee
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
The test case fails frequently and flakily locally with the Material
style, because the exit transition of the static menu interferes with
the opening of the dynamic menu. Wait for the static menu to be
completely done with the exit transition before continuing.
As a drive-by, replace all QCOMPARE(actual, true/false) patterns with
QVERIFY.
Task-number: QTBUG-104323
Pick-to: 6.5
Change-Id: Ide90f0094b05d628a0eb047248a72c35bcb7cdc3
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
GCC 13 says:
In member function ‘void QAbstractAnimationJob::setState(State)’,
inlined from ‘void QAbstractAnimationJob::setState(State)’ at animations/qabstractanimationjob.cpp:295:6,
inlined from ‘void QAbstractAnimationJob::complete()’ at animations/qabstractanimationjob.cpp:528:13:
animations/qanimationjobutil_p.h:41:39: error: storing the address of local variable ‘wasDeleted’ in ‘*this.QAbstractAnimationJob::m_selfDeletable.SelfDeletable::m_wasDeleted’ [-Werror=dangling-pointer=]
This warning is produced when the action is "return" (used by the
RETURN_IF_DELETED macro) because we'd leave m_wasDeleted with the
dangling pointer. However, it's not really dangling because it was
deleted, but GCC doesn't know that.
Pick-to: 5.15 6.2 6.5
Change-Id: I3b169860d8bd41e9be6bfffd1757115520a67972
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
User facing strings are being translated, and all qmllint warnings are
gone. JavaScript statments no longer end with semi-colon, and some
whitespace changes have been made.
Pick-to: 6.5
Change-Id: I2a6792800ef3b8a0dc596632dcd3b7d76aa08fe3
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
It was missing from QQmlXMLHttpRequestCtor, making life painful for
XHR users.
It's a method that has existed in every XHR specification, and is
required, if the goal is to be compliant with any XHR web standard.
[ChangeLog][Qml][XMLHttpRequest] Added missing overrideMimeType(mime)
method. This function can be used to force the XHR object to parse the
data in HTTP responses differently than what the server suggests.
Done-with: Oliver Eftevaag <oliver.eftevaag@qt.io>
Task-number: QTBUG-53709
Change-Id: I9f8ff37e1604b95306a85fc7e64db6d111b9e069
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
Amends 72651a50f8.
This commit decided to ignore double clicks in the virtual
QQuickItem::mouseDoubleClickEvent().
If a subclass inheriting from QQuickItem wants to not ignore
a double click, it should override mouseDoubleClickEvent()
and handle the double click event accordingly.
Fix QQuickMouseArea::mouseDoubleClickEvent(QMouseEvent *event) to *not*
call the base implementation in QQuickItem after handling a double
click, because QQuickItem sets that double-click MouseEvent back to
the ignored state.
This was leading to weird behavior on platforms with touch
screens like Android or IOS where buttons "got stuck" after
a double click.
Fixes: QTBUG-112434
Fixes: QTBUG-109393
Pick-to: 6.5
Change-Id: I774189fbcb356b07336f35f053e05a12c34ce602
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
It does not exist in Qt6 and was apparently replaced by WheelEvent.
Pick-to: 6.5
Change-Id: I6b833e664d8e5e5d6e2bd23ed90695d43073decd
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
If the area of a (List|Grid)View is 0, then instantiating delegates is
pointless, as they couldn't be shown anyway. However, our current logic
could not handle this case well, and would end up instantiating a
delegate for every delegate entry if their size also ended up being 0 -
you can after all fit infinitely many 0 sized items into a zero sized
container.
Detect this situation in QQuickItemViewPrivate::refill and the
applyInsertionChange implementations. Note that we only exit early if
there are no visible items and the view is zero-sized; if there are
visible items, we still want to ensure that they are removed after all.
We also need to adjust a few tests which had zero sized views to no
longer be zero sized; otherwise they wouldn't have created their
delegates in time.
[ChangeLog][QtQuick][ListView][Important Behavior Change] If a ListView
has size zero, it won't instantiate any delegates until its size becomes
non-zero.
Pick-to: 6.5
Fixes: QTBUG-110625
Fixes: QTBUG-89568
Fixes: QTBUG-51773
Change-Id: Ibe0e6fa5f01784016882522c120d2fee38df285b
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
The current text sounds a bit like it's describing a const value.
Change-Id: Idf9b8ae14ce032af7ac073419aba6250b26f5847
Pick-to: 6.5 6.2 5.15
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Give an overview of the module and some handy links and tips. This
also adds a note on how to get anti-aliasing with the shapes, as well
as a link to PathText as one of the supported element types.
Pick-to: 6.5
Fixes: QTBUG-106529
Task-number: QTBUG-112463
Change-Id: I137d25e2ca138454f913e92158d9286977457227
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
A QQmlScriptString without a d pointer is indeed empty.
Task-number: QTBUG-112859
Change-Id: Ic3aea676403bd815e73d26733392c7f6ac8b84b8
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
When checking for CallProperty we want the call base, not the
accumulator.
Pick-to: 6.5
Change-Id: I24ac066dd440bde459e20b3cf962af04ca531629
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
...and do not warn about missing properties if when is disabled. Besides
avoiding spurious warnings, this also avoids modifying a property only
to restore its binding/value directly afterwards.
Note that when the binding gets re-enabled, we still trigger the
warning.
Fixes: QTBUG-112860
Pick-to: 6.5
Change-Id: I5ddd32f2de2dec9da372b08ab4bb5bdb88873e51
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
It doesn't exist in the source dir because the files are, as the name
says, generated.
Pick-to: 6.5
Change-Id: I3b169860d8bd41e9be6bfffd1757127c90e0a6aa
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
WebEngine during page setup can create and delete
accessibility interface with QAccessible::deleteAccessibleInterface,
which will later on tear down end with a crash as lambda function
is called on non existing object.
In case accessibility interface is deleted do not try to call
repair window.
Pick-to: 6.5
Task-number: QTBUG-108226
Change-Id: Ic052d1b6c9c60168fb32f81134263fc484ee654b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Section delegate items will now notify the ListView when their geometry
changes. Enabling the ListView to call layoutVisibleItems to rearrange
the delegate items based on the geometric changes made to the section
delegate.
The listener is added when the item is created or fetched from the
cache.
The listener is removed when the item is hidden or removed from the
scene.
Fixes: QTBUG-101985
Fixes: QTBUG-100002
Pick-to: 6.2 6.3 6.4 6.5
Change-Id: Ia7617424a8447ba82f62629d93b6a000a72bfc02
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
It can actually be null rather than undefined. We need to generate a
separate check for that and output the correct error messages.
Amends commit 05f56d7c78
Change-Id: Ia795e31805181640cd5be19359af51067d3fc8d6
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
It should use the accent color when the control has active focus.
Pick-to: 6.5
Task-number: QTBUG-112650
Change-Id: Iab389ac4f7fa11e705f85b6a7d3c08e42aec6cd8
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
This patch fixes the following issues when the Material TextArea is
attached to a Flickable:
- Floating placeholder text scrolls with the Flickable.
- When text is cleared without the control having focus:
- Floating placeholder text is positioned incorrectly.
- The floating text background outline gap is still open.
- The background outline color is incorrect when the control has focus
(used primaryTextColor instead of accentColor).
Pick-to: 6.5
Task-number: QTBUG-112650
Change-Id: Icfa3517e4abcb1209ea2291dabdec225011f19ef
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
roleNames are generally guaranteed to be stable (given that QAIM has no
change signal for them), except that resetting the model is allowed to
invalidate them. TableInstanceModel did so far not take this into account.
Handle this case correctly by snapshotting the current roleNames before
the model is reset. Afterwards, if we detect that roleNames has changed,
we throw the current model set up away and rebuild everything from
scratch – it is unlikely that a more efficient implementation would be
worth it.
Fixes: QTBUG-111987
Pick-to: 6.5 6.2
Change-Id: Id1e3b8e4f983c0f00fc7b30bd4897f1f7fcc3792
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>