summaryrefslogtreecommitdiffstats
path: root/src/webengine/api
Commit message (Collapse)AuthorAgeFilesLines
* Document that the Windows version in the user-agent might be wrongKai Koehne2017-09-141-0/+4
| | | | | | | | | | | | | | | Chromium uses GetVersionEx() to determine the Windows version that is reported in the default user agent. GetVersionEx() however always reports "Windows NT 6.2" for newer Windows versions, unless the executable's manifest file marks the newer version as supported. Since this is a common question we document this in the httpUserAgent accessors. Task-number: QTBUG-56472 Change-Id: I4698cd659f5552b92ef925c198f39326fcb936f3 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Set referrer on download requestsJüri Valdmann2017-09-121-2/+4
| | | | | | | | | Note that the Referer header still won't be sent if the download is triggered via an anchor element with the 'download' attribute: crbug.com/455987 . Task-number: QTBUG-61354 Change-Id: I5af971af916b2190756e3e58f19736072a213922 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Call stopFinding, when navigating awayViktor Engelmann2017-07-061-0/+2
| | | | | | | | | | | When one searches for text on one page and then navigates away, results for the search-term are also highlighted on the new page. To stop this from happening, we now call adapter->stopFinding() when we navigate away from a page. Task-number: QTBUG-61506 Change-Id: I09e064d7788b12eae0a67c01e4f5872d94924617 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Merge remote-tracking branch 'origin/5.9.1' into 5.9Liang Qi2017-06-242-4/+0
|\ | | | | | | | | | | | | Conflicts: mkspecs/features/functions.prf Change-Id: I53d65ea49f546c7d4aadfdaff178fd2f3f4cdf11
| * Fix crash when accessibility is disabledAllan Sandfeld Jensen2017-06-232-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | With the no-accessibility feature moved to qtgui-config, we don't always include it where web_content_apapter_client.h is included, which gives it an inconsistent binary layout. Solve it by making the optional method always defined as it doesn't rely on anything from accessibility. Task-number: QTBUG-61200 Change-Id: I65f34ab2b6763f3166b945e700994bd8d019a835 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Avoid using string constructor of QJSValue for byte-arrayAllan Sandfeld Jensen2017-06-191-1/+2
|/ | | | | | | | | | | | | | | We were returning the PDF byte-data as a javascript unicode string using the deprecated ascii cast constructor. This patch changes the behavior to match that of runJavaScript callbacks and uses a script value over QVariant. [ChangeLog][QtWebEngine] The callback version of WebEngineView::printToPdf is now called with a proper bytearray result instead of PDF byte data in a javascript string. Change-Id: I71565623465c54052568bb5ff34665baaa93e187 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Store Target URL in WebContentsDelegateQt::WebContentsCreatedViktor Engelmann2017-05-302-4/+3
| | | | | | | | | | | | | | | | | | | | | | | When opening a new window, for example by using the JavaScript method window.open('...'), the requested url is not stored in the content::WebContents object we get in WebContentsDelegateQt::createWindow (at this point, it should at least be stored as pending request in the WebContents' NavigationController, but it is not). Because of this, the QQuickWebEngineNewViewRequest object in QQuickWebEngineViewPrivate::adoptNewWindow never contained the url. We have access to the target url in WebContentsDelegateQt::WebContentsCreated, so now we store it there in a new property m_initialTargetUrl, from where WebContentsDelegateQt::createWindow takes it and passes it to WebContentsAdapter::adoptNewWindow as a new parameter. [ChangeLog][WebEngine] Fix WebEngineNewViewRequest::requestedUrl being empty when opening window from JavaScript Task-number: QTBUG-57675 Change-Id: I7e2c7866899baade17ce2517e6be8b2b2709699e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Merge remote-tracking branch 'origin/5.9.0' into 5.9Allan Sandfeld Jensen2017-05-291-0/+2
|\ | | | | | | Change-Id: Iba6114263488d6bf84b255b38182904dc5880386
| * Fix crash on exit with url-request interceptorsAllan Sandfeld Jensen2017-05-081-0/+2
| | | | | | | | | | | | | | | | | | | | If the interceptor is the child of the profile, they will be deleted with the API profile which is before the underlying browser-context, they should therefore be unset from the browser context first. Task-number: QTBUG-60236 Change-Id: I2954e8106863b8b421ef166f6bf8fa79240c95ee Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Show "Follow link" context menu item for links without textJüri Valdmann2017-05-171-1/+1
|/ | | | | | | | The standard context menu currently doesn't have the "Follow link" item for e.g. the image links on https://www.qt.io . Change-Id: I5b9d620135c7a8e65bd95a0ab07a76278e56cad0 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Remove unused qmlRegisterRevision callKai Koehne2017-04-111-2/+0
| | | | | | | | This was used for registering an alternative QtWebEngine.experimental import, which has however been removed since then (a4dcc5b4894aac). Change-Id: I0edd869fcc0057b2c6a4932eb39cb8f739f571bc Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Allow setter methods of WebEngineScript to be called directlyKai Koehne2017-04-101-7/+7
| | | | | | | | The methods got removed from the script API in change bec2be57891f87f2b8bc04. However, this might break existing code. Change-Id: Ibc1b4632ade847953f848b3d1a29a14cab3f035b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Doc: Fix QtWebEngine version numberKai Koehne2017-04-102-3/+3
| | | | | | | | The latest version for Qt Webengine in 5.9 will be 1.5, not 1.6. Change-Id: Ibae42f24f4b7477901923ff0ef5436642599f365 Reviewed-by: Viktor Engelmann <viktor.engelmann@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Mark QQuickWebEngineScript::timerEvent() internalLeena Miettinen2017-03-301-0/+3
| | | | | | | ...to suppress a QDoc error. Change-Id: I11cb449137af06e11ba4e14a14da97d0088f8416 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Doc: Fix link errorNico Vertriest2017-03-281-3/+3
| | | | | | | | qquickwebenginedownloaditem.cpp:368: warning: Can't link to 'interruptReasonString()' Change-Id: Ia77d31851d17808330cfc701691e41eafb8d0aad Reviewed-by: Nico Vertriest <nico.vertriest@qt.io> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* Rename WebCoreVisitedLinksManager to VisitedLinksManagerQtAllan Sandfeld Jensen2017-03-261-1/+0
| | | | | | | | Rename to follow our standard naming. This class was one of our oldest and probably predates our standard naming convention. Change-Id: I32dfbad9611b789ad13114d9692b07045806f7c0 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Merge remote-tracking branch 'origin/5.8' into 5.9Liang Qi2017-03-101-0/+1
|\ | | | | | | Change-Id: I6a39d1ec0ffc0394fbb472ab1df2963ed5c69ec7
| * Clarify JavascriptCanAccessClipboard documentationFlorian Bruhin2017-03-071-0/+1
| | | | | | | | | | | | | | | | | | Chromium always allows copying to clipboard (even when this is disabled) if it's resulting from an user interaction. Change-Id: I0363b892fef6ce015a2f8ae9b89423e1655b516c Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Rework form validation QML testsPeter Varga2017-03-082-5/+0
| | | | | | | | | | | | | | | | | | Use Custom Dialog API instead of Test Support API for testing form validation messages. Moreover, remove the form validation part from the Test Support API. Change-Id: I8ecc80745ddad26f90df413d9a1d04045512af6c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Add FINALs and explicit constructor to QQuickWebEngineScriptSzabolcs David2017-03-071-7/+7
| | | | | | | | | | | | | | Deriving from this class is not expected. Change-Id: I75be53358292fbcdc813fc6d48b21362f1cc3f16 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into 5.9Allan Sandfeld Jensen2017-03-022-1/+3
|\| | | | | | | Change-Id: Iff6ab3c287c58d8ec84a1513460bfce5218e8a61
| * Abort findText when destroying QWebEnginePageViktor Engelmann2017-02-221-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | In the destructor of QWebEnginePage and QQuickWebEngineView, we now call adapter->stopFinding() to suppress callbacks that would cause segmentation faults if a findText request is still active at that point. Task-number: QTBUG-58563 Change-Id: I9d5d8407ee6c28cd76bf6ecf0b62808394e151cd Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
| * Doc: Fix \sa links in the docsLeena Miettinen2017-02-091-1/+1
| | | | | | | | | | | | | | | | - Leave out the class name for the members of the class - Add brackets in the end of method names Change-Id: I5429be5620c5c192aa872d94ab047eebe39a13da Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into devLiang Qi2017-01-301-2/+7
|\| | | | | | | Change-Id: Ic36a80502730d404ab96dfa11ff1eb0ac6eb302d
| * Fix drag position updates for QQuickWebEngineViewJoerg Bornemann2017-01-261-2/+7
| | | | | | | | | | | | | | | | | | Like in the widgets API we must check the result of updateDragPosition and ignore or accept the QDragMoveEvent. Task-number: QTBUG-58037 Change-Id: I26b9e10460eb2840c45698d9444c15ed78c6a1b3 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Make QQuickWebEngineScript a publicly exported classSzabolcs David2017-01-267-180/+283
| | | | | | | | | | | | | | | | | | Now the users can create user scripts when they are working with QQuickWebEngineProfiles in C++. Change-Id: I6ada78b1fc44c3f93589eb468578c330a1be9c6f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Add profile-wide user scripts to the Quick APISzabolcs David2017-01-264-0/+74
| | | | | | | | | | | | | | | | Add API tests in order to try how it works in C++ and QML. Task-number: QTBUG-51034 Change-Id: I1680297e2dafba39dbd4b161f0dbdb14fb6d4243 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into devAllan Sandfeld Jensen2017-01-185-5/+85
|\| | | | | | | Change-Id: If16bfc6f0fbfd0040e13a8a3cbaa113fda10f387
| * Merge remote-tracking branch 'origin/5.8.0' into 5.8Allan Sandfeld Jensen2017-01-165-5/+85
| |\ | | | | | | | | | Change-Id: I6b16bee2d0034865270fb26a5ad93da05b9129fa
| | * Doc: Describe WebEngineLoadRequest::errorDomainLeena Miettinen2016-12-221-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove the WebEngineLoadRequest property doc from WebEngineView::loadingChanged() method docs and add the type name to create an automatic link to the type docs. Fix a typo in the copied ErrorDomain docs. Change-Id: I9798e066d599c75a062bb7f596e4465f32d613b4 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| | * Doc: Fix article in WebEngineSettings::accelerated2dCanvasEnabled docsLeena Miettinen2016-12-221-1/+1
| | | | | | | | | | | | | | | | | | | | | a > an Change-Id: I52cb0b4b7e654d49e864e16fa5270515a73defbe Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| | * Doc: Fix type name to build FormValidationMessageRequest::type docsLeena Miettinen2016-12-221-1/+1
| | | | | | | | | | | | | | | Change-Id: I518cd1af6a6952c5ed325b51fbf34e312d90f594 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| | * Doc: Describe WebEngineDownloadItem.DownloadCancelled enum valueLeena Miettinen2016-12-221-0/+2
| | | | | | | | | | | | | | | Change-Id: I829cd3225858be5c10b00ee5b9c586abb6431111 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| | * Doc: Add docs for the WebEngineNavigationRequest typeLeena Miettinen2016-12-221-0/+59
| | | | | | | | | | | | | | | Change-Id: I41d0d286f25aa28b859271d907f226f5740524e0 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| | * Doc: Fix property name JavaScriptDialogRequest::defaultTextLeena Miettinen2016-12-221-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | The type value was also wrong (should have been DialogTypePrompt), so the text was changed to use natural language insted of code. Change-Id: I5e27749af54a20e722fcd0ccf793cd948151112a Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Add print and pdf feature to new configure systemMichal Klocek2017-01-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently printing and pdf are bounded together. Make compilation optional by adding it as a feature. Fix formatting of embedded_linux.pri Task-number: QTBUG-57731 Task-number: QTBUG-58108 Change-Id: I53a2baea656df0a5b6139365ed06385c9ebc5830 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add methods for textual description of DownloadInterruptReasonViktor Engelmann2017-01-122-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A method was added to get a textual description of a Q(Quick)WebEngineDownloadItem::DownloadInterruptReason. Basically returns the same description from the QDoc entry, but shortened where that was to long. Also moved the ASSERT_ENUMS_MATCHes from download_manager_delegate_qt.cpp to the newly created browser_context_adapter_client.cpp. Task-number: QTBUG-56839 Change-Id: I17c68987b7f12fcaeb71fd27f7ebb35c0ac87bac Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Emit a new signal when printing to a PDF file finishesMichael Brüning2017-01-103-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][Important Changes] Printing to a PDF file will now emit signal the signal pdfPrintingFinished in both QQuickWebEngineView and QWebEnginePage. The boolean passed with the signal to indicate if the printing and saving of the PDF was successful. The path of the created file is also passed to enable the user to map the signal to a print request. Task-number: QTBUG-56677 Change-Id: Ifab5a20b048f33a8cd872165bd4d453b01708037 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | | Merge branch '5.8' into devAllan Sandfeld Jensen2016-12-211-3/+1
|\| | | | | | | | | | | | | | | | | | | | Conflicts: configure.json Change-Id: I658a02de96b45b382f0f6c383964501b794b5eb6
| * | Improve WebEngineDownloadItem documentationKai Koehne2016-12-201-3/+1
| | | | | | | | | | | | | | | Change-Id: Ic5a771df8092ee217fffa2b14ccbd7e539f356f1 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | | QML: Add FINAL, CONST to Q_PROPERTY declarationsViktor Engelmann2016-12-197-59/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | Add FINAL and CONST declarations for every Q_PROPERTY where it is appropriate. This speeds up the execution in QML. Task-number: QTBUG-55912 Change-Id: I67d2223d87aee6bdc639fe6087e3364201f2b1c6 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Make QQuickWebEngineNewViewRequest::requestedUrl readable for QMLViktor Engelmann2016-12-153-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added Q_PROPERTY and getter for QQuickWebEngineNewViewRequest::m_requestedUrl so that it can be read from QML. Task-number: QTBUG-55590 Change-Id: I39e89690f996a1db7c9ce39103429186b26811f8 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.8' into dev" into refs/staging/devLiang Qi2016-12-074-6/+24
|\ \ \
| * | | Merge remote-tracking branch 'origin/5.8' into devMichael Brüning2016-12-074-6/+24
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty Change-Id: Ie7b7c469aa24716816a23b8fe7a8df9f477a9f67
| | * | Merge remote-tracking branch 'origin/5.8.0' into 5.8Michael Brüning2016-12-051-0/+7
| | |\| | | | | | | | | | | | | Change-Id: Ifa26409c722bd4eb373b9ced55f5a58132702ad5
| | | * Fix build when PDF support is disabledPeter Varga2016-12-011-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Wrap unused parameters. Change-Id: Iac550783a55b3fc585db6f7b8241aa2ae89fdf2e Reviewed-by: Michael Brüning <michael.bruning@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * | Wait for loadVisuallyCommitted signal with SignalSpyPeter Varga2016-11-292-2/+6
| | |/ | | | | | | | | | | | | Change-Id: Ic200807246c5feb8e1f33215cbc6194b03765359 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Move the QPrinter and QtWidgets related code out of the PDFium wrapperMichael Brüning2016-11-252-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the actual printing using QPrinter to the WebEngineWidgets part of the API. The printsupport module depends on the widgets module and therefore QtWebEngineCore also had a dependency to widgets. This is removed by this change. Change-Id: If6e5745709a59de18f2123b930cbe6e64390c867 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
| | * Merge remote-tracking branch 'origin/5.7' into 5.8Allan Sandfeld Jensen2016-11-251-1/+1
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty Change-Id: Ib9c9eca457c1c42dab948e6cb56d44b57d5da32a
| | | * Fix nullpointer dereferencing errorViktor Engelmann2016-10-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check whether iconUrls is NULL before calling contains(iconUrl) on it, which, under certain circumstances, caused a SEGFAULT. Task-number: QTBUG-56330 Change-Id: Ia167d68a4c4d62af4740a8cbab2686bfbc975455 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>