aboutsummaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-09-1710-66/+113
|\ | | | | | | | | | | | | | | | | Conflicts: src/qml/jit/qv4baselinejit.cpp src/qml/jsruntime/qv4vme_moth.cpp tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp Change-Id: Iec7cd27ddad0281bd3b7833fb6b252f66a6ae5d6
| * lancelot graphics test: Fix screengrabs being distorted on WindowsEirik Aavitsland2019-09-131-0/+9
| | | | | | | | | | | | | | | | | | | | The grabbing process transports the image data to the main process over the stdout stream. Windows by default applies LF->CRLF conversion on that stream. Avoid by setting the binary mode flag on it. Change-Id: Ieec0911e24e21c111caeb35e35259833e1fdd639 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io>
| * lancelot graphics test: support shadow build and installEirik Aavitsland2019-09-132-9/+15
| | | | | | | | | | | | | | | | | | | | | | Use the QFINDTESTDATA mechanism to locate the test suite directory, and add the data directory and qmlscenegrabber to the installs. As a driveby, improve runtime by cutting down on needlessly long waiting time between test scenes. Change-Id: Id8452c843eef198d8548b196b0a2b5f0bc6be8ba Reviewed-by: Andy Nichols <andy.nichols@qt.io>
| * tst_gridlayout.qml: use createTemporaryObject()Mitch Curtis2019-09-121-41/+15
| | | | | | | | | | | | | | | | Ensures that items created in a function are destroyed upon failures in that function, and results in less code. Change-Id: I62b3b7c3a19dbb2128c5c45bdc7adf4fe80df70d Reviewed-by: Liang Qi <liang.qi@qt.io>
| * tst_gridlayout.qml: convert to a proper data-driven testMitch Curtis2019-09-121-13/+26
| | | | | | | | | | Change-Id: I9f2ccd3d4e6933d68b03d82c2c319aa2e8951e78 Reviewed-by: Liang Qi <liang.qi@qt.io>
| * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-09-123-0/+38
| |\ | | | | | | | | | Change-Id: I6472cd72b27c69257efe54376e428274ebf68050
| | * Merge remote-tracking branch 'origin/5.12.5' into 5.12Qt Forward Merge Bot2019-09-071-0/+0
| | |\ | | | | | | | | | | | | Change-Id: I6f456baf6bade7cdc66529c2b28d914c47929941
| | | * Add changes file for Qt 5.12.5v5.12.5Antti Kokko2019-08-261-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I147d3faefac8114e08a0594a0c43b3cdae959804 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | QQuickTextNodeEngine: don't create background when its alpha is 0Wang Chuan2019-08-292-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the alpha value for the background color of a text element is 0, we don't need to create a rectangle node to represent it, as the rectangle will be invisible anyway. [ChangeLog][QtQuick][QQuickTextNodeEngine] don't create a new rectangle node as the background of text, when the alpha of it is 0 Fixes: QTBUG-76137 Change-Id: I40c624ee8f61740fd07e7d3751a78b6224882913 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| * | | Blacklist tst_qquickmousearea::nestedStopAtBounds on opensuse 15.0Ulf Hermann2019-09-121-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-78153 Change-Id: Ifdca53d4eed452067ba7f75ae0b3e74cf2027895 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * | | Blacklist tst_qquicktextinput::mouseSelectionMode on OpenSuse 15.0Ulf Hermann2019-09-121-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-78162 Change-Id: I8b4f536583afba889a9225d257900031c21ba9e0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * | | tst_qqmlecmascript: Cast pointer to unsigned for printingUlf Hermann2019-09-121-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise QString::number() will apparently extend "negative" values to 64bits even if the actual type is only 32bits long. Change-Id: Ibdecff2fe707616d2254b7e34e08247f0ff52489 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io>
* | | | Fix qmlobject_{dis}connect macros to require semicolon at the endJan Arve Sæther2019-09-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Just do the typical do { [..stuff..] } while(0) in the macros Fix the places that didn't have semicolons. This should eliminate some compiler warnings complaining about excessive semicolons Change-Id: I6b0e7a55badfd0f80c3cd0e9e1da42dc41945485 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | | Force creation of metaobjects for top level objects and componentsUlf Hermann2019-09-137-12/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We want those to be different types, even if they don't add any properties, signals etc. Otherwise you can cross-assign objects of components defined in different files. Fully-dynamic types, such as QQmlPropertyMap are still an exception to this. We need to use the original meta object so that you can still dynamically add properties to any derived types. Therefore, all types derived from QQmlPropertyMap are in fact just aliases of each other. Also, types which aren't addressable from the outside don't get their own meta object. Types are addressable if they live in files and the file name starts with an uppercase character. Otherwise there is no way to refer to the component from anywhere else in QML. Fixes: QTBUG-76021 Change-Id: I96a01fdad13e50e4705520fec46f2b3373e0c365 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | | Use the correct type's meta-type ID for int and save a misplaced castEdward Welbourne2019-09-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I got compiler warnings because of a comparison of a QVariant::type() with an int(). These were caused by a "fix" that cast to int a QMetaType::Int, where the correct fix was surely to use QVariant::Int. This amends commit 83f8d886cee0a40ac1ad5e43e597f309f602ad76. Change-Id: I3f1718e4f2c0c5a6a1cbb79266768fba4e3290e3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | | Merge "Merge remote-tracking branch 'origin/5.13' into 5.14"Liang Qi2019-09-129-88/+155
|\ \ \ \
| * | | | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-129-88/+155
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
| | * | | lancelot graphics test: prepare for new host info mechanismEirik Aavitsland2019-09-042-76/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The old hacky way of the test running a "hostinfo.sh" script is about to be removed, see https://codereview.qt-project.org/c/qt/qtbase/+/272694 Insted add the value of QT_QUICK_BACKEND (the only not-automatically-gathered important piece of host information) programmatically. As a driveby, update it from the obsolete name "QMLSCENE_DEVICE". Change-Id: If95a4ccc89ec1c32bf03743071261dfa1b8f5b4d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * | | QQuickTableView: always relayout after a rebuildRichard Moe Gustavsen2019-08-282-0/+116
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current logic was based on the idea that if both rowHeight-, and columnWidthProveders were set, we didn't have to relayout the items at the end of a rebuild. Because in that case, the row and column sizes would already be correct after the initial load. This assumption turns out to be false, because the providers are allowed to return -1 to signal that the size of a row or column should use default values (meaning, calculated by TableView). And for those cases, we need to do a relayout at the end of a rebuild. Fixes: QTBUG-77074 Change-Id: I0e0f2fdca1cfa9e98f2a0a2b227c3715c16a70f9 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | * | | Make mouseSelection test more stableJan Arve Sæther2019-08-281-9/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QTestLib assumes that the double click interval is below 500ms. Therefore it adds a 500ms delay after all synthesized single- and doubleclick releases to prevent unintentional synthesizing of double click events. This has two unfortunate side-effects: 1. If the double click interval is smaller than 500 ms, it is not possible to synthesize a triple click. (Triple clicks are used for selecting paragraphs in text). This is why the workaround in the block (if clicks ==2) was needed. 2. If the double click interval is bigger than 500ms we might still accidentally trigger a double click event with two successive single click events, so it doesn't even work reliably for that case (!). Therefore, the hardcoded 500ms in QTestLib should probably be revisited. Anyway, to fix this test we therefore have to cancel the 500ms delta QTestLib adds in order to properly synthesize the triple click by adjusting the internal QTest::lastMouseTimestamp. Task-number: QTBUG-77389 Change-Id: Ic738f51b294270ddf99b6d91d256f6ec4b34d039 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-08-284-1/+23
| | |\| | | | | | | | | | | | | | | | | Change-Id: I0ae0a162e133cffd8fb1a2c6b70826e50f06facd
| | | * | Fix loading of ES modules when using CONFIG += qtquickcompilerSimon Hausmann2019-08-264-1/+23
| | | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added the missing lookup for cached .mjs files in ExecutionEngine::compileModule. This allows using .mjs files in WorkerScript {} elements in conjunction with the Qt Quick Compiler and also fixes the use when using QJSEngine::importModule. [ChangeLog][QtQml] Fix loading of EcmaScript modules when using the Qt Quick Compiler. Fixes: QTBUG-77761 Change-Id: I58130b0468f4920b2f6c49b98a2f51d5ae3a0491 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
| | * | Fix flakiness in QQuickTextEdit::mouseSelectionJan Arve Sæther2019-08-211-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid that the last click from the previous test data and the first click in the current test data happens so close in time that they are interpreted as a double click. Task-number: QTBUG-77389 Change-Id: Ia2d159452dcdb58cacccf7101cc3360175b39594 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | | QQmlTypeLoader: Prevent trivial cyclesFabian Kosmale2019-09-126-1/+41
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The type loader already contained a cycle check, however it did not work for the attached example. We now do an additional test for A->B->A cycles, which fixes the bug. This is a valid strategy, as in that case the currently resolved type would immediately fullfill the depentency of the type waiting on it, which in turn resolves the only dependency of the current type. Fixes: QTBUG-78098 Change-Id: I8b550a1c240d3d0fbf158beb99a5daf992904cb0 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Request correct alpha composition on the rhi code pathLaszlo Agocs2019-09-111-0/+7
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-78089 Change-Id: I22f8bb5ec0af33397df14e064a0306bd4c5a5ef5 Reviewed-by: Christian Strømme <christian.stromme@qt.io>
* | | QQuickFolderListModel: make sure properties' values can be updateWang Chuan2019-09-111-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are some properties in FolderListModel neglect to update their values, although the new values are passed to the thread which does the real work [ChangeLog][QtQuick][QQuickFolderListModel] update the values of some properties when setting new values to them Fixes: QTBUG-77965 Change-Id: I77db3388cee569479459deaa2e19546a77da6178 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Prefer JS stack frames over QML contexts when resolving translationsUlf Hermann2019-09-104-0/+39
| | | | | | | | | | | | | | | | | | Fixes: QTBUG-77751 Change-Id: Ic5e07dc4e251c5fbf149b0a4f015bac5187dd6a1 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Also check the non-file-imported type on QQmlMetaType::typeForUrlMichael Brasser2019-09-099-1/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no reason why we wouldn't want to find those. Failure to do so leads to duplicate creation of singleton objects. Fixes: QTBUG-76514 Change-Id: If2fdfbd933229518136ae0d19474bbaebfbb8cff Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Michael Brasser <michael.brasser@live.com>
* | | QQmlTypeLoader: Do some more sanity checks on file and path namesUlf Hermann2019-09-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Apparently we can end up with null bytes in those names, and those really should not be valid. Change-Id: I5b84dbc412342dbfb23befd5417a8bd394d4fb4f Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Make QQmlValueTypeFactory::valueType() and isValueType() consistentUlf Hermann2019-09-044-3/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If isValueType() returns true, we should really return a non-null value from valueType(). Otherwise the assumption that QQmlValueTypeWrapper::valueType is never null breaks. In particular, the unknown type and various primitive types are _not_ value types. We special case the, probably common, UnknownType and check the actual return value of valueType() for anything else. In order to avoid looking up the metaobject each time we request a type that is not a value type, we keep an invalid value type as marker for "not checked yet" and replace that with nullptr once we determine that the type in question is indeed not a value type. Fixes: QTBUG-76866 Change-Id: I797f4cdd4db48ffc1b8fa2d919afc8022f67fa94 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | PathMultiline: handle directly-bound QVector<QPolygonF>Shawn Rutledge2019-09-032-0/+131
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The autotest in 811b15bd161d12e5c85e093f9f492a0c4fa278d6 only tested what happens if the vector of polygons is passed via a QVariant to the PathMultiline paths property. But the intention (as documented) was to literally support an object with Q_PROPERTY(QVector<QPolygonF> paths ...) and binding that paths property to PathMultiline.paths. In that case it appears in QQuickPathMultiline::setPaths() as a QVariant<QJSValue>, canConvert<QVector<QPolygonF>>() returns false, then canConvert<QVariantList>() returns true. Nevertheless each variant in the QVariantList is a QPolygonF, as expected. So we need another check to detect this case. Also added a test specifically for that. Fixes: QTBUG-77929 Change-Id: I84d0a45326d5f007b8ba3cc9bb1fbccf0345d812 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | | Allow semicolon after property declarationFabian Kosmale2019-09-032-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Most of the rules already had Semicolon at the end, however it was missing for UiScriptStatement, list properties and UiObjectInitializer. This change fixes the regression from 5.11.3 to 5.12.0, and keeps the behavior consistent. Fixes: QTBUG-77954 Change-Id: I45ef35fab399e3f971444b96d4a9ec6a99e29e09 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | PathMultiline: allow lists/vectors of polygons or point lists/vectorsShawn Rutledge2019-09-023-0/+212
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a C++ model object can make a vector of vectors of points available directly, and it is bound to a PathMultiline's paths property to provide the view layer, it's a waste of time to convert it to a QVariantList of QVariantLists and back again. Changing the type of the property to QVariant instead of QVariantList enables an extensible set of supported types: all those that make sense. Fixes: QTBUG-77929 Change-Id: If749c2171173e7b9933fc9ecdf6d2741dc1c7500 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | | Enable PathPolyline to take a QPolygonF or QVector<QPointF> pathShawn Rutledge2019-09-023-0/+154
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a C++ model object can make a vector of points available directly, and it is bound to a PathPolyline's path to provide the view layer, it's a waste of time to convert it to a QVariantList and back again. Changing the type of the property to QVariant instead of QVariantList enables an extensible set of supported types. Task-number: QTBUG-77929 Change-Id: I2453b59e047ec3310070e943f6934c9ddcd1ffaa Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | | Merge dev into 5.14Kari Oikarinen2019-08-2731-36/+481
|\ \ \ | | | | | | | | | | | | Change-Id: I3ae119563f41fda63ac2b452f2d05fa83e411faa
| * | | Make the qmllint test an actual testUlf Hermann2019-08-262-15/+19
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I59a96cbef9a68454b68a37e5c7aed45cb4009785 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * | | Stabilize image and borderimage multiFrame testsShawn Rutledge2019-08-242-10/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are various problems on QEMU: color depth may not be 32-bit, and for some reason grabWindow isn't always working. Task-number: QTBUG-77817 Change-Id: I10db56e93643722d1d6a85e66b9dd552ee654432 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * | | Move currentFrame and frameCount properties up to QQuickImageBaseShawn Rutledge2019-08-248-0/+133
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | AnimatedImage already had these properties, but some typically non-animated image formats such as PDF, TIFF and ICO can also support multiple pages. In either case, the currentFrame property can be used to select a specific frame or page. However an AnimatedImage uses a QMovie to do that, whereas a plain Image uses QQuickPixmap. So the accessors need to be virtual in order to have these different implementations. [ChangeLog][QtQuick][Image] Image and BorderImage now have currentFrame and frameCount properties which can be used to step through the frames of multi-page image formats such as TIFF, WEBP and ICO. Task-number: QTBUG-77506 Change-Id: Id4d95a99a26a862957e44b1bd8ffe06d7eababef Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
| * | | Remove usages of deprecated APIs of QWheelEventSona Kurazyan2019-08-233-9/+15
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-76491 Change-Id: I69b0c4ec7c03f9421b18828516e064eff2b45518 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * | | Fix deployment of QtQuick for Android with dummy_imports.qmlJan Arve Sæther2019-08-213-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We rely on the qmlimportscanner to find out what to deploy, but it is limited to scanning .qml files. These tests creates the QML code from C++, so qmlimportscanner fails to detect those dependencies. Therefore, we add a dummy_imports.qml file that has the sole purpose of giving qmlimportscanner which additional dependencies the test has. Change-Id: I4237b738e408c309b9b21de7e53d1a4e4acb7e2e Task-number: QTBUG-73512 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| * | | Remove the last usages of deprecated APIsSona Kurazyan2019-08-205-12/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Replaced the usages of deprecated APIs by corresponding alternatives. - Fixed building the tests with disabled deprecated APIs. Task-number: QTBUG-76491 Change-Id: Ie8c5deb22c2074d39a64346c20e5384a7b2ad99b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| * | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-08-205-0/+46
| |\| | | | | | | | | | | | | | Change-Id: I9ce3eee3d6f88783b9e20110a2814bee805291a4
| | * | tst_qquicklistview: make addOnCompleted more robust + sanity checkFabian Kosmale2019-08-072-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check that after we could not find an element, we do not suddenly find one afterwards. Moreover, disable the cacheBuffer as the asynchronous creation might cause issues, leading to the flakyness observed in QTBUG-77330 Task-number: QTBUG-77330 Change-Id: I444eede16a99a75340a0b7ccf17193298730a675 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-08-053-0/+42
| | |\| | | | | | | | | | | | | Change-Id: I042df89ddd381c7fbb944b7ff49d5b45b764fd47
| | | * Fix possible crash with top/bottom aligned imagesEskil Abrahamsen Blomfeldt2019-07-303-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An image inside at the end of a text block which did not start at text position 0 would resolve to an invalid QTextLine, since we passed the document position to lineForTextPosition(), which expects the relative block position. If the image was aligned to top or bottom, so that the extracted QTextLine was actually accessed, this would cause a crash. [ChangeLog][QtQuick][Text] Fixed a bug where aligning an image to "top" or "bottom" could cause a crash under certain circumstances. Task-number: QTBUG-77217 Change-Id: Iaa239ba482f2a765703656e4116cbebb8435a66e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * | | Introduce functions to set properties during creationFabian Kosmale2019-08-195-0/+156
| | | | | | | | | | | | | | | | | | | | Change-Id: Idd4c8ab9e34b9bc3e00f21d7cf1e4f1a70586e7f Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | | Improve error message when setting to a property with unknown typeAleix Pol2019-08-235-1/+21
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment we were being told that the types were incompatible but the truth was we were comparing to nullptr. This patch makes it apparent that the assigning broke because the type comparison never happened. Change-Id: I29728eedeee13c3bc9389213735df142f56e9c34 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | qmllint: do not warn about the identifier of a catch statementFabian Kosmale2019-08-193-1/+32
| | | | | | | | | | | | | | | Change-Id: I2e679fe4fbebff7d8252da6ea69aed3cc9ffab41 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | CMake: Provide API to allow handling of QML static pluginsAlexandru Croitor2019-08-175-0/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds a new -cmake-output command line argument to qmlimportscanner which outputs its result in a format which is consumable by CMake. This change also adds a new CMake package called Qt5QmlImportScanner. It provides a function called QT5_IMPORT_QML_PLUGINS() which is useful for projects that use a static build of Qt and which also use QML plugins. Calling it with the target name of your application does the following: - Runs qmlimportscanner at configure time to find out which QML / QtQuick plugins are used by your project - Links the imported QML plugins into the target - Links the static dependencies of the QML plugins into the target - Generates a .cpp file that initializes imported QML plugins, which is subsequently compiled and linked into the given target When Qt is built in a shared library config, the introduced function is a no-op. [ChangeLog][CMake] Added ability to import static qml plugins with CMake builds using the new QT5_IMPORT_QML_PLUGINS function. Task-number: QTBUG-38913 Change-Id: Ib9b9a69654eab13dfbe12d10f5cb28ba3c307d1b Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Allow Connections to handle signals using JavaScript functionsUlf Hermann2019-08-1629-14/+242
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Requiring full function definitions as signal handlers has two advantages: 1, We don't need a custom parser that magically recognizes properties which would otherwise be an error in other components. 2, The user is forced to specify the full signature of the handler, including any parameters. This helps when the functions will eventually be compiled to C++ The old behavior is retained, generating a warning if any of the magic bindings are still set in a Connections element. Only if no magic bindings are found, the functions are connected. This is because there might be functions named onFoo in old-style Connections elements and silently connecting those to any matching signals would be a change in behavior. Change-Id: I8c78d8994fdcddd355fe822cde9a0702dc8c75de Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>