summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Fix not working password test for QPdfQuickMichal Klocek2023-03-081-3/+0
| | | | | | | | | | | | | In qml url can have different schemas like 'qrc' 'file' 'assets'. Make correct conversion so file can be loaded. Note check isLocalFile() is not true for qrc scheme. Fixes: QTBUG-106072 Change-Id: I4dcc969e4c6d9b3f58ea5d81d20d8e81b55edfde Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> (cherry picked from commit efbb12954cf6e581b6b29bed2fa2bb26e1cfab71)
* Fix initialization of QWebEngineDownloadRequest::totalBytes for WidgetsPeter Varga2023-03-021-2/+2
| | | | | | | | | | | | | | QQuickWebEngineProfile already initializes totalBytes. Also clean up QWebEngineDownloadRequestPrivate and fix typo in documentation. Fixes: QTBUG-104869 Change-Id: I8c4b79c076ddc63180960e22a9488b45ff6c4402 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 496647f7647571ca3cdf81b10ba418de0f06f34d) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> (cherry picked from commit 01be7f108c0d501f532b197f091baaaaba211ee6)
* Add qml filesystem api testsMichal Klocek2023-02-284-0/+200
| | | | | | | | | | | | | | | | | | | There are three functions we use within file systems API, which trigger dialogs: * window.showSaveFilePicker * window.showOpenFilePicker * window.showDirectoryPicker Only first one was tested with widgets, therefore add tests which cover use of api, and also test cover the found issues in previous commits. Note we have separate test to cover file system dialogs coming from <input> html tags in tst_filePicker Change-Id: I4616efa84688ed471fb8c4566e49262bce945638 Reviewed-by: Michael Brüning <michael.bruning@qt.io> (cherry picked from commit 1a291c5579122e520af1a2cec263ebd12dcd2407)
* Replace uses of deprecated _qs with _sPeter Varga2023-02-031-7/+9
| | | | | | | | Task-number: QTBUG-101408 Change-Id: Ie8a7944c3ded5662953bed00f022905f5805275e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit b4cf9c2e0520ec39ef064955ec025f5941e4c04a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Quick: Fix file selection modes in the default UI delegateSzabolcs David2023-01-193-1/+20
| | | | | | | | | | | Our implementation of QML file picker was outdated. Now directory picker is a separate type of dialog and other file selection modes are set in FileDialog.fileMode property. Change-Id: Icc62369539c56666e596e5ee6f1b3068a43acd81 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 35d4b0b1d1c723e32d589b3dfddfe96eaa8e5568) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix creation of nssdb for certificate store unit testMichal Klocek2023-01-042-7/+13
| | | | | | | | | | | | | | In case there is no nssdb in system create empty database. This got unnoticed as running webengine creates one, however when doing test configuration on fresh system without one pk12utils fails. Move 'nickname' to certificate otherwise clean job does not work. Task-number: QTBUG-109179 Change-Id: I401ffab62dd13d7aa1459672b1170afcde3cde83 Reviewed-by: Michael Brüning <michael.bruning@qt.io> (cherry picked from commit b3b4aef1d67096632c703adca6fdfb2b676bdc0a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update ChromiumMichael Brüning2023-01-031-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Submodule src/3rdparty 0a34013e..f2bbd3ec: * [Backport] Security bug 1393384 * [Backport] Security bug 1393177 * [Backport] Security bug 1394382 (4/4) * [Backport] Security bug 1394382 (3/4) * [Backport] Security bug 1394382 (2/4) * [Backport] Security bug 1394382 (1/4) * [Backport] CVE-2022-4440: Use after free in Profiles * [Backport] CVE-2022-4439: Use after free in Aura * [Backport] CVE-2022-4438: Use after free in Blink Frames * [Backport] CVE-2022-4436: Use after free in Blink Media * [Backport] CVE-2022-4437: Use after free in Mojo IPC * [Backport] Security bug 1367993 * [Backport] Security bug 1365082 * [Backport] Security bug 1378601 * [Backport] CVE-2022-4194: Use after free in Accessibility * [Backport] CVE-2022-4193: Insufficient policy enforcement in File System API * [Backport] CVE-2022-4190: Insufficient data validation in Directory * [Backport] Security bug 1372019 (4/4) * [Backport] Security bug 1372019 (3/4) * [Backport] Security bug 1372019 (2/4) * [Backport] Security bug 1372019 (1/4) Adjusts the test for the file chooser as Chromium now enforces folder uploads to be folders. Task-number: QTBUG-109224 Fixes: QTBUG-108106 Change-Id: Ib1ccc839650ae323d6ba867991eca19d5bb858aa Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Disable nss test on yoctoMichal Klocek2022-12-301-1/+1
| | | | | | | | | | As pk12util call fails disable the test. Fixes: QTBUG-109179 Change-Id: I4149c77a86c3c1df8b34ed9b641eae916e688ecc Reviewed-by: Samuli Piippo <samuli.piippo@qt.io> (cherry picked from commit 6dc341bc52511ade244878a4da35f4de587b528e) Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Recreate response head objects on multiple redirectMichael Brüning2022-12-143-0/+55
| | | | | | | | | | | The previous response head gets moved when redirecting, which lead to dereferencing a null pointer on the next redirect. Fixes: QTBUG-109357 Change-Id: Iaad1c46b8d4ca9720f1749980a9e06337ca0f3d8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit c6b2b5d8038b3ec0de6233c1e21df60ade11c81b) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Rewrite mixedSchemes testMichal Klocek2022-12-091-86/+142
| | | | | | | | | | | | | | | Follow the same 'test' pattern we have in other tests. Note that this and previous change make test suite for tst_origin execute faster form ~170s to ~60s for desktop linux and from ~320s to ~140s for qemu. Task-number: QTBUG-105342 Change-Id: I5cd0aa0a76fcc2d005cee398a88ba4099f9881c3 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit dfc19ad0804fe45dab19ffdf46084e9e4be24f0a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Reduce slowness and flakiness of tst_originMichal Klocek2022-12-095-22/+45
| | | | | | | | | | | | | | | | | | | | | | | This test runs very slow and it is flaky. Make it run faster by: * instead of doing timeout checks for "cannotLoad", introduce <image> element add use 'onload' and 'onerror' handlers before doing actual <iframe> load, this dropps a need for hardcoded delay/deadline for ifrme being loaded. * do not evaluate JavaScript in try wait loop , use JavaScript messages instead. Note that using <img> or <script> element to perform the test (which have onload and onerros handler unlike iframe) ie. loading cross origin scripts or images instead of iframes is a dead-end as it has different results and "canLoadButNotAccess" can not be tested as origin BAR can load a script from origin FOO, but it still works in BAR‘s context. Task-number: QTBUG-105342 Change-Id: I180aea801cedb0f97b96cb90a54b793d0a7c1a7f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit ffc09328c9774548e378a3187ea0d386cc31de3a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Return both application and system certificatesAllan Sandfeld Jensen2022-12-085-8/+143
| | | | | | | | | | | | | | | | | | | | | | | | | | For the certificate choice return both application and system certificates. Add unit test to cover the case on Linux. Unfortunately it requires adding the user certificate to the nss data store, which is not not nice, however porting the certificate manger from Chromium is a bigger task. Test runs only if the machine has pk12utils installed. During the test the user certificate is imported into the nss database with the nickname 'qwebengineclientcertificatestore'. This can be removed later with: ninja remove-user-personal-certificate and verified with: certutil -d sql:$HOME/.pki/nssdb -L Change-Id: I475fddc68ea56304980f6c835ed4cfed4b093ad4 Reviewed-by: Michael Brüning <michael.bruning@qt.io> (cherry picked from commit daaac7adb519e82b21a2f826ef6ae83c4f102a62) Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Add client SSL authentication testMichal Klocek2022-12-0810-6/+200
| | | | | | | | | | | | | | | | | Our qwebenginecertificatestore unit test so far only tested adding/removing custom certificates into the memory. However, it never actually initialized certificate store and did not test if ssl certificate client authentication really works. Cover that case and client authentication test. Note ca and client certificates in the test are self signed to be able to run test without network connection, however we ignore the errors. Change-Id: I4df4fdfabed5abd8f8bde7d4c0c79b5fd7f6f3a9 Reviewed-by: Michael Brüning <michael.bruning@qt.io> (cherry picked from commit 37da356e7b7ec11f486589dce4a230b36c53c7a3) Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Port from qAsConst() to std::as_const()Marc Mutz2022-11-225-6/+6
| | | | | | | | | | | | | | | | We've been requiring C++17 since Qt 6.0, and our qAsConst use finally starts to bother us (QTBUG-99313), so time to port away from it now. Since qAsConst has exactly the same semantics as std::as_const (down to rvalue treatment, constexpr'ness and noexcept'ness), there's really nothing more to it than a global search-and-replace. This is a 6.4 re-run of the script we ran in dev, in order to avoid conflicts between the branches when cherry-picking. Change-Id: I5eca3df3179dfb2b2682c75a479ba9a4259cc703 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Port from container::count() and length() to size() - V5Marc Mutz2022-11-2228-731/+731
| | | | | | | | | | This is a the same semantic patch (qt-port-to-std-compatible-api V5 with config Scope: 'Container') as in dev. I've re-ran it in 6.4 to avoid cherry-pick conflicts. Change-Id: I9621dee5ed328b47e78919a34c307105e4311903 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Use QSslServer in certificate testMichal Klocek2022-11-173-37/+31
| | | | | | | | | | | | | | | | | | We had our own implementation for the HTTPS server. However, the way it worked involved adding for every incoming connection a socket to the list of pending connections, which resulted in unnecessary logging noise due to socket connect/disconnected signals during the SSL handshake negotiations. It also resulted in memory leaks. Since 6.4 we have now QSslServer which adds socket to the pending connection list only after encryption got established. Change-Id: I3c8a2a0684e3f0760a56d4b4aaf7b777700e334b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 4d0a8a6030728bcf63b654ecee2de2fec3575b77) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Blacklist certificate test and unblock integrationsMichal Klocek2022-11-011-0/+2
| | | | | | | | | Certificate for revoked.badssl.com expired on 10/28/2022. Change-Id: I06022bea1404bf5134f815067dcd2713790e5a23 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 23841d844adf252061f949b1b810049e82ec2aef) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix GCC compiler warnings in auto testsPeter Varga2022-10-133-9/+13
| | | | | | | Change-Id: I9daae92749e7dbe0580c17e8f0325e2199b2ed17 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit cd82a30311302ded70b278bfc4919097b0f421f7) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Stop using deprecated QMouseEvent constructorShawn Rutledge2022-10-061-2/+5
| | | | | | | | | | Followup to qtbase 6b2c9b81afdb3d1d9b7a2e87819e9545b14810f3 Change-Id: Ib879ee176c4fd1fc4bdbac7161ea20cf5c59a247 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 252456b94a93ddef2fdfdd49d59fc8f474fb5e80) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix locally falling tst_qpdfdocument on qemuMichal Klocek2022-09-161-1/+1
| | | | | | | | | | | Use name for temporary file otherwise is can not be opened on qemu. Task-number: QTBUG-105342 Change-Id: I7f9ed244c32b866ead6832ed942e2293be24811b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 30f2d86426c674d0cba9ca88dbf7e587c57e72d3) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix using QNetworkReply with custom url schemesAllan Sandfeld Jensen2022-09-131-7/+52
| | | | | | | | | | | | | | Sequential QIODevices are allowed to report atEnd() when they have no data to read, but add more data later. To avoid a regression with our own tests, treat a read error from a sequential device at end, as end-of-data. Fixes: QTBUG-106461 Change-Id: Iac1233e6daa978c827c37a7fd3131e2fce764111 Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit aefd389bfdf7efcaf787d2cfb4683d7018cb377c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Improve tests for qemu-armv7Allan Sandfeld Jensen2022-09-022-3/+2
| | | | | | | | | | | | test_runJavaScript() was badly written with a hardcoded wait of 100ms this should make it both faster on normal machines and more reliable on slower ones. Fixes: QTBUG-106210 Change-Id: I539e59dce6e3719661202e1a213277794a660bd3 Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit f38f75bf8310186085c3be7a9f5816115f5c74c9) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Add tst_MultiPageView::navigation() testShawn Rutledge2022-09-023-0/+138
| | | | | | | | | | | | | The navigation() test is a high-level one to verify that the navigation stack works and that the TableView jumps to the expected locations inside the document when we go to pages, click links and use the forward() and back() methods. It's similar to the internalLink() test, but more programmable. Change-Id: I337e2ae283213238288a172d1bab3df07a1395e0 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit 2d8c8ac02e8afed8d99996e3d53cacd982badfeb) Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Blacklist tst_MultiPageView::password on WindowsShawn Rutledge2022-09-011-0/+3
| | | | | | | Task-number: QTBUG-106072 Change-Id: Iecc763f0f8cd5f1b83588a31f1de4fd4f8c0055e Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> (cherry picked from commit 1f7ced8bc0d3c4156648b99b360580b5420acbdc)
* Begin adding Qt Quick Pdf testsShawn Rutledge2022-09-019-0/+762
| | | | | | | | | | | | | | | | | | ...starting with tests for the PdfMultiPageView component. The file bookmarksAndLinks.pdf is fx/other/bookmarkgetcolor.pdf from https://pdfium.googlesource.com/pdfium_tests pdf-sample.protected.pdf is from 55b863f2dd2773290c63259c3835b19dcb277098 The shared/util implementation is adapted from the Qt Quick 3D module, with showView() adapted from qtdeclarative's viewtestutils.cpp. Change-Id: I1458968846d33f262465a368fdaec771d4979b67 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit 9ae10a349a8525ebf5975ba4d17271f98e80f708) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix crashes of combobox popup testsMichal Klocek2022-08-261-9/+22
| | | | | | | | | | | | | | | | | Offscreenwindow from quickwidget is a top level window, which was from time to time used as "popup" window in the test instead of widgetwindow of webengineview. Check if window is offscreenwindow and do not consider it as valid window in the test. Moreover popup should be closed in the end of test, however checking for offscreen window would result in bogus outcome as offscreen window is destroyed before quickwidgetwindow. Task-number: QTBUG-105342 Change-Id: Ibfeab0cad0bc43690c2458cb97738b4b5ea132f4 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> (cherry picked from commit 7415a127df0ab21b703d1a549abe595900e76fab) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Reestablish default config for embedded buildsAllan Sandfeld Jensen2022-08-262-0/+6
| | | | | | | | | | Was missing from the CMake switch-over Change-Id: I0171d395f9e66c072e368b7019539fc29ff865b8 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 0def03920e07d6a2e193cbd2537643d668bc979a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix initial widget focusPeter Varga2022-08-241-13/+43
| | | | | | | | | | | | | Avoid WebEngineQuickWidget::rootObject() to steal focus from the content item (RenderWidgetHostViewQtDelegateItem). The root object is supposed to keep the content item alive and not handling input events. Fixes: QTBUG-105072 Change-Id: I18e8ff39bfe338b742416bc56f6937edcfd2bc21 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit a7d353ae7d85438b92c8e376cbf6cf92c05a0952) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Increase timeoutsAllan Sandfeld Jensen2022-08-1712-17/+17
| | | | | | | | | | | Trying to pass on qemu-arm64 Task-number: QTBUG-105342 Change-Id: I5eca4ef2235d26b88207decd66b06c30b9f9972f Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 8e8c728517785e02e066138544dd156d54680b2c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix single process crash when proxy pac is usedMichal Klocek2022-08-163-8/+30
| | | | | | | | | | | | | | | | | | | Using proxy v8 resolver ends up in race condition when render thread tries to evaluate extension handle and v8 proxy resolver evaluates proxy pac script. Disable v8 proxy resolver for single process mode. Issue tracked upstream http://crbug.com/474654 Modify the unit test to catch the crash case, the test loads now network resource but it does not matter as we do not check for failure or success. Fixes: QTBUG-104436 Change-Id: Id3221d1b8b3896f0ced3d0cd7cb9d9eceeb929cc Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit 1b6633d1ce86eaf43b750a03a785793512e487ed) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Only skip arm64 qemu testsAllan Sandfeld Jensen2022-08-121-1/+1
| | | | | | | | | | It seems we can pass the arm32 tests. Task-number: QTBUG-105342 Change-Id: Ic5492e43cd327119305c3731701186710f9d59c6 Reviewed-by: Michael Brüning <michael.bruning@qt.io> (cherry picked from commit bb0a39c5dab77cc6aba6819e038dfb8182c69861) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Disable tests on qemu temporallyMichal Klocek2022-08-061-0/+5
| | | | | | | Task-number: QTBUG-105342 Change-Id: Ic644c193329ff6c21dfffe43f52ea6f0c5a8fc3f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 603be2388eb227270fbc6d9ef0f926e7f3059b5f)
* Adaptations for Chromium 102Allan Sandfeld Jensen2022-08-061-5/+10
| | | | | | | Change-Id: I7ef0ad616f2ea0fae482253335e95998aa2d360e Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 00e2201264e3839570fbf64817eeca931a630b01) Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Adaptations for Chromium 100Allan Sandfeld Jensen2022-08-063-11/+11
| | | | | | Change-Id: I217c87657f544a2e868de7291353ff1143e20902 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit fae023b184f6c044e85f4ca6052c306d519e2e85)
* Use SPDX license identifiersLucie Gérard2022-07-081-27/+2
| | | | | | | | | | | | Ammend 9b9d789fcb8f63a8998f1eefe44f2a1c8156c362 : some files were still missing SPDX headers Task-number: QTBUG-67283 Task-number: QTBUG-104589 Change-Id: Ia4d2aae636bbdb1a99c422e3b8d3f097c3af34d6 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit e74ccbf41d2cce734175579a58d36eb7f223319c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Skip uidelegates test on macosAllan Sandfeld Jensen2022-07-051-1/+4
| | | | | | | | | | | | | We have two bugs here, one failing most tests, and one crashing. Skip the entire test on macos until fixed. Task-number: QTBUG-101744 Task-number: QTBUG-103354 Change-Id: Ib56921b8d075ab5874f68fe8c0815c6c0155b5de Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit b257ca2411745deaf8525f88f9bb0707f948763a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Various clean-upsPeter Varga2022-06-241-0/+2
| | | | | | | Change-Id: I53e04a247a25149d9f29135484c0528c706de7d8 Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 8c113ad54b39d26c011a8a127b8dac6c401a9ef3) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Use SPDX license identifiersLucie Gérard2022-06-23140-4077/+280
| | | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. License files are organized under LICENSES directory. Task-number: QTBUG-67283 Change-Id: I869ffda1080e283f231eb0dc4477b260f2054d99 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit 9b9d789fcb8f63a8998f1eefe44f2a1c8156c362) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Support HTML5 <datalist> elementPeter Varga2022-06-205-14/+373
| | | | | | | | | | | | | | | | | | The datalist uses Chromium's autofill component to fetch and filter predefined options in the list and autocomplete the field with the selected option. Autofill component is added to build and bound to WebEngine. All the unnecessary autofill features for datalist are supposed to be disabled: payment/credit card support, password manager, save profile data, store suggestions in database etc. Custom popups for the dropdown are implemented for Widget and Quick. Scrolling in dropdown is not implemented in this change. Fixes: QTBUG-54433 Change-Id: I155d02d6dbc9d88fbca4bc5f55b76c19d0ba7a9d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 19c6b0a22f20a33c8c1fd4bdea29468fa8b4e10e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Test local, secure and file redirectsAllan Sandfeld Jensen2022-06-203-30/+178
| | | | | | | | Task-number: QTBUG-99207 Change-Id: I28a3d06f97c0973ccc0f23bd90de58e89b19eb7a Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> (cherry picked from commit e2d3beb65653bb96342a80b436d8935e903fdd70) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Prove that the service worker works with otr profileMichal Klocek2022-06-143-10/+56
| | | | | | | | | | Check registration installation and activation of service worker and add basic message ping pong test. Change-Id: Ia446553ccbc62b45a5d6313cbbdf15108adcdd36 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 10b4b06d28dbeb0de67edcb94eb85df4d70e4f55) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update ChromiumAllan Sandfeld Jensen2022-06-131-1/+1
| | | | | | | | | | | | | Submodule src/3rdparty 6559e00a3..88398c89a7b: > Fix broken bundled zlib for cross compilation > FIXUP: Fix url_utils for QtWebEngine > Make sure we do not compile minizip from 3rdparty > Trim down some dependencies of push messaging Change-Id: I3062f536fd144d00f72ea783ddcc56931a46a98f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit f5207d2012efe408f178496b2023d822b33a6474) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Avoid extra window after change of pageAllan Sandfeld Jensen2022-06-111-0/+1
| | | | | | | | | | A widget created for an item in a viewless page, still needs to be tracked as a widget. Change-Id: I9d571916b28b1cb2b8bd184d008255b9af105c33 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> (cherry picked from commit d12adcd84d9246e029b9a8340da4545a1f1797ec) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Revert "Skip tst_UIDelegates::contextMenu on macOS"Shawn Rutledge2022-06-111-3/+0
| | | | | | | | | | | | This reverts commit af4f03f51fc647c48968e149799cd35ab161dc55. Reason for revert: crashes anyway, somehow Task-number: QTBUG-103354 Change-Id: I6f3119f855ce485668d9541c323dee947df93b60 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit a4099cdd2aa657e75dfa27ab06247052254920bc) Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Do not reset favicon for same document navigationsPeter Varga2022-06-112-0/+69
| | | | | | | | Fixes: QTBUG-103735 Change-Id: Iee0c09cde16a825097b7c1c014655476989922c0 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit c5de1b21232c7114b27e42fa8c15cb323d256e47) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Switch from QT_NO macros to feature checksAllan Sandfeld Jensen2022-06-103-5/+7
| | | | | | | | | | | | This is safer by ensuring we are checking for a feature that is defined. For some reason, the openssl feature is a private feature, so we need to include the private header to access it. Change-Id: Idf7f3baba33e5188f206f5be1b8a0bfd75e79d03 Reviewed-by: Marc Mutz <marc.mutz@qt.io> (cherry picked from commit be4c684be7c2fa91f7df3d7cccfb6999aecfc967) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Create a RWHV delegate in coreAllan Sandfeld Jensen2022-06-104-4/+28
| | | | | | | | | | | This is adapting the Quick code for shared use with widgets, and allows us to use it from QWebEnginePage. Fixes: QTBUG-96377 Change-Id: I3f09c1a949eff86d80fbe6c513dc66e3f9f2f611 Reviewed-by: Michal Klocek <michal.klocek@qt.io> (cherry picked from commit 5d1ef38f9f6815807596d0606cf7ed06b7930aac) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* unblacklist passing tests 2022Anna Wojciechowska2022-06-051-12/+0
| | | | | Change-Id: I3eec851a59e49c700945268c1421d18f4868d3c5 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix issues in PdfLinkDelegateShawn Rutledge2022-06-041-4/+4
| | | | | | | | | | - gesturePolicy must be set to take an exclusive grab, to avoid letting events propagate to another TapHandler in TableView - behavior was incorrect on the touchscreen - fixed doc warnings about the undocumented link arguments Change-Id: Ic438383b6b6d67936ce2b88b84ef131f41e0d2fb Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Add PdfLinkDelegate instead of link decoration style propertiesShawn Rutledge2022-06-041-0/+193
| | | | | | | | | | | | | | | | This simplifies PdfStyle somewhat. PdfLinkDelegate could still be replaced or augmented via file selectors, but we don't expect to need to, since link delegates are already non-visual. [ChangeLog][QtPDF] A PdfLinkDelegate will now be instantiated on top of each hyperlink in the PdfMultiPageView, PdfScrollablePageView and PdfPageView components, for event handling and to provide tapped() and contextMenuRequested() signals. It is non-visual by default, but can be customized, for example to draw underlines under hyperlinks if the PDF documents are not expected to have them already. Change-Id: Ib3726e7220a0c3858db564ca8d53a04625a11950 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>