| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| |
| |
| | |
tqtc/lts-5.15-opensource
Change-Id: I49d3f2094eee9709c4cd68433047dfad0c3414fa
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Including moc files directly into their classes' TU tends to improve
codegen and enables extended compiler warnings, e.g. about unused
private functions or fields.
Manual conflict resolutions:
- dropped all inclusions into non-existing files
Task-number: QTBUG-102948
Change-Id: I080e266e1a23f03efd4acdf48fa51a555429ceac
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
(cherry picked from commit 69f7039ada381591f751d1e213c94d48307657a1)
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\|
| |
| |
| |
| |
| | |
tqtc/lts-5.15-opensource
Change-Id: I91d2b178e7111d0802ea973bccf230b264c30c96
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In QQmlAdaptorModel, we were using QQmlStrongJSQObjectReference to
ensure that a passed in model lives long enough. However,
QQmlAdaptorModel uses reparenting to keep objects alive. This is not
safe, as we can use QML singletons as models.
Reparenting singletons messes with the engine's lifetime handling once
their new parent gets deleted: The object will be marked as
queuedForDeletion by QQmlData::markAsDeleted; consequently wasDeleted
returns true for the object, and any ScopedObject or ObjectWrapper will
return nullptr when we try to retrieve their underlying QObject.
The actual object probaly does not get deleted, as it is not placed in
the QML heap. Consequently the gc will ignore it.
This leads to a crash when the singleton is accessed in a different
place: We see that the object is non-null, create a ScopedObject for it,
and then try to later access the ScopedObject's underlying object
(assuming that it must be non-null, because we already checked for the
actual object being non-null). However, due to the reasons outlined
above, we actually receive a null pointer, and thus encounter a crash.
To avoid he issue, we change the lifetime management strategy: Instead
of using the parent to keep the object alive, we now use a
QV4::PersistentValue.
Fixes: QTBUG-100260
Change-Id: I266e6ef94c4f079de3da2742d6fb8d61df5a64ce
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 6901eacff40a7d8781e20fb5bcfd28d7526b589b)
(cherry picked from commit ce8db0672557cef7942df061f52ccdf65fa250f6)
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
I was running into a crash (it didn't reproduce with a minimal example,
and I'm still not sure exactly what caused it) related to models and
views, and saw that there m_count was negative, which shouldn't be
possible. Adding this new assertion allowed me to find the issue in my
code.
Change-Id: Ie467e749dbf95799618bd04591e50b0038cf3399
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
(cherry picked from commit d70b4ab2e58bcfd5e65c1d11a79020bb3e2906c0)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|\|
| |
| |
| |
| |
| | |
tqtc/lts-5.15-opensource
Change-Id: Ic3ca76460360cbab866a4e881c4848e6deeaf7d7
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We need to set the set the contextObject already in
QQmlDelegateModelPrivate::object, as the context property might be
accessed in a child component before we are able to run
setRequiredProperties (which would set-up the context in case there are
no required properties).
Instead of delaying setting the context object, we clear it now in
setRequiredProperties.
This has the drawback that one might be able to access context
properties on initial component setup which should not exist
(due to the presence of required properties).
This could be avoided by inspecting the Compilation Unit and only
setting the context if we do not find required properties, however that
needs further work to expose the necessary information.
Fixes: QTBUG-94223
Change-Id: I678de81408539417fc650f94da4c9f0d3167653d
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
(cherry picked from commit 58cd06033cacadab541efaa16a3eecec37dab0fa)
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
|
|\|
| |
| |
| |
| |
| | |
tqtc/lts-5.15-opensource
Change-Id: I5e0eef69a31bcfda65cf965fb4c8c330581e5168
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When removing items from groups actively shown by a model filter a warning
and assert was triggered in the past. This change fixes this behavior.
Fixes: QTBUG-86017
Change-Id: I49b7498a3d03141b654e453a3c35a43fc7ba804a
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 8a3ede5ba1daf2d9314d71db972175b2791456c0)
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|\|
| |
| |
| |
| |
| | |
tqtc/lts-5.15-opensource
Change-Id: I39595f8b7ad212c842709b939226d95531819391
|
| |
| |
| |
| |
| |
| |
| |
| | |
Task-number: QTBUG-91276
Change-Id: I1ddbb4a3326d61ff94e3881beb64a14dade11c46
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 31ad81d81e623a34cd71567b9507f16601f1c1d4)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|/
|
|
|
|
|
|
|
|
|
| |
This reverts commit 7b1331c789df0ac12d7cf5aa5f8967b8651a4cfa.
Revert of commercial license headers is required for Qt 5.15.3
opensource release.
Task-number: QTBUG-91108
Change-Id: I47eb004523bdb3beb16e9fd51e40da6f738f9f34
Reviewed-by: Jukka Jokiniva <jukka.jokiniva@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Commit 37fcffa035d55ac00f85f57ce1390fff3be213c6 fixed the issue for
remove rows, but it can also happen with model reset.
Fixes: QTBUG-83352
Change-Id: I0ec1a67e822e4f8fe5b8f87f38dfae1f26b3fab5
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit d99d192884608408759492bd656ab99a2f4f23ed)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Updated header.COMM to the files in tqtc-qtdeclarative.
Examples, documentation files or tests are not updated.
The commercial license header may contain some
additional lines so that its line count equals with
the earlier license header. Reason for this is that
some autotests use hard coded line numbers and a
change in the line count causes failures in tests.
Task-number: QTQAINFRA-4161
Change-Id: Ic1d011aa01b1fe7242bcbbf72d5ab454d1015cf9
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The delegate items are destroyed through an event loop by a call to a
deleteLater(). This, however, doesn't work when the application is
in the process of exiting and the event loop is already closed (i.e.
we're in a stack unwinding part that starts after app.exec())
Combat this situation by setting a parent of the to-be-deleted object
to some QObject that will be destroyed e.g. QCoreApplication::instance()
before the program finishes. As QObjects clean their children on
destruction, this will make sure that we cleanup the previously leaking
thing regardless of the event loop
Added a test to check that delegates are destroyed (as a separate binary
due to differences in main() function)
Fixes: QTBUG-87228
Change-Id: I59066603b77497fe4fd8d051798c3e4b47c119f0
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit 3a5617dc45e281552b9c1f7a04f0561b8fa14d94)
|
|
|
|
|
|
|
|
|
| |
The previous description had an awkward structure and was duplicated.
Change-Id: I46dbc804e1c907198364f441fd46eb853db97e6a
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
(cherry picked from commit 3cf3434c1a898c834b2f0f6182068bbf8a95b9bc)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
DelegateModel.inItems and DelegateModel.inPersistedItems were
wrongfully documented as of type int, when they are bool. This
patch corrects that. Reflow long lines as clang-format complains..
Fixes: QTBUG-86031
Change-Id: I4dee919b7008b5d3b2f492ed894891ac164a1217
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
(cherry picked from commit 06b3d7ceb732588633e51e6580675b2a2595fe8d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Delegate items can be deleted when remove them from cache list. That may
cause a crash. So call referenceObject to keep the item from being
deleted.
Task-number: QTBUG-83352
Change-Id: Id5d7ab6dbf21682940f5393ea4e843c2448f7d81
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 37fcffa035d55ac00f85f57ce1390fff3be213c6)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
| |
Change-Id: I0117029ecbe7fc369c15fcd8a44f93797e95ab3e
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
If the context is gone, we assume that the object is
currently torn down. Therefore we do not print an error
message in that case.
Fixes: QTBUG-82809
Change-Id: I74e5a4f41490ea9c13639c158a4d5fc0a52a38a4
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
| |
It is actually not needed, and declining to cancel the incubation leaks
memory.
Change-Id: I478ed2a4eef34bd27c716762a2fced1e9091607c
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
This fixes the memory leaks from the "x items in the process of being
created at engine destruction" situation.
Change-Id: I65fe278ead3d4de0cbddc075972a6774b231814f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
QDoc will generate these notes automatically.
Task-number: QTBUG-37355
Change-Id: I8ed058ecbbcc630ad0351f6ce167c3fa61936f6f
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
The iterator may be invalidated by addCacheItem(). We can retrieve the
relevant properties before, though.
Change-Id: Ia3bbc50d16a7563097239177a75c9e2eab777a33
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
| |
Task-number: QTBUG-79263
Change-Id: If518f644b5b9eddbacfb1cb16fbb557127ffcfb2
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
| |
Consistently store it in QQmlRefPointer so that it doesn't leak.
Change-Id: Id1f06228f6eb477b758901d61c1b71928671dc6a
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
as type is going to be deprecated.
This change was done automatically with the help of clazy.
In addition, ColumnRoleMetadata was changed to take an int instead
of a QVariant::Type
Change-Id: Ibc02d7b52e7d931a56c19fdebc4788b5e6df2a39
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
|
| |
Since insertMulti is going away
Change-Id: I1ad91f3788648b807cb09f54e54ddce39c6ce06a
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Take the shared reuse pool into use, and implement delegate
item recycling in QQmlDelegateModel. The implementation is
more or less a copy of the strategy followed in
QQmlTableInstanceModel.
Change-Id: I80953ec617f586774a240e7c6790b7777e7b64b8
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
| |
Factor out the reuse pool logic in TableInstanceModel into a
separate class, so that we can share it with the upcoming implementation
for recycling items in QQmlDelegateModel.
Change-Id: If8f700b7a0208bac7d1cb1de087792e2c3a9b512
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
| |
If we have a proxyObject, we need to use that one for reading proxy
values. Otherwise the read operation will crash.
Fixes: QTBUG-80420
Change-Id: I88cd5499802bff1aea2e43da9ab61d6565ab7ede
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|\
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/qml/qmldirparser/qqmldirparser.cpp
src/qml/qmldirparser/qqmldirparser_p.h
Change-Id: Ia68a8d4f345e6e456eebc3f215fc90d3819ddd70
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The raw index doesn't take the filter group into account.
Fixes: QTBUG-78297
Change-Id: Ie6514c8acdc380fe3f8f267d02335afc357abd17
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Joshua GPBeta <studiocghibli@gmail.com>
|
| |
| |
| |
| |
| |
| |
| | |
Amends 744e77b841878fb017c0f2d60607090008f28180.
Change-Id: I16e37aaf503eb62f67fca0e48be4c92c4a72ae46
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Otherwise we would set the same object as extraObject and as
contextObject. That spells trouble when tearing down the context.
Fixes: QTBUG-79958
Change-Id: I97fd0bf111304d06cff35eda46d4b4c6eefdaccc
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It is being deprecated.
Change-Id: I844bd92af85bc53a8fc0371408d05277bd49f511
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/qml/qml/qqmlextensionplugin.cpp
tests/auto/quick/qquicktableview/tst_qquicktableview.cpp
Change-Id: Ic58d36a8532015bae30f2690063db9829b3bf372
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When reusing a delegate item, it can sometimes happen that the item
ends up being reused at the same location in the table as it had
before it was pooled. And in that case, we don't emit changes to
index, row and column since they technically didn't change.
The problem is that the model might have changed in-between, e.g if
a row has been removed. And in that case, row and column will, even
when unchanged, point to other parts of the model. So all bindings
needs to be reevaluated to ensure that the values they use are
refreshed.
This patch will therefore ensure that we always emit changes to
the mentioned properties when an item is reused, regardless if
they change or not.
Fixes: QTBUG-79209
Change-Id: Icec201a43a30b9f677303fbf652baf6487621deb
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| | |
We want to have only one import URI per library.
Change-Id: I8be524cf361b12bcb423c9efccd4e047ae3d8d0e
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\|
| |
| |
| | |
Change-Id: I2835748c27616103f275849141fbe5a93e3dfd8c
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It looked a bit odd that the DelegateModel delegate property was not a
notifying property. Adding the delegateChanged signal makes it easier
to update the view when this happens. The previous approach of removing
all delegates and adding all new ones resulted in the view losing its
currentIndex and often scrolling to a different place. It's also nice
to reduce the number of d-> indirections by adding the
QQuickItemViewPrivate::applyDelegateChange() function, so that we just
need one indirection to call it, and then it updates all the internal
stuff in one place.
Done-with: Frederik Gladhorn
Done-with: Joni Poikelin
Fixes: QTBUG-63477
Change-Id: I2d17fd11ff4a2fcb20968a7182dd2c403abb715a
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/imports/qtquick2/plugins.qmltypes
src/quick/items/qquickitemsmodule.cpp
Change-Id: I841c65c9c131354788b4f3fcfe3d7ed27be316d5
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/qml/jsruntime/qv4engine.cpp
src/quick/handlers/qquicktaphandler.cpp
src/quick/items/qquicktableview.cpp
Done-With: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Done-With: Ulf Hermann <ulf.hermann@qt.io>
Done-With: Shawn Rutledge <shawn.rutledge@qt.io>
Change-Id: If9558a33f01693ce96420c094e0b57dfff0626cd
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
With required properties, we do not store the cache item as a context
object anymore. To fix this, we repurpose the (space of the) incubator
pointer of QQmlContextData to store the element there, and one of the
dummy bits as a flag to indicate the new usage.
Change-Id: I7cc435fc6781c603fe407411a60a6018239c972c
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This mirrors the behavior in other parts of QML where writing to a
property in imperative code breaks the binding.
Change-Id: Id19eef17a3c5e77bc4c2772bd749b38c732606a8
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a delegates declares a required property of a given name, and that
name exists as a role in the model, we set the property accordingly.
The same holds true for the special properties that come from the
QQmlDelegateModel like "index" and "model".
All roles are still injected into scope and thus accessible;
changing this in Qt5 would be tedious or even impossible while still
maintaining backwardscompatibility with delegates that do not use
required properties.
Change-Id: I4f388ba549c42f1ff9822bdb3b8357c4d45e4b66
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
| |
Conflicts:
.qmake.conf
Change-Id: I20ad6f8a260f387a3b73566a32c35a5772b401a5
|
|
|
|
|
|
|
| |
Conflicts:
tests/auto/qml/qjsengine/tst_qjsengine.cpp
Change-Id: I34df194046a91ee8a076ce28022eb99d68e7f362
|
|
|
|
|
| |
Change-Id: I59f738402d51e39188bbbca2ef1fbc8a61612372
Reviewed-by: Simon Hausmann <simon.hausmann@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>
|