summaryrefslogtreecommitdiffstats
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Add spellchecker feature to new config systemMichal Klocek2016-11-141-1/+1
| | | | | Change-Id: I35a5c815c9f2b3ebacb5991ba6645641b17db2db Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Remove RequestType prefixMichal Klocek2016-11-021-3/+3
| | | | | | | | Removes RequestType prefix from FormValidationMessageRequest's RequestType enumeration members. Change-Id: I51b7eb77b0bae2a8d3109e3ee3b7ea42349b211c Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Add qtquick customdialog exampleMichal Klocek2016-11-0139-0/+2434
| | | | | | | | | The example shows how to create and use custom dialogs instead of webengine's default dialogs. Task-number: QTBUG-56063 Change-Id: I440305b2d4357d2b47c6b5a1a821b25c71221aa2 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Update spellcheck api to support multiple languagesMichal Klocek2016-10-291-3/+3
| | | | | | Task-number: QTBUG-56074 Change-Id: I2a66e91dd4ed1026e5ab2539cfd3f9094263b48c Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Fix spellchecking for macOSAlexandru Croitor2016-10-173-11/+40
| | | | | | | | | | | | The change fixes spellchecking to work on macOS. A new WebEngine configure option is available to allow spellchecking on macOS to use either Hunspell like the other platforms, or the native spellchecker that comes with the OS. The default is to use Hunspell. Task-number: QTBUG-53135 Change-Id: I3e45b2e0d728b1bf2659c35f3d0a042b0ecd6239 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* demobrowser: Fix compilation warningPeter Varga2016-10-071-0/+2
| | | | | Change-Id: I283365c72d351e62bc749cbc60e06472e52255ec Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* MarkDownEditor: Hide context menuKai Koehne2016-10-042-2/+8
| | | | | | | | Most actions do not make sense. A custom context menu might be good for text actions, but would require reimplementing QWebEngineView. Change-Id: Idf94939c16469e1dcee96d9ecfd0eb5309589fdd Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* RecipeBrowser: Hide context menuKai Koehne2016-10-042-2/+8
| | | | | | Change-Id: Ia7438535398aa9ae39d0c49e244c4cde05a55b89 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Fix memory leak on printAllan Sandfeld Jensen2016-09-231-1/+1
| | | | | | | We need to delete the QPrintDialog. Change-Id: I959f963ba2e44091acb0c762ac680037bccc5b43 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Add recipebrowser exampleAlexandru Croitor2016-08-3127-0/+1460
| | | | | | | | | | | | The example uses WebEngineView and Qt Quick Controls 2 items to demonstrate how to write a small hybrid QtQuick / HTML application, and also shows the usage of the new focusOnNavigationEnabled setting. Task-number: QTBUG-52999 Change-Id: I1813a658a2f46e90f9ca4e8229a8c8fbb6590248 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Add printing on a QPrinter to the demobrowserMichael Bruning2016-08-282-11/+35
| | | | | Change-Id: I307103956bf50469a5c4cbe3656f655925f55653 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Adjust webengine to the qtConfig() changes in qtbaseLars Knoll2016-08-231-1/+1
| | | | | Change-Id: I907f6ea73a1d707eda536764c4b0b2edea49a963 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-08-0514-11/+68
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also blacklist tst_QWebEnginePage::comboBoxPopupPositionAfterChildMove() and comboBoxPopupPositionAfterMove(). Conflicts: .qmake.conf src/3rdparty src/core/render_widget_host_view_qt.cpp src/core/resources/resources.gyp src/webengine/doc/src/qtwebengine-platform-notes.qdoc src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp src/webenginewidgets/render_widget_host_view_qt_delegate_widget.h tests/auto/widgets/qwebenginepage/BLACKLIST tests/auto/widgets/qwebenginepage/tst_qwebenginepage.cpp tools/qmake/mkspecs/features/functions.prf Task-number: QTBUG-55158 Change-Id: I1d73ac9b3ca5293ad3c7e3a56f4c395da930e6f4
| * Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-08-022-4/+40
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty src/core/resources/resources.gyp src/webengine/doc/src/qtwebengine-overview.qdoc src/webenginewidgets/api/qwebenginepage.cpp src/webenginewidgets/api/qwebenginescriptcollection.cpp src/webenginewidgets/api/qwebenginescriptcollection_p.h tests/auto/widgets/qwebenginepage/BLACKLIST And readded newly in 5.6 enabled tests to the BLACKLIST. Change-Id: I4ab1fc54ebfaaf940df81b0d8d6bdd15cae8b7c4
| | * Fixup Back/Forward short-cutsAllan Sandfeld Jensen2016-07-222-4/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove backspace short-cut, Chromium will already handle that if it is standard on the platform. Also we were not triggering on Back/Forward buttons due to those being mapped to prev/next tab item in Qt. Task-number: QTBUG-54546 Change-Id: I9a4f48c718c5685ca9ca1b032d8b04409ac622ca Reviewed-by: Jesus Fernandez <jesus.fernandez@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-06-2712-7/+28
| |\| | | | | | | | | | Change-Id: Ic6686df8f82f710a3441501b7eeaffe69fbcbdf7
| | * Remove infinite loop when loading history.Michael Bruning2016-06-202-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | Add a flag to let checkForExpired remove the entries directly. Task-number: QTBUG-54222 Change-Id: Iddac9e50f645d74b95d0ea13ed76d7f858ddd137 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Make all examples high-dpi awareKai Koehne2016-06-2010-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | Setting the Qt::AA_EnableHighDpiScaling attribute makes sure that the scrollbars are scaled, and that the default zoom level is sensible. Task-number: QTBUG-54113 Change-Id: I0ae7eb97cb9e2824e7f9b92d77cf2986cac66685 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add View Source API and make the feature available from context menuPeter Varga2016-08-022-16/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][QtWebEngineQML][QQuickWebEngineView] View Source feature is now supported [ChangeLog][QtWebEngineWidgets][QWebEnginePage] View Source feature is now supported Change-Id: Icc16da71fc6ec95880897fc9744dd8be8c004e00 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add back "Open Link in New Tab" to Demobrowser's context menuPeter Varga2016-07-132-6/+1
| | | | | | | | | | | | | | | Change-Id: Ied45cf010aef87e319a01274399938cff7c1a53e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add widget based spellchecker exampleMichal Klocek2016-07-0217-1/+618
|/ / | | | | | | | | | | | | | | | | | | This example demonstrates how to convert 'dic' dictionary files into 'bdict' binary format using qwebengine_convert_dict tool. It shows how to implement language selection. It adds two dummy dictionaries. Change-Id: Iffc23a0ed4e51cbc749f666c8f565fafb3739a9b Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-06-112-1/+1
|\| | | | | | | Change-Id: Ib010ede9756fb02992a3276ae7ec90ef1ab56a00
| * Fix build of webenginewidgets/simplebrowserJoerg Bornemann2016-06-101-0/+1
| | | | | | | | | | | | | | | | | | Add missing include to fix error C2027: use of undefined type 'QDebug' on MSVC. Change-Id: Icc62cdf36f417f30691445ab4994b822c8e37db9 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * Do not trigger find on slash keyAllan Sandfeld Jensen2016-06-031-1/+0
| | | | | | | | | | | | | | | | Application short-cuts override the passing the keys to WebCore, and makes it impossible to type '/' in form elements. Change-Id: I7df99547f99a3a0703d98d19d3ccdb23de0641ce Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Enable plugins in the simplebrowserAllan Sandfeld Jensen2016-06-071-0/+3
| | | | | | | | | | | | | | | | This makes it possible to also test flash from simplebrowser. Change-Id: I94677383fdbea4a723432ea6811ee72314c019fd Reviewed-by: Alexandru Croitor <alexandru.croitor@theqtcompany.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | demobrowser: Fix meta object system warningJoerg Bornemann2016-05-242-3/+1
| | | | | | | | | | | | | | | | | | | | Do not redefine QWebEngineView::iconChanged. This fixes the following warning: QMetaObject::indexOfSignal: signal iconChanged(QIcon) from QWebEngineView redefined in WebView Change-Id: I2489bfcf9379200f9bfa24345b56679f138894fe Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | demobrowser: Remove connection to non-existent signalJoerg Bornemann2016-05-241-2/+0
| | | | | | | | | | | | | | This amends commit 213fbe76. Change-Id: Ie5ca9f7713b0653e0e5241eb3e99644425a3b1e3 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.6' into 5.7.0Michael Bruning2016-05-233-4/+21
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty src/core/browser_context_adapter.cpp src/core/web_contents_adapter.cpp src/webengine/doc/src/qtwebengine-platform-notes.qdoc tests/auto/widgets/qwebenginepage/BLACKLIST Change-Id: I768fc954a9a2147fc3669961286163a0a824def3
| * Merge 5.6 into 5.6.1Oswald Buddenhagen2016-05-122-1/+6
| |\ | | | | | | | | | Change-Id: I96aa7487c341f40c74832f00bc72995d25969329
| | * add missing example installOswald Buddenhagen2016-05-102-1/+6
| | | | | | | | | | | | | | | Change-Id: Ifee9bb458de2c15760da21938b5e5bb598936161 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
| * | [Simplebrowser] Fix command line option parsing.Alexandru Croitor2016-05-111-3/+15
| |/ | | | | | | | | | | | | | | | | | | | | | | | | Passing just command line options to Chromium prevents loading of the initial startup url. This happens because the startup url is overridden by the last command line argument, which happens to be a Chromium option, thus an invalid URL. Fix consists in using the last command line argument as the loading url only if it can be parsed as valid url. Change-Id: I3615ef57b6eddc5098de79cba1b1ba6b6af193ef Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Change messagebox in simplebrowser exampleMichal Klocek2016-05-091-2/+5
| | | | | | | | | | | | | | | | In case of render epic fails, let the user leave the loaded page with dignity. Change-Id: I27f692fc0bb181c1d4f7ce43f5772d5573d7e385 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-05-096-59/+93
|\| | | | | | | Change-Id: I2843a633721212850db77c772caf24e0ea82b450
| * Quick fix for not working history in demobrowserMichal Klocek2016-05-044-50/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current implementation of history manager seems to be not straight forward. To display history we use QList to keep history items plus model adapter in form of HistoryModel (QAbstractTableModel) plus HistoryFilterModel to avoid duplication, plus HistoryTreeModel to make a tree view with split for dates, plus TreeProxyModel on top to enable sorting. This approach unfortunately falls apart when items should be deleted from the model by treeView. This ends badly with corrupted cached values. This fix removes history items using history manager. It also abandons HistoryTreeModel since frequent sourceReset calls make it unusable. If split for dates it desired the better approach would be to implement history tree model already at HistoryManager level to avoid unmaintainable code. Task-number: QTBUG-49913 Task-number: QTBUG-50255 Change-Id: Ic9cebb52b623bd453119e11b5e907eaa90609e34 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| * [Demobrowser] Fix command line option parsing.Alexandru Croitor2016-05-042-9/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Passing just command line options to Chromium prevents loading of the initial startup url. This happens because the startup url is overridden by the last command line argument, which happens to be a Chromium option, thus an invalid URL. Fix consists in iterating through the command line arguments, until a non-option argument is found (doesn't start with a dash), and use that as the startup URL. Change-Id: Ibe2946b25b2e023c094a85e50d2ccbd5bfce2977 Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* | Replace print dialog with a custom one for printing to pdf.Michael Bruning2016-05-025-13/+349
| | | | | | | | | | | | | | | | The standard pdf print dialog does not work on OS X and Windows. Task-number: QTBUG-53016 Change-Id: Ic9dd1a1603e1cdbd82fef095cc660814bcd8c98e Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-04-255-20/+7
|\| | | | | | | Change-Id: I329397621f19ba3890be5daf44a6bb2d668ad2d8
| * Fix contextMenu handling in examplesMichal Klocek2016-04-212-5/+8
| | | | | | | | | | | | | | | | Adds missing deleteLater on close Change-Id: Id337856f138e0d38f0c72d3962ccac309d36c73e Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
| * demobrowser: Remove unused loadingUrlJoerg Bornemann2016-04-212-18/+0
| | | | | | | | | | | | | | | | | | Remove the unused m_loadingUrl member. Remove the loadingUrl signal that was forwarded to urlChanged. QWebEngineView already emits urlChanged. There's no need to do this twice. Change-Id: Ib9734c5b1571745f7b82b4e5f2bc92c7f1d8f51c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
| * demobrowser: Fix HistoryManager::clearJoerg Bornemann2016-04-211-1/+1
| | | | | | | | | | | | | | | | Clear the model before saving. Otherwise the cleared history will appear again after restarting the demobrowser. Change-Id: I79f939c1f1e8ee993127d139cefe7f5818ce593c Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| * demobrowser: Fix precision of progress bar renderingJoerg Bornemann2016-04-201-1/+1
| | | | | | | | | | | | | | The progress bar never reached the 100% mark. Change-Id: Id87bdb27f882d0d77ed0ad590e2c2278ce6fba92 Reviewed-by: Michael Brüning <michael.bruning@theqtcompany.com>
* | SimpleBrowser: Use new QWebEnginePage::icon APIKai Koehne2016-04-207-82/+19
| | | | | | | | | | | | | | Change-Id: I38d16a57116517aee21f6f84c5fca82192cb1572 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>
* | Add QQuickWebEngineFaviconProviderPeter Varga2016-04-201-0/+1
| | | | | | | | | | | | | | | | | | The new QQuickImageProvider subclass is used to access downloaded icons from the FaviconManager via the Quick API. Change-Id: I6a52d3c737b2260cf480167764a931915cd99cab Task-number: QTBUG-51179 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* | Merge branch '5.6' into 5.7Allan Sandfeld Jensen2016-04-182-4/+7
|\| | | | | | | Change-Id: I490e0ee46d3ff040ca26426feb7e4d6ef7098f94
| * SimpleBrowser: Fix loading iconKai Koehne2016-04-151-1/+1
| | | | | | | | | | Change-Id: I008b649b43069978b6ce19b2faf5a557dd67c756 Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>
| * Demobrowser: Fix black screen after exiting fullscreen mode on OS X.Alexandru Croitor2016-04-151-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When exiting fullscreen while viewing a full screen video, the video is replaced with a black screen, and does not switch back to the initial page. This happens when hide() is called on a native window while being in fullscreen, which hides the window, but does not exit full screen mode, thus showing a black screen. The workaround fix consists of two parts: 1) Make sure to delete the fullscreen window object, to release the OS virtual screen it occupies (visible in mission control as a black rectangle). 2) Hide and show the main page window, to force exit fullscreen mode. Change-Id: I364d4427e84957ed97f57a14e2cfc2c95aed6f48 Task-number: QTBUG-52058 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* | Remove "Save Page" web action from the standard context menuJoerg Bornemann2016-04-131-4/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The SavePage web action is only useful if the user code reacts on the downloadRequested signal. Also, having SavePage available is not useful for e.g. hybrid applications. Extend the demobrowser example to show how to add the SavePage web action to the context menu. Change-Id: I979bcd9f5a25d2cae07ef819663afde17784440b Task-number: QTBUG-52370 Reviewed-by: Michael Brüning <michael.bruning@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* | Remove default values for printToPdf callbacks and unify API.Michael Bruning2016-04-131-1/+1
| | | | | | | | | | | | | | Adds default QPageLayout values. Change-Id: Ibf2964ecd86350a51d682e385973f830ac4347a7 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | Fix recentlyAudible Widgets and Quick API.Alexandru Croitor2016-04-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Rename all uses of wasRecentlyAudible to recentlyAudible. Add missing recentlyAudible properties. Change QtQuick slots to simple functions. Change affected demobrowser example. Adjust documentation for the API. Change-Id: I5a6f7b8384c0b7e34afaa5c412a5543c210d3ef9 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>
* | SimpleBrowser: Handle WebBrowserBackgroundTabKai Koehne2016-04-071-0/+4
| | | | | | | | | | | | | | | | | | | | | | Fix compilation warning: qtwebengine/examples/webenginewidgets/simplebrowser/webview.cpp:131: warning: enumeration value 'WebBrowserBackgroundTab' not handled in switch [-Wswitch] switch (type) { ^ Change-Id: I590207c56525db740e62403b6cb949c6281d765c Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>