| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
Retrieving the QQmlValueType is expensive and there is not a single
place where we need anything but its QMetaObject. Retrieving only the
meta object, on the other hand, is cheap.
Change-Id: I3ad5574d64f1f67a4d4cf2886dc5c396e99ec91a
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
| |
This is where it belongs. We need to apply some tricks to avoid
cyclic includes, but that's better than what we have so far.
Also, sort and clean up the includes in the affected files.
Change-Id: Ia7a957d06c0ca284045d831417740c3f9920bc92
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A QML module might not actually contain any QML files at all (in case of
a pure C++ module). In such a case, we so far ended up with
QT_QML_MODULE_QML_FILES being set to "-NOTOUND", which later is
problematic for qt_query_qml_module.
We already have code in place to cover that issue for some variables,
just not for QML_FILES. The code is now amended to handle it, too.
Moreover, the code block is moved to the end of the function. This
ensures that the code for setting a variable always comes before the
code ensuring that it is set – which would not have been the case for
QML_FILES if it had stayed at its old position.
Pick-to: 6.5
Task-number: QTBUG-111946
Change-Id: Ib4501bb4a617b2174ad89e116588aa51353cb17f
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
| |
The named builtins include void and regexp. The optimizations for other
types are useful, but should be a separate enum.
Change-Id: I06220cf4a6d3449deca89a26c4f5db0e41d32765
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
Q_ENUMS() is deprecated in favor of Q_ENUM().
Pick-to: 6.5
Task-number: QTBUG-113229
Change-Id: If562e50a88ff04d02be0aa10c975e0af84d90e44
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
PAST_MAJOR_VERSIONS, PLUGIN_TARGET, NO_CREATE_PLUGIN_TARGET, and
CLASS_NAME are documented and elsewhere in the documentation we
try to link to them, but they were missing a \target.
Also, fix a link to QT_QML_SOURCE_TYPENAME.
Pick-to: 6.5
Change-Id: I74ff0de558d1f43b739f64a4bab19863f8be34cb
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Amends commit a7c92814f0ff6e9253c781b90e70ad645f8cd94e.
Change-Id: I0568298aaa696036b5115f4e93ddeb1cf90c76a3
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Mike Trahearn <mtrahearn@topcon.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When calling the QQmlV4Function overload of createObject() we end up in
a different code path. The problem is the same, though.
Amends commit ef6e9f6b75848dfdacdd98cf9e7530f651b3dfca.
Pick-to: 6.5
Task-number: QTBUG-99363
Change-Id: I6341243b75d9db1e0fcb80d8d73dab6932d85fd2
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
Outdated documention has been removed.
Task-number: QTBUG-111036
Change-Id: I8db138ff71615a6ed6ac4cebdb365c27252fa5ee
Pick-to: 6.5
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Our value type refactoring in 6.5 broke reset support for value types
when that write happens through virtualPut.
Fix that by checking whether the value we're assinging is undefined
before attempting any conversion, and reset the gadget in that case (if
it is actually resettable).
Task-number: QTBUG-113473
Pick-to: 6.5
Change-Id: Ifaa2d045f718fc3cb2d5e75b3626b41175ac3a3b
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These APIs started out as private APIs in qnumeric_p.h, but have since
been made pseudo-public in qnumeric.h. The qnumeric_p.h versions just
forward to the qnumeric.h ones, so just use the latter.
This is in preparation of removing the {add,sub,mul}_overflow
versions, which, despite being defined in the unnamed namespace, don't
sport the q prefix, so potentially clash with global symbols.
The change is a simple textual search and replace.
Picking to 6.5 to avoid cherry-pick conflicts going forward.
Pick-to: 6.5
Change-Id: I2525619c14cb8eeadd08e2fa6c35968bcedd5171
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the methodCount is 0, the methods have to be nullptr. Otherwise they
have to point to the actual method(s). This is important for the method
resolution to work correctly.
In particular when cloning a method we have to check for 0.
Amends commit 17bd07cbc5b6cf54716e991765ab3088a710d7b3.
Pick-to: 6.5
Fixes: QTBUG-113484
Change-Id: Ic31d6e391c1d74a162820232f242a19379f5e4df
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
|
|
|
|
|
|
| |
It would be very, very bad if that assumption was violated.
Change-Id: I0ae7391a8df93450fc881a937c5365c57c58277f
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We don't have to pass types that don't fit if we actually have the
correct types in suitable wrappers.
This still invokes the internal conversions of the call frame setup if
we call with really generic types, for example if the same value is read
multiple times with different target types. However, that is acceptable.
Fixes: QTBUG-113465
Change-Id: I8ec4afeb39bbe6585e5268c0e9b0cfd2788d761a
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
When we're assigning a QJSValue to a value type property, we must first
check whether it is a binding created by Qt.binding. In that case, we
should directly set that binding up. Going through the conversion code
path might not necessarily fail, but might instead yield nonsense.
Pick-to: 6.5
Fixes: QTBUG-113472
Change-Id: If91e0843f0caf36c96b4c811b9ce8076adfc984f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The meaning of the feature has changed and tools that depends on this
feature now need to be built unconditionally. So the feature should be
removed to avoid confusing users.
[ChangeLog][QtQml][Tools] The 'qml-devtools' feature is removed. All
tools that depend on this feature are mandatory and need to be build
unconditionally.
Fixes: QTBUG-113221
Pick-to: 6.5
Change-Id: Ia026684703d847ce777d7a2916f04b3c90727695
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
a, Teach QV4::QObjectWrapper how to convert QQmlListProperty to
QObjectList.
b, Parse the isList attribute from qmltypes.
c, Resolve lists when resolving QQmlJSScope.
Change-Id: I70c6d40507de990b45a87eb7d8c7bba279d550e8
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This way we can identify which entry in a stack frame to amend when
processing an exception in generated code. However, negative line
numbers are also used to signal the position of "Ret" instructions.
Since you cannot throw an exception from a "Ret" instruction, those
cannot collide, but we cannot qAbs() the line number anymore when saving
it in the stack trace. We have to qAbs() it in all the places where it's
read.
Pick-to: 6.5
Fixes: QTBUG-112946
Change-Id: I24dc4008fb7eab38e4d24e70211c22e46f1b72a7
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
| |
Pick-to: 6.5
Fixes: QTBUG-112291
Change-Id: Idd47ea8daf9c54759af6c1feba68bd52d1163615
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
This is likely to lose some properties.
Pick-to: 6.5
Fixes: QTBUG-106266
Change-Id: Ib5a2567d61635a5cf7b3abee7cfef0c073d59e63
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The warning C4018: '<': signed/unsigned mismatch appears in a Q_ASSERT
when checking a lookup index against the size of the container.
Fixed by changing from unsigned to signed type for the index. Since the
index is already implicitly converted to signed type when used, we can
use a signed type from the start. We rely on implicit conversion from
unsigned instead of static_cast to not hide other warnings in the
future.
Change-Id: I2b1983bdd40104e2c7135eec849a198ac074517c
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
|
| |
Pick-to: 6.2 6.5
Fixes: QTBUG-99363
Change-Id: I2c731ec0b8c5947192accdeb5ef52903d9c7cd90
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
| |
There are more bindings kinds around.
Fixes: QTBUG-113353
Change-Id: If545f56bd61c238431883be3eb013841d96b18bb
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
Fix spelling and remove QGraphicsItem::ItemHasNoContents reference.
Pick-to: 6.5
Task-number: QTBUG-111033
Change-Id: I9564fa1bb4eb1af786078d1909a3ad8268dfe290
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of accepting the inconsistency between interpreter and compiled
code here, we can just detect whether a value can be affected by side
effects and refrain from reading it then. Since you can always
explicitly reload a value that may have been changed, the resulting
compile warnings are easily worked around in user code. Refactoring user
code this way also makes it much clearer what is actually going on.
Pick-to: 6.5
Task-number: QTBUG-109221
Change-Id: Ica832e39838ef732b0d181364630737fd7709b74
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
We can just use calloc and zero-initialization.
Change-Id: I88dc79d5b880253655159ae3b4385b9792a18ec6
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
The function may return a QVariant in place of the actual type because
it cannot express the actual type as-is. This case needs special care
because QMetaType::convert() doesn't know what to do with it.
Pick-to: 6.5
Fixes: QTBUG-112837
Change-Id: Ibf93a28aa6a60d49c5ab63fa7eed5f5a8e58e163
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This just creates an inconsistent state where some of the document has
been parsed and some hasn't. The only thing we actually need is the log
message. Also, fix the warning message.
Amends commit 169f0f71665a3a5155f8d63a9c11bc2484353561.
Pick-to: 6.5
Fixes: QTBUG-112897
Change-Id: Ie8486909f9bea9ee1b87f2857f7b77fb7cc561e8
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If we detect a property or method as potentially shadowed, we don't have
to abandon all hope. We can still retrieve it as untyped var. Since
there are a number of things we can do with untyped var, this may still
be useful.
In the same sense, we need to treat function calls as untyped when the
function in question can be shadowed. Calling functions with var
arguments and return types leads to some more interesting situations in
the call frame setup, so we fix that, too.
Task-number: QTBUG-112480
Change-Id: I238d1cf04951f390c73e14ed9e299f2aa72b68cb
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
| |
Task-number: QTBUG-113160
Pick-to: 6.5
Change-Id: I49de891c36d778df5d2727f2f0703d534421e2d5
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
The new overload avoids the unconditional deep copy inside
QMetaProperty::write()'s lvalue overload.
Task-number: QTBUG-112762
Change-Id: Ic224faf72288e73bb6ad9049f1e0dc585e04ca19
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
| |
Pick-to: 6.5
Task-number: QTBUG-113227
Change-Id: Icd2ca482ef8656d544c7c560ca05b9dd222f9c0a
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
So far we can only deal with methods that don't change the source array
and don't use iterators or functions as parameters. We also omit
concat() for now. However, indexOf(), lastIndexOf(), includes(),
join(), slice() and toString() are possible already now.
Task-number: QTBUG-112722
Change-Id: Id19c74e8ad25af876bc954c040c767823b7e3259
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
While a normal QML scene should not feature extremely deep object trees,
one can still encounter them in some test cases.
Those test cases might then run out of (C++) stack space with the
previous recursive version of markAsDeleted.
Thus, we change the implementation to use an explicit workqueue instead
of relying on recursion. This changes the visitation order, but code is
not supposed to rely on the order of Component.onDestroyed calls anyway
(and we keep at least the order in so far that the parent emits the
"signal" before it's children.
Pick-to: 6.5
Change-Id: I93b30cc26b984d1a21cff92df1dd68cd45e67477
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
| |
Task-number: QTBUG-113148
Change-Id: I9dfdc5601b684b2c54c6436ab86cd2f633c432b5
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Now that the type is available from qmltypes we can just use it.
Task-number: QTBUG-112180
Change-Id: I315372da0925f19c209f676226f450863b0d3ea5
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
| |
Pick-to: 6.5
Change-Id: Ieacfa716b657ac221a75cd5a0dd75d5099962e91
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Janne Koskinen <janne.p.koskinen@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>
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
| |
Task-number: QTBUG-113116
Pick-to: 6.5
Change-Id: I8d2c1c2e8e96b365b4bd2e6c9a321cdf1824272b
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>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
| |
A QQmlScriptString without a d pointer is indeed empty.
Task-number: QTBUG-112859
Change-Id: Ic3aea676403bd815e73d26733392c7f6ac8b84b8
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>
|