aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Support QRegularExpression on the same level as QRegExpUlf Hermann2019-03-207-9/+85
| | | | | | | | | | | | | | | | | QRegularExpression is the recommended way to do regular expressions nowadays. Support assignment of JavaScript regular expressions to QRegularExpression properties of QObjects and the other way around. QJSValue::toVariant() will create a QRegularExpression from a JavaScript RegExp by default now. [ChangeLog][QtQml][Important Behavior Changes] QRegularExpression is now supported the same way QRegExp is in QML. QJSValue::toVariant() creates a QRegularExpression variant rather than a QRegExp one from a JavaScript regular expression now. Fixes: QTBUG-73429 Change-Id: I301a02771cd17903406c2bc5c7aaeca6cce629f0 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Use QQmlRefCount for QQmlType(Private)Ulf Hermann2019-03-196-67/+43
| | | | | | | | | | | | | As we already have an implementation of refcounting, we can just use that intead of inventing another one. This also gives us nice move ctors and operators. Also, use const pointers to QQmlTypePrivate where possible. This exposes quite some nastiness that needs to be fixed in follow-up commits: All the mutable members of QQmlTypePrivate are unsafe for multithreaded use. Change-Id: I3be8f2c53d86e06ffa80c8df8830473fe6d1d91d Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Replace bit field with normal typesErik Verbruggen2019-03-192-5/+5
| | | | | | | So they can be addressed through offsetof() in JITs. Change-Id: If598dde3ace89db0643feed895bdf706563c3cce Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-03-1540-160/+231
|\ | | | | | | | | | | | | Conflicts: src/qml/compiler/qv4codegen.cpp Change-Id: I604517d0948fb5056ce36cc104f13ac956fbcc24
| * Update plugins.qmltypes for Qt 5.13Kai Koehne2019-03-1315-36/+77
| | | | | | | | | | | | | | | | Task-number: QTBUG-73484 Change-Id: I089f5122817a4da1fce13f55d2975240d741b9f6 Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * Doc: include support for astc compressed texture filesEirik Aavitsland2019-03-131-1/+2
| | | | | | | | | | Change-Id: I939cba4ccdb5408a5a6a47f1324538462f51e35a Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| * Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into ↵Ulf Hermann2019-03-1322-146/+141
| |\ | | | | | | | | | refs/staging/5.13
| | * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-03-1322-146/+141
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qv4codegen.cpp src/qml/animations/qsequentialanimationgroupjob.cpp Change-Id: I8b76e509fd7c8599d4cef25181d790ee28edab54
| | | * Doc: link to C++ and QML integration flowchartMitch Curtis2019-03-121-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The chart makes it easier to find the correct way to register a C++ type with the QML type system, so it makes sense to link to it from these docs. Task-number: QTBUG-74318 Change-Id: Iba74ce02d200d6609dbb0a508d618226a6fe1e54 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| | | * Fix leaking of QML QQuickItemGrabResult objectsVal Doroshchuk2019-03-111-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If QQuickItem::grabToImage is called from QML, QQuickItemGrabResult is created but was never deleted. Adding a deleteLater() right after dispatching the callback ensures that QQuickItemGrabResult objects are deleted. Task-number: QTBUG-73723 Change-Id: Ifda85599098f2b679ae5f22e1d47a73962ed0a85 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | | * Disable tail calls for function called with more arguments than formalsUlf Hermann2019-03-041-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We cannot easily find the required stack space to store the extra arguments without adding a new stack frame. In principle it would be possible, but heavily recursing on such functions should be a rare problem. Change-Id: I1a53a6d29e37ce67aa7bd64acb7b1f41197e84c0 Fixes: QTBUG-72807 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * Fix a bug where hover events were not sent if the mouse was never movedJan Arve Sæther2019-03-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This happened if the "real mouse" was never moved, since moving the real mouse caused it to update the internal QQuickWindowPrivate::lastMousePosition. If the window never got any mouse events, it would therefore fail to generate proper hover events. However, if the window got exposed under a mouse cursor it would generate a hover enter event. We therefore update lastMousePosition when that happens also. Change-Id: I77d9b1bd779a813756c4056b015f2e81664b6d36 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | | * Don't crash if the synth-mouse touchpoint is absent from a touch eventShawn Rutledge2019-03-041-12/+16
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-74008 Change-Id: Ib232b723e4a246db0312145ef475ce81cd5f1a5f Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
| | | * Doc: QQmlApplicationEngine::objectCreated() also signals errorsUlf Hermann2019-03-011-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-73298 Change-Id: Icb872963982f32baf6e9489f43d228041bcea2b8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | | * Doc: Document peculiarity of sorting DelegateModelGroupsUlf Hermann2019-03-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If an item is part of multiple groups, moving it in one group also moves it in all other groups. This has been the case since the groups exist. Fixes: QTBUG-73707 Change-Id: Id1a6e82f667eaf992982e693475b734f485eb8a2 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | | * Doc: Fix use of \QtMinorVersion in snippetsKai Koehne2019-03-011-16/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Macros are in general not extended in \qml..\endqml code snippets. You need to make it an explicit argument. This fixes a regression introduced in fd3cf7a45ad5abf26. Change-Id: Ic3a44d6c66b2301a12e051d647dfa6aebf8e8256 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| | | * QQuickFlickable: fix setContentX/setContentY comparing qrealYulong Bai2019-03-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QQuickFlickable::setContentX/setContentY used !=/== to compare qreal, which would trigger binding loop warnings while using bi-directional property bindings. Fixes: QTBUG-74128 Change-Id: I224a924e11c93cf047478ba0e09e10e57eedabde Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | | * Text: render table cell backgrounds properlyShawn Rutledge2019-02-282-9/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QQuickTextNodeEngine::addTextBlock() was noticing the background color of text fragments, including those within table cells (and adding to the colorChanges vector for rendering), but not rendering a rectangle for the background of the entire table cell. So while the color was correct, it only took up as much space as the text itself. Also, QTextDocumentLayout needs to be told how much width is available so that QTextDocumentLayoutPrivate::layoutTable() will allocate cell width appropriately in case width is given as a percentage, e.g. <td width="20%">. This is done by calling QTextDocument::setPageSize() with correct width in pixels rather than zero. Fixes: QTBUG-72457 Change-Id: I5c8f861829f76d1cf4044fccd1142c3817bb33bc Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | | * Doc: Fix link issuesNico Vertriest2019-02-286-20/+27
| | | | | | | | | | | | | | | | | | | | Change-Id: I0e08820a6d25996fe27118f05214ff63d695d24e Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
| | | * qtlite: Fix build the source code with -no-feature-shortcutMikhail Svetkin2019-02-271-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I7b1b3fc60eb40e799c6622ea1d4ad14baa0fe269 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
| | | * doc: Clarify that DelegateModel is a kind of proxy modelShawn Rutledge2019-02-261-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was not quite clear in the GridView DnD example that the ListModel doesn't get reordered, so if new ListElements are inserted after reordering the DelegateModel by DnD, predicting the position where new delegates will appear becomes a bit of a riddle. Also: - the QQmlDelegateModelAttached::model is a model, not an int - disambiguate the properties that have the same names in QQmlDelegateModel and QQmlDelegateModelAttached, using \keyword for linking. Task-number: QTBUG-34891 Change-Id: I485fd632f67d607652428b4e3c9ca528e57f7348 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
| | | * Don't crash when passive grabber deleted before exclusive gr. releasedShawn Rutledge2019-02-261-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In this scenario, a DragHandler is inside an Item in a Loader, under a MouseArea, which unloads the loader on press. So on press, the DragHandler acquires a passive grab, then the MouseArea acquires the exclusive grab, then the DragHandler is destroyed along with its parent when the Loader is unloaded. On release, QQuickEventPoint::setGrabberItem(nullptr) was sending an onGrabChanged(passiveGrabber, OverrideGrabPassive, this) notification. That was questionable: the handler was not just then getting its grab overridden, but rather un-overridden, because the exclusive grab was being released. It's also a good idea to check for null pointers, since m_passiveGrabbers is a collection of QPointers already, so we can tell when a passive grabber is deleted dynamically. It can also be reproduced with MultiPointTouchArea just as with MouseArea, so the test is written that way for convenience, because we have tst_multipointtoucharea_interop already. It doesn't really matter which handler has the passive grab, or which item has the exclusive grab that's being relinquished. Fixes: QTBUG-73819 Change-Id: Ic605efa2143a1d849be095dcb88d6c38d7d2ee19 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
| | | * QAnimationGroupJob: Notify about removed children on clear()Ulf Hermann2019-02-261-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Derived classes, such as QSequentialAnimationGroupJob, might keep additional pointers to the children. Those need to be cleared, too. Therefore, use the regular removeAnimation() method for clearing. Fixes: QTBUG-73828 Change-Id: I64cc1fe4da59f10b29f27012b10f93b4289b6e5a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * Unify and fix number to string conversion with radixUlf Hermann2019-02-252-39/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the loop that generated the string could fail to terminate with certain numbers as input. Also, the algorithm was duplicated in two places. Change-Id: Ie2075148d931e7cfcedb5bcd23af61e2e8afc232 Fixes: QTBUG-73999 Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | | * V4: Rotate loop in ArrayPattern and eliminate "done" labelErik Verbruggen2019-02-251-11/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This prevents jumping over the resetting of the unwind handler when an exception occurs. (cherry-picked from commit 0282b89ec672e25a465a8e51bc74c7fd58a624b1) Fixes: QTBUG-73985 Change-Id: I4a4da815f54c13980d239e0492f9b013991cfbd5 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | | * V4: Fix unwind handling when destructuring listsErik Verbruggen2019-02-251-14/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If there was a rest element in the list, the generated code would jump over the clean-up (closing of the iterator). However, this would also jump over any resetting of the unwind handler. (cherry-picked from commit 3310f173c1c6208cb0f6541578419196bc29831f) Task-number: QTBUG-73985 Change-Id: I9a1bcb9e69fd98975fe9c89e23a4568b0dafdf83 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | | * Update the cursor when the window is enteredAndy Shaw2019-02-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a window is entered, due to another window being hidden, then it is possible that the item under the mouse has a different cursor than the one previously set for that window. Since there will not be a mouse move at this point yet, then we should update the cursor right away. Change-Id: I2ef3c72617ae5c995a4daf7daef1ba3311fdcc12 Fixes: QTBUG-41045 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * | | Ask rendering thread to release resources when window is closedDamien Caliste2019-03-131-0/+8
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the close event is accepted, the close handler in QWindow will destroy the underlying platform window without notifying the QSGRenderer attribute windowManager. This may cause a race condition if the renderer is a QSGThreadedRenderLoop because the platform window may be deleted while the thread is using it. Correct this issue by notifying the QSGRenderer on a close event using the hide() method (which is supposed to release the resources according to documentation). Task-number: QTBUG-73929 Change-Id: Ia48366b3f6638d5d714ceb17a2f8c7848eb20465 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * | Use lowercase name for window headerSamuli Piippo2019-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Compilation otherwise fails when cross-compiling on linux, since the filename is is lowercased. Change-Id: I0b25f814543b677802cd6f07dc91964547a6028a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * | wasm: disable MOTH_COMPUTED_GOTO for stock llvmv5.13.0-beta1Morten Johan Sørvig2019-03-081-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The WASM_OBJECT_FILES=1 build mode requires using upstream llvm (instead of the of the emscripten ‘fastcomp’ llvm fork), which does not support computed goto. Change-Id: Ie47b29ac8a09f4bd2519fc55087e4803e66e9520 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* | | JSC::Yarr::Parser: fix invalid noreturn warningYulong Bai2019-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Function 'isValidNamedForwardReference' declared 'noreturn' but still returned. Attribute macro 'NO_RETURN_DUE_TO_ASSERT' is deleted to pass compilation for GCC and Clang while [-Werror,-Winvalid-noreturn] enabled. Fixes: QTBUG-74250 Change-Id: I6f7f64ffacf8003f0c695e6a4b9cb422ba57153c Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-03-089-37/+49
|\| | | | | | | | | | | Change-Id: I7aa5284298990062fac9d9f1ab55d05f9b225ac9
| * | Properly revision new TestResult slotsKai Koehne2019-03-072-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure the slots added in 028617688b0f86ac are only available with import QtTest 1.13 Change-Id: I93aa6ff6595ddc4c4583f1785bd19d489793a5f8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| * | Doc: Promote use of ECMAScript modules over Qt.include()Ulf Hermann2019-03-045-33/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also, mention that Qt.include() is deprecated. [ChangeLog][QtQml] Qt.include() is deprecated in favor of ECMAScript modules. Task-number: QTBUG-74068 Change-Id: Ia13e4f1577d86b869a9a1cd810a82ff0b27ea0cc Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * | Make qml-tracing a private featureUlf Hermann2019-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | There is no need to expose it in public API. Change-Id: I2a6145403d31694d36be1f704fe486b76738fe28 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * | Doc: Fix a code snippet in DragHandler QML typeTopi Reinio2019-02-251-1/+1
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-73900 Change-Id: I00875525450a91d6841e5e7a2af77b41e400ea46 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* | | V4: Add IR that can use traced information to JITErik Verbruggen2019-03-0417-10/+5512
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the in a series of patches for a JIT that can use traced information to generate better code. In this patch, traced information is not used/stored yet. It allows testing the basic infrastructure without trying to do any optimizations, therefore making it easier to debug, test, and review. Change-Id: I589bdadf731c36542331abe64e1b39e305b6723e Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Fix msvc warning on size differencesErik Verbruggen2019-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | And as warnings treated as error, it stops the build. Change-Id: I429aac8b5fd8b10d52751295191dc1d5bf85401d Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | V4: Undo rotation of the do-while loopErik Verbruggen2019-03-011-10/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously the generated code looked like this: Jump loop-body loop-condition: acc = condition JumpFalse loop-end loop-body: ... Jump loop-condition loop end: ... This is a problem for anything that analyzes the bytecode in 1 pass from top to bottom: at the point of the loop-condition the state of the interpreter isn't known yet: that state will only be known after analyzing the loop body. The new generated code does not have that problem: loop-body: ... acc = condition JumpTrue loop-body loop-end: ... Change-Id: I16977e9ce1f9377e7bf4d09afc16136ba0111463 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | V4: Change both setter0 lookup methods to reflect getter0Erik Verbruggen2019-03-013-22/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The setter0Inline would do the index to offset calculation each time it was called, while getter0Inline would do it once when creating the lookup. Same for setter0Memberdata. Both setters now mirror the behavior of their getter counterparts. However, getterTwoClasses is more sophisticated than setterTwoClasses, so there we still use the existing setter0setter0, but restore the uncorrected index back into the two-class-lookup. Change-Id: Ide29d0304e840b2e09d65bdfc216fa8da08d69dc Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | TableModel: support built-in QML model rolesMitch Curtis2019-02-283-90/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For the display role, we'll return the first role in that column if it wasn't explicitly specified. For every other role, we can just return an invalid QVariant. As usual, roleDataProvider can be used for any data that is missing. Before this patch, the extra roles were missing from roleNames, so they couldn't be used in delegates. Change-Id: I53ac5b75526bcddec44baf834f6a093115a70993 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | Upgrade Yarr to latest version from WebKitUlf Hermann2019-02-2615-221/+746
| | | | | | | | | | | | | | | | | | | | | | | | | | | This is an upgrade to commit cbb0aa18662bc26da31de91e2104c030eaa6ead2 in webkit. It causes some more ecmascript tests to pass. Fixes: QTBUG-73915 Change-Id: I8bb5ff9b37907d17b1020576ba64f0b3aed2f1b3 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev" into ↵Liang Qi2019-02-2522-143/+256
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-02-2522-143/+256
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlmetatype.cpp Change-Id: I517c001ea4eb0fdd8e469f9fffe5b7559a5b0795
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-02-2218-84/+159
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/quick/qquicktableview/tst_qquicktableview.cpp Change-Id: If3bf1abc23a59c458be0bb862d92f2edcb16b79f
| | | * Merge remote-tracking branch 'origin/5.12.2' into 5.12Qt Forward Merge Bot2019-02-221-9/+22
| | | |\ | | | | | | | | | | | | | | | Change-Id: If1c718780a48a3e818eb5a0c0907a31acb6c694d
| | | | * Only warn about incompatible parameter types passed from QMLUlf Hermann2019-02-211-9/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Throwing a TypeError is too drastic. We need to properly deprecate this pattern before we actually enforce the compatibility. Fixes: QTBUG-73943 Change-Id: I00313ad7aed4021a7368fd014e2bfc6443b177e3 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * | QML: Pass type minor version when creating property dataUlf Hermann2019-02-219-27/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Depending on the type minor version recursive properties should be available or not. Check for that when resolving grouped properties. Fixes: QTBUG-33179 Change-Id: Id8f62befdc4a29d879710499e19d3d289bd18775 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * | QQmlDelegateModel: guard new row/column properties with revision 12Richard Moe Gustavsen2019-02-217-4/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tag the new 'row' and 'column' properties with revision 12. This will make sure that they cannot be accessed by the delegate unless the QQmlAdaptorModel has the correct minorVersion set. Fixes: QTBUG-70031 Change-Id: I49e67c37ab5b7925c7bca313bbb99f04d1387cc4 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | | * | QQmlAdaptorModel::Accessors: create a propertyCache for all accessors, not ↵Richard Moe Gustavsen2019-02-214-42/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | just for QAIM From before, only accessors for wrapping a QAbstractItemModel had to create a dynamic QMetaObject together with a shared QQmlPropertyCache (for enabling model roles in the delegate). Each model item in the view would get a QQmlData with the dynamic property cache assigned, which would then later be used by the v4 runtime during property lookup. But after we added the properties 'row' and 'column' to the model items, we now always need to create a property cache, regardless of the Accessor used. That way we can we specify the correct metaObject revision of the model item in the cache, which will also allow us to revision the new properties so that they will be respected by the v4 runtime. In this patch we hard-code the revision (modelItemRevision) to be 0, but this will change in a subsequent patch. This patch will move the 'metaObject' and 'propertyCache' up to the base class (Accessor), and ensure that we create a property cache for each of the non-pure-virtual sub classes. The model item wrappers will then, when creating a QQmlData, assign the shared cache from the associated Accessor. Task-number: QTBUG-70031 Change-Id: If6a67d5968d360d4a2b23d8291669c0549e8a342 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>