summaryrefslogtreecommitdiffstats
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Shorten names of permission classesJüri Valdmann2018-04-133-9/+9
| | | | | | | | | | | Remove 'permission' from class and signal names, so e.g. QWebEngineQuotaPermissionRequest becomes QWebEngineQuotaRequest and quotaPermissionRequested becomes quotaRequested. Rename the internal controller classes to public name + "Controller". Change-Id: I247714ab0a2880adbf4ed8ee68f1b78838ae7a14 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Adaptations to form validationAllan Sandfeld Jensen2018-03-155-77/+9
| | | | | | | | Form validations messages has moved entirely to being done by Blink. Change-Id: I6742c111fc59f0baba75b8b37f5d0ec9ae2fb920 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Rename protocol() to scheme() in QWERPHPermissionRequestJüri Valdmann2018-03-082-2/+2
| | | | | | | | | Scheme refers to a part of a URL. Protocol refers to a formal standard for communication over a network. Therefore scheme is more accurate here, since registerProtocolHandler only defines simple aliases. Change-Id: I71a1511aa92e41c3e3aca4c0403f54af6d91c563 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Add ninja icon to simplebrowserMichal Klocek2018-03-063-0/+10
| | | | | | Task-number: QTBUG-65944 Change-Id: Ie30f2088ca3be90a75d3592433f0c6cf56381dde Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Fix some QDoc warningsJüri Valdmann2018-03-022-7/+2
| | | | | Change-Id: I1af130982db78184fca763dd61568f350d8a2d42 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Prevent Qt Quick Compiler from removing qrc Javascript source codeAlexandru Croitor2018-02-203-0/+11
| | | | | | | | | | | | | | | | | By default whenever a Qt application is built with Qt Quick compiler, it will scan all qrc resources for javascript files, generate corresponding C++ code, and remove the original JS code. This is problematic for web pages that are loaded in WebEngine because the pages won't be able to access the javascript code, and silently fail (or if you are lucky, you will get some unrelated "can not be found" error). Use the undocumented QtQuick Compiler QTQUICK_COMPILER_SKIPPED_RESOURCES qmake variable to specify that Javascript source code found in qrc files should be left as is. Task-number: QTBUG-66155 Change-Id: Ib1dc744901baddd9e0c17c53db1ffede5c31e544 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add support for registerProtocolHandlerJüri Valdmann2018-02-133-0/+24
| | | | | | | | | | | | | | | | | | | Extend initialization of URLRequestContextGetterQt to create a content::ProtocolHandlerRegistry for each content::BrowserContext and add the registry's URL request interceptor to the front of the interceptor chain. Implement methods in WebContentsDelegateQt to add/remove protocol handlers to/from the ProtocolHandlerRegistry. Add permission request signal and classes for core, quick and widgets. Add widgets autotest. Add signal handlers to quicknanobrowser and simplebrowser. Task-number: QTBUG-62783 Change-Id: I808e7eb9a1cb4d7216686deed4895de14fe46310 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Merge remote-tracking branch 'origin/5.10.1' into 5.11Liang Qi2018-02-121-1/+1
|\ | | | | | | Change-Id: If971fbfcb158c921e2328dfcdef3bd3322f30c4b
| * Merge remote-tracking branch 'origin/5.9' into 5.10.1Michael Brüning2018-02-051-1/+1
| |\ | | | | | | | | | | | | | | | | | | Conflicts: src/core/web_engine_context.cpp Change-Id: I004994a0ab6dbc54370b6973de1816cd673154c6
| | * Fix quicknanobrowser to use unique storage locationMichal Klocek2018-02-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not use "Default" as custom profile, global profile uses "Default" as storge name, this ends up on creating two browser context adapters using the same files. Change-Id: I298fa87ee14c5c83a15683710ba3fbb29c201714 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.10' into dev" into ↵Allan Sandfeld Jensen2018-02-061-3/+3
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.10' into devAllan Sandfeld Jensen2018-02-021-3/+3
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/core/download_manager_delegate_qt.cpp src/core/download_manager_delegate_qt.h src/core/render_widget_host_view_qt.cpp src/core/web_contents_adapter.cpp src/webengine/api/qquickwebengineview.cpp tests/auto/widgets/qwebenginedownloads/tst_qwebenginedownloads.cpp Change-Id: I2308414ce257ae5bb0fc9f6493aa111a267ff39b
| | * | Fix FDL license headerKai Koehne2018-01-231-3/+3
| | | | | | | | | | | | | | | | | | | | Change-Id: I8d7cf992d1f51cc82168d5e01bbe4c062be09992 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* | | | Make default context menus look more like chrome's oneValentin Fokin2018-02-022-20/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Implement EditFlags in ContextMenuData - Unify Quick and Widget default context menus - Add workaround for QTBUG-65044 - Update the SimpleBrowser example and its documentation [ChangeLog][QtWebEngine][QtWebEngineWidgets] Unify Quick and Widget default context menus Task-number: QTBUG-62414 Change-Id: I16a380f9f17e160497dfb8ac9c172341eb28c6c8 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | | Unset inspectedView when devTools are not visibleSzabolcs David2018-02-011-1/+1
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | The webview in quicknanobrowser shows devtools related information, for example: resolution appears in the top right corner when resizing the window. Change-Id: I494450f4976155f995bcb7e843d82ba081d91493 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into devAllan Sandfeld Jensen2018-01-171-136/+63
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/webengine/api/qquickwebengineview_p_p.h src/webenginewidgets/api/qwebenginepage_p.h tests/auto/quick/qmltests/data/TestWebEngineView.qml Change-Id: Id2acc92e8d0364bdaaf5a63ea2d2cb9cd533ade3
| * | stylesheet example: Make dialog adapt to different sizesKai Koehne2018-01-091-136/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The old code had fixed pixel sizes, which broke with high dpi and different font sizes. Also, simplify the hierarchy by replacing the top widget and the nested layouts with a Frame and grid layout. Task-number: QTBUG-64816 Change-Id: Ifeb458fb5d5e709e8add9c77c274dee13307d4c6 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | | Fix compilation of simplebrowser exampleKai Koehne2018-01-161-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously qstyle.h was included indirectly through the uic generated code, but this got changed in qtbase commit 058474884c2505a8a0. Task-number: QTBUG-65793 Change-Id: I56a1cd045d53b268999d728f6907ee8d952ba6e9 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | | Introduce devtools frontendAllan Sandfeld Jensen2017-12-069-34/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Makes it possible to use devtools without using the remote-debugger Task-number: QTBUG-47899 Task-number: QTBUG-50725 Task-number: QTBUG-50766 Change-Id: Id32e13f773372d9917599ebbb64ab4af61bbf1d8 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.10' into dev" into ↵Allan Sandfeld Jensen2017-11-302-2/+2
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.10' into devAllan Sandfeld Jensen2017-11-292-2/+2
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/core/web_event_factory.cpp src/core/web_event_factory.h src/webengine/render_widget_host_view_qt_delegate_quick.h Change-Id: Ic43787e2689c81b501ed395a990190eb67d83a2b
| | * | Add 'webengine' prefix to configure features, tests, libraries, etcAlexandru Croitor2017-11-122-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is done to make sure there are no conflicts with features in other modules, because they all share a global namespace. Change-Id: I95b3b7fadd8ffc2979ee3aad2234ee543d57c7d8 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | | | Expose an option to hide internal IP addresses from WebRTCAllan Sandfeld Jensen2017-11-291-0/+8
|/ / / | | | | | | | | | | | | | | | Task-number: QTBUG-57505 Change-Id: I8d8f906311ce94b2d9df67cb4479b70c8961c3a6 Reviewed-by: Viktor Engelmann <viktor.engelmann@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-11-0310-21/+94
|\| | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty Change-Id: Ie6b1922db2269e0e0561022162228a7c8609c9ba
| * | Change spellchecker-related private features into public onesAlexandru Croitor2017-11-022-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is done because qtConfig(spellchecker) is present in an example .pro file, and thus "spellchecker" should be a public feature. Change-Id: Idff977b8d0835b049c4c19dc42c1475d2c55c323 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
| * | Remove pointless inclusions of qtwebengine-config.priAlexandru Croitor2017-11-022-2/+0
| | | | | | | | | | | | | | | | | | | | | Only projects which are built before the actual module need to do that. Change-Id: Ia8b071a627bd39c5df4600877b6873f308cbf690 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * | Merge branch '5.9' into 5.10Allan Sandfeld Jensen2017-11-018-17/+92
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/core/core_module.pro src/core/delegated_frame_node.cpp src/core/surface_factory_qt.cpp src/webenginewidgets/api/qwebengineprofile.cpp tests/auto/widgets/widgets.pro Change-Id: I92f3ef4eee779afef6c5381a7aa8b551417c1b17
| | * Add off-the-record mode to simplebrowser exampleJüri Valdmann2017-10-257-15/+86
| | | | | | | | | | | | | | | | | | Change-Id: I9b87f870c4f6ad63142bc0497722b0c95095cd6b Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Build recipebrowser only if QtQuickControls2 is availableJoerg Bornemann2017-10-201-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | This fixes the examples build if the QtQuickControls2 is unavailable. Task-number: QTBUG-63904 Change-Id: I2d5ff0920cc960af6df556543fd77abdc21d4a8a Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into devAllan Sandfeld Jensen2017-10-275-108/+153
|\| | | | | | | | | | | Change-Id: Ibc1c881a67bf088ba6fb044e2553c74c7e9e24ca
| * | Fix license headers in stylesheetbrowser exampleKai Koehne2017-10-205-108/+153
| | | | | | | | | | | | | | | | | | | | | | | | Actually use the BSD license from header.BSD. Change-Id: I89e762a0cedcf02ee3732c62bc7869757aa9f271 Reviewed-by: Szabolcs David <davidsz@inf.u-szeged.hu> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | Merge branch '5.10' into devAllan Sandfeld Jensen2017-10-1379-226/+873
|\| | | | | | | | | | | Change-Id: I3a411e4019a5ec2f7d1a967b62a00ad7cf92f6f4
| * | Merge "Merge remote-tracking branch 'origin/5.9' into 5.10" into ↵Allan Sandfeld Jensen2017-09-2979-217/+853
| |\ \ | | | | | | | | | | | | refs/staging/5.10
| | * | Merge remote-tracking branch 'origin/5.9' into 5.10Allan Sandfeld Jensen2017-09-2979-217/+853
| | |\| | | | | | | | | | | | | Change-Id: I7094e85a7770303a2ae30baccbc484c04f33600e
| | | * Fix license header for examplesKai Koehne2017-09-20125-260/+896
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-60006 Change-Id: Ie1604aed3d5a9ba566e898eae232227ba340bfaa Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | | * Fix not working "OpenFile" in simplebrowserMichal Klocek2017-09-151-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I3e9baf47d0491f0031a9a9864eecd12b09773eff Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| * | | Change the minimal example to be minimally usefulAllan Sandfeld Jensen2017-09-283-9/+20
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | Open the first non-flag argument if one is given Fixes up simplebrowser to act similarly Change-Id: I40270a0f7bc06ce52117f23f7ccbdd743d3d97f6 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Implement geometryChangeRequested signal in the Quick APISzabolcs David2017-10-052-6/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Chromium includes the size of the frame in the requested geometry, but QWindow::setGeometry() and the related properties of QML Window expect a size without frame. This patch - fixes the geometry handling in Demobrowser example. - implements a new signal in the QML API which sends both frameless and extended geometries to the application, because QML doesn't have capability to determine the size of the frame and handle extended geometry correctly. Task-number: QTBUG-51181 Change-Id: I8595593aecca33d7cd46986c7abbad0cc7c18ec2 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-09-222-7/+12
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/webengine/api/qquickwebenginesettings_p.h src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc Change-Id: I9cac7059557084a575af02782af886f55a8d404f
| * | Remove WEBENGINE_CONFIG from configureMichal Klocek2017-09-202-7/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not store flags in qmake.cache with WEBENGINE_CONFIG. Use directly qtConfig values insted. This makes configuration more consistent, simplifies handling and avoids passing values from qtConfig to WEBENIGNE_CONFIG, which then were passed to gn. [ChangeLog] Removing WEBENGINE_CONFIG from qtwebengine configure Change-Id: I1a773fb4bff6d67ad75c237d044998051d92ab51 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* | | Support Quota Management APISzabolcs David2017-09-131-1/+8
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Expose navigator.webkitPersistentStorage.requestQuota() calls to the API layer as a permission API. It allows the users to accept these requests and specify a quota for persistent storage. https://developer.chrome.com/apps/offline_storage#managing_quota [ChangeLog] navigator.webkitPersistentStorage.requestQuota() calls were rejected by default and now they will emit signal quotaPermissionRequested in both WebEngineView and QWebEnginePage. Task-number: QTBUG-56354 Change-Id: Id192577ffb403694d3051414744ded89bbfd2aa8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Fix documentation of FullScreenRequestSzabolcs David2017-08-231-2/+2
| | | | | | | | | | | | | | | | It was registered as FullScreenRequest in plugin.cpp, not WebEngineFullScreenRequest. Change-Id: Ib9eec950a0f54aad2dbc31e54d6d5c6a6838ac65 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into devAllan Sandfeld Jensen2017-08-1453-389/+893
|\| | | | | | | | | | | Includes sha1 bump of src/3rdparty to head of 58-based. Change-Id: I37743c3979c1b6fb21f71eab7048e82f7aa5d78b
| * Fix signal name in simplebrowser example documentationJüri Valdmann2017-08-031-1/+1
| | | | | | | | | | Change-Id: Id3bf1218e43609cdb471e087e2077d4c0c0e5153 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
| * Fix simplebrowser crash on exit while downloadingMichal Klocek2017-08-022-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | On webengine profile destruction all download items in progress are canceled. This triggered stateChanged of QWebEngineDownloadItem which called lambda function on already deleted object. Do not use lambda functions in this case. Change-Id: Ia1d359fe47204baa51f1380d1c3547c28550bc28 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Viktor Engelmann <viktor.engelmann@qt.io>
| * Fix demobrowser to not crash when switching to private browsing modePeter Varga2017-07-311-2/+0
| | | | | | | | | | | | | | | | | | | | Old QWebEnginePage is destructed by the QWebEngineView::setPage() call. No need to destruct it explicitly. Task-number: QTBUG-62147 Change-Id: I8ec33d5df618f69e4acf1667490df4a67dad9a16 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| * Update Simple Browser exampleJüri Valdmann2017-07-1935-354/+750
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Accept downloads and add a downloads list. - Fix toolbar icons being pixelated on hidpi screens by - enabling attribute AA_UseHighDpiPixmaps, and - replacing the 22x22 icons with 32x32 versions. - Move favicon selection to WebView to reduce duplication. - Replace UrlLineEdit with a standard QLineEdit using a QAction for the favicon and setClearButtonEnabled(true) for the clear button. - Fix bug where the "File -> New Tab" action would create background tabs because the QAction::triggered(bool) signal was connected to the TabWidget::createTab(bool) slot with the bool argument having a completely different meaning between the two. - Make the toolbar unmovable. Nobody wants to move the toolbar. - Add tooltips to toolbar buttons. - Add tooltips to the tab bar (page titles). - Stop adding icons to menu items only to disable them right after. Task-number: QTBUG-60655 Change-Id: I10cc0fa82dbf39281bbdbbf9ef901e1b26402f80 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
| * Properly document third party code in examplesKai Koehne2017-07-1317-29/+140
| | | | | | | | | | | | | | | | | | | | | | Move files from marked, markdown.css to a 3rdparty directory, and properly document them with a qt_attribution.json file. Finally, reference the (automatically generated) documentation in the respective examples documentation. Task-number: QTBUG-61706 Change-Id: I8fd3f894e6e81647bc4804df784b1e00b83d12d6 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| * Examples: Add recipebrowser to top-level .pro fileKai Koehne2017-07-131-1/+2
| | | | | | | | | | Change-Id: I7d22a9c2a4f4aed1f364e672985da357158467e7 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Reorder documentation for QtWebEngine dictionary discoveryFlorian Bruhin2017-08-041-9/+2
| | | | | | | | | | | | | | | | | | | | This also adds documentation for QTWEBENGINE_DICTIONARY_PATH from my previous change. Change-Id: I85cd7476c095d5427e2db3a909449838a2362b81 Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>