The href() and search() functions now return properly encoded search
components.
Tests were added to tst_urlobject.cpp to verify this.
Pick-to: 6.5
Fixes: QTBUG-110454
Change-Id: I3d6485eeeedbd5ba5423cdd42d9c17669ca4bd62
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Previously, setting the search params via the searchParams.set() method
did not change the url's search field. The searchParams object now has a
back pointer to the urlObject it belongs to. Whenever a search param is
set, the url search field is also updated.
The tst_qv4urlobject test was also added to check proper behavior.
Pick-to: 6.5
Task-number: QTBUG-110454
Change-Id: I3b0e843395da8a0e5aedcf71895981f68560d9c6
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
In MouseArea, containsMouse (mouse inside MouseArea) flag is enabled for
press event irrespective of whether its accepted or not. This creates
containsMouse to be enabled always for this corresponding item leaving
no option to reset.
To fix this issue, containsMouse flag is enabled only if the press
event is accepted for mouse handler.
Fixes: QTBUG-110594
Pick-to: 6.4 6.5
Change-Id: Ibb0e89529ccebc3063330c22b8b3501b2917d78f
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
- The Dialog’s implicitWidth is set to the max between the header’s,
footer’s, and background’s implicitWidth. So, when testing that the
dialog’s implicitWidth is equal to that of the header, we should first
make sure that the IW of the background and footer is smaller.
- Wait for all enter transitions to finish before assuming that the
dialog is opened.
Pick-to: 6.4 6.5
Change-Id: I803db9664ad46a83dbe6b47c53448530c30d6150
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
I don't know how to trigger this, but a recent crash report from the CI
shows that we can get there without a valid engine.
Pick-to: 6.5
Change-Id: I9f17894da82b8e7eab88181c96dfa8eaf7795523
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Set QSG_USE_SIMPLE_ANIMATION_DRIVER=1 to get an alternative animation
driver. (applies when using the threaded render loop) This behaves like
the fallback mode (TimerMode) of the other one: it advances based on
whatever delta the QElapsedTimer reports. Thus there is no dependency
on vsync-based throttling whatsoever, and a big chunk of the workaround
infrastructure (such as needing to fall back to QTimer with multiple
windows) is simply not needed.
It should be evaluated going forward if this should become the default.
For now, in order to avoid any surprises, it is only opt-in.
Pick-to: 6.5
Task-number: QTBUG-84328
Change-Id: I8e466caa08ba5f0471d767b1600d198ba787d8e5
Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io>
Reviewed-by: Robert Griebl <robert.griebl@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
In this form we can expose it in QQmlSA.
Pick-to: 6.5
Task-number: QTBUG-110834
Change-Id: Ieb0cf31b6e86379c0d80f89bc6c63b129f269798
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
It breaks unity builds, and declaring metatypes outside of the actual
class that uses them is generally a bad idea.
Pick-to: 6.5
Change-Id: I0106667f6075aabc2fa3c9e5271d21b64f41e4c1
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
The QTranslator was destructed right after it was loaded because it was
inside a scope
Pick-to: 6.5
Change-Id: I8c9d1604652f18f7d15aa7a0045f580cd8a25063
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Triggering quickmousearea test suite generates qml warnings and its due
to change in qt6 qml compiler. These warnings has been fixed in this
patchset.
Pick-to: 6.5
Change-Id: I38ba666c4ae77f1e82292ab748ca3f4bb6f34d63
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Try to explain how the usage of SourceProxy may affect the appearance
of the MultiEffect source item.
Task-number: QTBUG-109555
Pick-to: 6.5
Change-Id: I5ec6fd686aa5c870c163e2ea7e6d56b82008c5ed
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
The snippets showing the use of setContextProperty() are intentionally
removed. You should not do such a thing.
Pick-to: 6.5
Fixes: QTBUG-106030
Change-Id: I1c5c217630aee8dd6e44f9f244b9ef2a8d2ef290
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
When a ShaderEffect did not have any shaders, we would
register a "fake" bindPoint for the 'source' property with
bindPoint 0. However, when actually linking the default
shader program, the actual bindPoint is 1 (also matches
what is in shadereffect.frag).
When the property corresponding to the source updated, we
would thus register an update for binding point 0. The
initial value for binding point 1, from when the shader
effect was loaded, would never be overwritten and when we
iterated over the variables later and tried to cast do a
qobject_cast on the (initial, now dangling) pointer stored
for binding point 1, it would crash.
Pick-to: 6.2 6.4 6.5
Fixes: QTBUG-110111
Change-Id: I96c3e81908db8cce682b5447800fcb7a3fe5e0b9
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Fix the blur items size to next divisible by 16 (like the comment says)
instead of 32. Use QVector4D for colorizationColor and shadowColor so
their alpha is set correctly.
Pick-to: 6.5
Change-Id: I948bdd6c0a792c2fd90a58b69514478f2d965f41
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
Add CustomMultiEffect QQEM project and the effect exported from it into
the MultiEffect testbed example. This can be used to validate the QQEM
MultiEffect node compatibility with the Qt Quick MultiEffect.
Task-number: QTBUG-109740
Pick-to: 6.5
Change-Id: I596bf54316ab70b85b1ace33a433a4109c43b239
Reviewed-by: Kaj Grönholm <kaj.gronholm@qt.io>
QQuickRotation::applyTo(QMatrix4x4 *matrix) uses
QMatrix4x4::projectedRotate() to apply rotation in pseudo-3D.
QQuickFlipablePrivate::updateSide() was previously applying
QQuickRotation to QTransform to decide which side should be showing;
but when using QTransform::map(QPointF) to get the position of the
transformed point, it is affected by the distance-to-plane value.
QMatrix4x4::projectedRotate() uses 1024 as distance from "camera" to
plane; so if the items on the plane are too large, some coordinates on
the plane may be behind the camera during rotation, which could cause
QQuickFlipable to mistakenly think that the current side has become
QQuickFlipable::Back.
Now we directly calculate the side of QQuickFlipable in 3D space rather
than performing projection, to avoid being affected by the camera
distance value. We use QMatrix4x4 instead of QTransform.
Fixes: QTBUG-75954
Pick-to: 6.5 6.4 6.2
Change-Id: Ibb08f6f6de690f5b56c3130a1f7b09beb250c807
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
https://wiki.qt.io/API_Design_Principles#Pointers_vs._References
says we prefer pointers for out-parameters because it's clearer at the
call site that the argument will be modified. Amends
bfb3c424ab
As a drive-by, re-indented nearby internal doc comments.
Change-Id: Id7f377e94e6917185fc26d7ac7c564841d45a257
Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
Reviewed-by: JiDe Zhang <zhangjide@uniontech.com>
If we can't find a member, we don't know whether it's a property.
Pick-to: 6.5
Task-number: QTBUG-110933
Change-Id: Ie7d170f0e1967ac121630afe73e46c514b01e821
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
We use it in three different compile passes, so it should be a member of
QQmlJSCompilePass.
Pick-to: 6.5
Change-Id: Ibc46ceb7ab05839b0a573c8ab3ee2acf4a6de154
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Qmlls was completely implemented in the ./tools directory, which made
its code complicated to test and try out. Also, it required some "dirty"
hacks in the actual tests (including files from others targets to be
able to use them) and made testing new features for qmlls more
complicated.
To remedy this, the qmlls code was split into a tool (qmlls) and
a static library (QmlLSPrivate). The tool only contains
tools/qmlls/qmllanguageservertool.cpp (which has the qmlls main method)
and links to QmlLSPrivate, that contains all the other qmlls-related
code. This way, the tests can also link to QmlLSPrivate and test out
individual functions there without needing to include files from other
targets.
Also rename all the files to make syncqt happy (adding "_p" to headers
and prepending "q" to headers and files and includeguards), and use
QString::fromUtf8() to silence the QString()-constructor deprecation
warnings.
On the way, move tools/shared/qqmltoolingsettings.* into its own private
static library, instead of recompiling it for each tool that requires
it. Move the qqmltoolingsettings stuff into the qt namespace to be
usable.
Also, add qmlls as a dependency to the qmlls tests to avoid testing an
outdated qmlls-binary.
This commit prepares qmlls's code to implement the go-to and
find-usages features.
Task-number: QTBUG-109006
Change-Id: I91eed689c68a0c53fb88006de335b0f852cc1a83
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Restore the --transparent and --multisample options. Also make the
default QSurfaceFormat setting universal (no need to tie it to the
option of forcing a core profile context), and prevent the warning
that is printed when the default surfaceformat is changed after the
application is already created with AA_ShareOpenGLContexts set. This
involves having to handle the relevant arguments manually early on,
not through QCommandLineParser.
All this matches the qmlscene behavior.
NB qmlscene requests 16 samples with --multisample which is completely
pointless in practice. Use the common 4 now.
Change-Id: I671e5f22846a715675ea936bb7cf2a31a849dc28
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
When shaders are generated dynamically, such as with QtQuick3D, cached
shaders may get out of date if the QML file is changed.
Change-Id: I2c5484765e30da5c13fd175a9fcbad2473d55e62
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
They should either be the same size as int/uint or the same size as
longlong/ulonglong, but for some reason we get them as separate types.
Pick-to: 6.5
Fixes: QTBUG-110767
Change-Id: I4c5826cfe6108e6f9722e6b3443bde13b2141b04
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
If you have a loop in your qmldir imports, you get an abhorrent amount
of spam terminating with a misformatted message. Let's limit the total
length of the message and fix the formatting.
Amends commit c7c4c8f088.
Amends commit a0290dcc53.
Pick-to: 6.5
Fixes: QTBUG-110808
Change-Id: I46fa944eacbca456964d1a98fe029f6d550c0a8c
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Those are just as important for modules as for single files.
Pick-to: 6.5
Change-Id: I201d62c61988abc2dfba6300a1cfc355203fec75
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
We only need one line for those. For now we cannot add the version
information because that was forgotten when the qmldir parser was
written.
Pick-to: 6.5
Fixes: QTBUG-110815
Change-Id: Ic922caa6a339a51b905b493e4638ee4d8f737fe6
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
There is no reason why internal types cannot have versions.
Pick-to: 6.5
Task-number: QTBUG-110815
Change-Id: I7fa9790dc64dd785fc08ec7b22f68b4f961fdb00
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Move constant MinimumFlickVelocity to a common header and prefix it
to avoid clashes in static builds.
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: Ic4178a3e7c1ea930a711c4e04f26edda19ad3efb
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Make it a properly prefixed global variable.
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: Ia09072bf6603c3566484f5361b03f1d3a2164be3
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
When using CMake 3.21 use the new builtin command for copying files if
they are different.
On my macbook pro 2019, according to cmake's 3.25 profiling,
qt6_target_qml_sources execution speed goes down from 1072ms to 122ms
when processing the imagine style qml module.
Pick-to: 6.5
Change-Id: I46c51d03bc16cadacb64c011fdf9899a88332052
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Virtual keyboard uses quick text input as shadow input control attached
on top of the keyboard when the actual input control is obscured by the
keyboard. The shadow input is synchronized by the IM update events sent
by the actual input control.
When the user makes selection or moves cursor on the shadow input
control, the change is synchronized to actual input control with input
method event (QInputMethodEvent::Selection). This all works, except
when there is a selection and the cursor is clicked. The expected
outcome is that the selection is cleared, and it is, but it was not
reported back to input method.
Fix the issue by sending the update in case the selection is cleared.
Pick-to: 6.5 6.4
Change-Id: Ieabc9ee97ad9fe6154d46f302314e3ebdfd10de2
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This change just makes the behavior a bit more consistent so that
developers can do things like `stepSize: down.pressed ? downStepSize :
upStepSize`.
Pick-to: 6.5 6.4
Change-Id: I4210f31eaf0e5eda6dc83b369346e16861304fb8
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
This will be a behavior change for anyone who is still relying on
"touchPoints" to be the signal argument rather than the MPTA property;
so let's put it off until Qt 7 and have a reminder in docs in the
meantime.
Fix autotests to avoid depending on this (just as users should).
[ChangeLog][QtQuick][MultiPointTouchArea] As a reminder: you should
always use formal parameters when writing a signal handler that depends
on an argument, such as MultiPointTouchArea.onPressed, onUpdated,
onReleased, or onCanceled. It gives you an opportunity to name the
argument, to avoid confusion with the touchPoints property, and will
avoid behavior changes if we rename the argument in a future version.
Pick-to: 6.5
Fixes: QTBUG-110906
Change-Id: Ie78dc539f7f6cac660f2e90bf3e4665afed3e3f7
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
So that users can see the theme change while the popup is open
Change-Id: I9cac09badc04c5dcace45dadaa9282900b093e17
Pick-to: 6.5
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
If a property cannot be found but there are immediate properties in the
surrounding type, that indicates that the construct in question may be
phrased using generalized grouped properties.
Pick-to: 6.5
Fixes: QTBUG-105251
Change-Id: I107132294ba0ca56ff522fc29e7a1972553390bd
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
You should use the id-based generalized group form.
Pick-to: 6.5
Fixes: QTBUG-105251
Change-Id: I42edfb03059d3e8c92bfb3c311bf1ed1af7cf70e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>