| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We don't build the assembler or the JIT in bootstrap mode.
Change-Id: Idc3a56cc1e9cfba415bef9cba221c8a60ee75010
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We don't need it to build the IR and we can drop a few checks for
V4_BOOTSTRAP this way.
Change-Id: I9464e65528c70c42ebc8ddad576eaab001dc9d2f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The "early" compilation doesn't use it and we can get rid of a few
V4_BOOTSTRAP checks this way.
Change-Id: I1c4845aba445b105ddace0b6810e0e5c28a25b29
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I778cfe842ddf1c600a837d8f2061a338887eed95
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Since different tables can have different sized
models, it can also happen, as the views are being flicked
around, that some views temporarily end up with no
visible rows and columns in the viewport. When that
happens, we continually check if the columns should
become visible again, and if so, schedule a rebuild.
Change-Id: Ic84e47fd5d7968c1f1408eb122e38fa841e7aec7
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The table and object models should be configurable, too, and Package
conceptually belongs to the delegate model.
Change-Id: Id928f14c5b378b6e7ffcbb98039192fa7c375fa7
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\ \ \
| | | |
| | | |
| | | | |
refs/staging/dev
|
| |\| |
| | | |
| | | |
| | | | |
Change-Id: I662790341c4b1ee816b0639067fe3f0e38a002b4
|
| | |\|
| | | |
| | | |
| | | | |
Change-Id: Ic10f47e4763d67d989df77f2dc11d9705ec7fb6b
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Otherwise it gets a separate address for each CU in which the template
is instantiated. We want to use the address as key to the attached
properties, though.
Fixes: QTBUG-75385
Change-Id: Iaec82db116a032f7cb1d40670bb47fdf610664a2
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
content view
Calling the base class implementation of fixup might move the content
view and start animations etc, which will cause glitches. So ensure
we don't do this when we adjust the content size internally.
Change-Id: I214a6ae2da0c21fd733ea884bccb5e77fc554615
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|/ / /
| | |
| | |
| | |
| | | |
Change-Id: Ib2f195780415836ebb03c151a6586fd7b0fb77b8
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The model types are not part of the core QML runtime and should only be
loaded if you explicitly import them. We cannot enforce that in Qt5 as
some of them are available from the QtQml import, but we can change it
in Qt6.
Change-Id: I1e49e84d748e352537ec2d4af901c034c91d038f
Reviewed-by: Erik Verbruggen <erik.verbruggen@me.com>
|
|\| |
| | |
| | |
| | | |
Change-Id: I5d2c3da38df35922b2147c3c0bc55c6c3bae2fe5
|
| |\|
| | |
| | |
| | | |
Change-Id: Ic008bf9223a9ac293c925044355ff218f7ed7f78
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Nobody needs those and we run into integer overflows later on if we
accept them.
Fixes: QTBUG-74048
Change-Id: Ib8ccd05e4bd6f662c38fbe95bf1350f81982e1b8
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Only the call context contains the signal parameters. However, there can
be any number of nested block contexts in a function. This manifests
itself when the function needs an execution context. The simplest way to
trigger this is attaching a debugger.
Fixes: QTBUG-75393
Change-Id: Iabdc06a9fe7bf88204525d6940b626575fee1579
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Commit bc00353cffbfe0f74b602a16452f2e7bcd588152 accidentally removed the
assert that expressed how objectForId will always succeed with the alias
target. That caused coverity to complain that objectAt() may be called
with a negative (then array) index.
Change-Id: I8651e0826c92e41ab00bf8a44f1abfd1cbfb0e06
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
For clang we need to use has_feature to detect the presence of an ASAN
build. Amends commit eb363c3a0b7f96015d7b8f2551dbeaa86f5acf16
Task-number: QTBUG-75410
Change-Id: I2adb69deb07f8c6b77be8c2f23751fd0a2bbdb95
Reviewed-by: Erik Verbruggen <erik.verbruggen@me.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
qCInfo is enabled by default, so this turns into noise for users.
Task-number: QTBUG-70083
Change-Id: Ie7f50d393055846bd2f9935c2bbe72830b1b24a3
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Enable by -Wextra in gcc 9.
Change-Id: I6642240f7ff9fe9f5fc6a456b66d86c9591eaf5f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Add an atomic isInterrupted flag to BaseEngine and check that in
addition to the hasException flag on checkException(). Add some more
exception checks to cover all possible infinite loops. Also, remove the
writeBarrierActive member from QV4::EngineBase. It isn't used.
Fixes: QTBUG-49080
Change-Id: I86b3114e3e61aff3e5eb9b020749a908ed801c2b
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Used to store columnWidths and rowHeights.
Change-Id: Id66fba9de05afa2c4df15761fb004b4f046fe103
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Make it completely inline, move the (4 times duplicated) primeForNumBits
function into its own file, address some warnings, move
QHashedString::compare into qhashedstring.cpp.
Change-Id: I778bb3d3e176cfec45eda9be9d7e5982585e6474
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Task-number: QTBUG-75176
Change-Id: I969e7987ebf8b98aed9ba9e17388a0e168ef5e09
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Qt Labs Animation requires Qt Quick, but was unconditionally built
even when Qt Quick was not present.
Change-Id: Idf5093574e409e91b7a662f41f18101907746c6a
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If you put two tables inside an async loader, with one being
the syncView for the other, the syncView child will start
loading items async simultaneously with the syncView.
This is unnecessary, and steals loading resources, since
the child will have to rebuild anyway once the syncView has
completed loading. So return early from the recursiveUpdateTable
call before handling the children if we detect that the parent
is not done.
Change-Id: I8c0badaf3cfa3a353a650e5f38f381bf9a7b98f9
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The tracing JIT won't be finished. Therefore, remove the parts that have
already been integrated.
Change-Id: If72036be904bd7fc17ba9bcba0a317f8ed6cb30d
Reviewed-by: Erik Verbruggen <erik.verbruggen@me.com>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/compiler/qv4compilercontext.cpp
src/qml/qml/qqmlmetatype.cpp
Change-Id: I02e0216961b92ff68a3f91a70edc33fe9e8db147
|
| |\|
| | |
| | |
| | | |
Change-Id: I552629813ea8100d04ea19e51fe7198931082e19
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In handlePointerEventImpl, there is the call
d->centroid.reset(d->currentPoints);
with the expectation that currentPoints is not empty. But we weren't
populating it in case of a native gesture.
It still ends up being empty at the end of the gesture, but it's
normal to return false from wantsPointerEvent() when there are no
eligible points.
Fixes: QTBUG-70083
Change-Id: I12ca6460a24d2eb6c44a639f83ce3ff17eb37613
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
I don't see any reason why this should be prohibited.
Change-Id: I4a54c55eff4b9151691d0587627efad4a06485f1
Fixes: QTBUG-74815
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
That is rather confusing.
Task-number: QTBUG-74815
Change-Id: Id683a7f9efd63c8859c5740ceab9f161cea46ee3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
ASAN enabled builds require more stack space and therefore our call
depth limits should be lower.
In my measurements with a recursion through arrow functions with the
interpreter, as per the test case in the bug report, different types of
builds require different amounts of stack space. On x86-64 Linux, I
measured, by printing $rsp and subtracting:
Debug: ~6k
Debug with -Og: ~590 bytes
Release with -O2: ~570 bytes
Release (-O2) with ASAN: ~40k
Fixes: QTBUG-75410
Change-Id: I403b261c677b1adb9f349958339b5a1294ae4d5d
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Fix crash when QQmlMetaType::freeUnusedTypesAndCaches() is being called
during program exit, i.e. when the parent QJSEngine instance is being
destructed during exit().
Sample backtrace:
#0 QQmlMetaType::freeUnusedTypesAndCaches () at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/qml/qqmlmetatype.cpp:2600
#1 0x00007fffe12fce83 in QJSEnginePrivate::~QJSEnginePrivate (this=0x60c001c0b040, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:982
#2 0x00007fffe12fce9f in QJSEnginePrivate::~QJSEnginePrivate (this=0x60c001c0b040, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:980
#3 0x00007ffff53650c3 in QScopedPointerDeleter<QObjectData>::cleanup (pointer=<optimized out>) at ../../include/QtCore/../../../../../src/qt5.12/qtbase/src/corelib/tools/qscopedpointer.h:52
#4 QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::~QScopedPointer (this=0x60300178b3a8, __in_chrg=<optimized out>) at ../../include/QtCore/../../../../../src/qt5.12/qtbase/src/corelib/tools/qscopedpointer.h:107
#5 QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:891
#6 0x00007fffe12ff572 in QJSEngine::~QJSEngine (this=0x60300178b3a0, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:379
#7 0x00007fffe12ff583 in QJSEngine::~QJSEngine (this=0x60300178b3a0, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:375
#8 0x00007ffff5363cc4 in QObjectPrivate::deleteChildren (this=this@entry=0x60b00016c380) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:2010
#9 0x00007ffff53650f5 in QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:1032
#10 0x00007fffe103b43b in Grantlee::ScriptableTagLibrary::~ScriptableTagLibrary (this=0x607000ba4c00) at templates/lib/Grantlee_Templates_autogen/MTDBPGIEEV/../../../../../../../src/kf5/grantlee/templates/scriptabletags/scriptabletags.h:58
#11 0x00007fffe103b469 in Grantlee::ScriptableTagLibrary::~ScriptableTagLibrary (this=0x607000ba4c00) at templates/lib/Grantlee_Templates_autogen/MTDBPGIEEV/../../../../../../../src/kf5/grantlee/templates/scriptabletags/scriptabletags.h:58
#12 0x00007ffff5363cc4 in QObjectPrivate::deleteChildren (this=this@entry=0x60b00016c0c0) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:2010
#13 0x00007ffff53650f5 in QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:1032
#14 0x00007fffe0fef704 in Grantlee::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantlee/templates/lib/engine.cpp:60
#15 0x00007fffdf2e2482 in GrantleeTheme::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantleetheme/src/grantleethemeengine.cpp:54
#16 0x00007fffdf2e24a9 in GrantleeTheme::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantleetheme/src/grantleethemeengine.cpp:52
#17 0x00007ffff3f4f8d1 in MessageViewer::MessagePartRendererManager::~MessagePartRendererManager (this=0x7ffff40c8ab0 <MessageViewer::MessagePartRendererManager::self()::s_self>) at /home/kfunk/devel/src/kf5/messagelib/messageviewer/src/messagepartthemes/default
/messagepartrenderermanager.cpp:118
#18 0x00007ffff4b442ac in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#19 0x00007ffff4b443da in exit () from /lib/x86_64-linux-gnu/libc.so.6
Also see:
https://bugs.kde.org/show_bug.cgi?id=406871
Change-Id: If5676880c87f1fa2405701a439e1a0037dce045c
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
"hasTry" doesn't exist.
Change-Id: Ia6df66406e296c7623fa872ef32acc46d93b3319
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
|
| |\|
| | |
| | |
| | | |
Change-Id: I2fea101de38922d34088c6eca0e256ec167ad118
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This reverts commit 2beb77c81a1f3585c15099a09ba8b2192c6da824.
To optimize lookup in case of heapObject we cast its value to Object.
This unfortunately does not work well when the value type of heap object
is actually a string.
Task-number: QTBUG-75335
Change-Id: I55d7c9e0d41f3be617ca7141a4121de3a56f8eef
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Store PointVelocityData by value in the QMap to avoid leaking memory.
This also appears to be slightly faster than heap allocation, with
the struct being relatively small (24 or 32 bytes depending on qreal).
Fixes: QTBUG-73182
Change-Id: Ibd9374746b76fd5b78c23283d278b6af42907c96
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This warning is generated from a statically called ctor. At that point
the system facilities to run QMessageLogger may not be in place, yet. In
addition, we actually don't want the message to go through the regular
QMessageLogger redirection and possibly filtering. The message should
always be shown.
Fixes: QTBUG-73217
Change-Id: Ief192dae8c38d5d94996ee9285e54b5cbd714f4b
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
(cherry-picked from commit 15525d2a309a6028d548797bc777e38905f36c46)
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
It can be used to change any qreal property of its target Item in
response to wheel rotation, or it can be used in other ways that involve
bindings but without a target item.
[ChangeLog][QtQuick][Event Handlers] Added WheelHandler, which handles
mouse wheel rotation by modifying arbitrary Item properties.
Fixes: QTBUG-68119
Change-Id: I247e2325ee993cc1b91a47fbd6c4ba0ffde7ad49
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
[ChangeLog][Qt Labs Animation] Added the BoundaryRule QML type, a
PropertyValueInterceptor that restricts the range of values a numeric
property can have, applies "resistance" when the value is overshooting,
and provides the ability to animate it back within range.
Change-Id: I677b407a351c12b0c5b23c34a45933154310c2cd
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
calculateTopLeft() takes care of finding which cell should be
the 'corner stone' that needs to be loaded first when doing
a rebuild. When we have a syncView, the top left cell should
match the top left cell of the syncView, so the logic needs
to change quite a bit to take this into account.
Change-Id: Ia0b621a3155bbd113fa37c2ed585f16627d46443
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Location::line is 20 bits, so assigning it to a 16 unsigned integer
truncates the number unnecessarily.
Change-Id: I50a7ec73d6a88505c7d41b5a2b7ceb726b9dd437
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Now that several table views can stay in sync through the
syncView parent-child chain, we also need to ensure that the
position of the content views stays in sync. This patch will
recursively go through all connected views when one of the
views are moved and set the same position on them all according
to the syncDirection flag.
Change-Id: I5a5b8e795426484eeab3771f6c8d4c9b7da046eb
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This way you can enable or disable the JIT when configuring Qt. The
conditions for the availability of the JIT have also been cleaned up.
There is no reason anymore to artificially restrict availability on x86
and x86_64. The reason for the existence of those clauses are old
problems on windows that have been fixed by now. However, on arm and
arm64, we need a specialization of the cacheFlush() function for each OS
to be supported. Therefore, restrict to the systems for which such a
specialization exists. iOS and tvOS are technically supported and you
can enable the JIT via the feature flag now. Due to Apple's policy we
disable it by default, though.
Change-Id: I5fe2a2bf6799b2d11b7ae7c7a85962bcbf44f919
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Now that a TableView can be inside a syncView hierarchy, we
cannot update a table in isolation, but need to coordinate
this with the other views. It's especially important that
we update a parent syncView before a child syncView, to
ensure that the parent has calculated all the necessary
columns width and row heights. For that reason, we always
update the table views starting from the top.
Change-Id: Iba8ae7d28fa0bb2fbbad9f8fc7aa198e15b91872
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Ensure that properties that has to do with the layout
stays in sync with the syncView. This is currently
rowSpacing, columnSpacing, rowHeight, columnWidth,
contentWidth and contentHeight.
Change-Id: I5af29d7be6c30cefbfa7d2353f53359907c9405b
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
- Make two sub-sections: C++ and QML
- Add a TableModel example to the QML section
Change-Id: Ib391b4c0a78e11f5130944b6ac99e20a5982a453
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Singleton object instances were previously managed by
QQmlType::SingletonInstanceInfo and kept in a shared storage. This caused
concurrency problems when instantiating singleton instances from different
QML engines in different threads.
This patch moves the singleton house-keeping infrastructure to
QQmlEnginePrivate and makes SingletonInstanceInfo immutable.
Singleton objects are stored in a QHash with QQmlType as the key because
the qml type id might be 0 for composite singletons. The public API of
QQmlType is extended to provide more information about singleton types so that
access to SingletonInstanceInfo is not needed.
All internal accesses of singleton objects must now take the same code path via
QQmlEnginePrivate::singletonInstance<T>() which simplifies overall usage of
singletons and scatters less implementation details throughout the code base.
Task-number: QTBUG-75007
Change-Id: I13c5fd21cac2eb7291f2cbcf2c2b504f0f51a07c
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|