summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix WebEngine api build on WindowsZoltan Arvai2014-02-112-0/+5
| | | | | | | | QQuickWebEngineViewPrivate needs a destructor to work right with WebContentsAdapter. Change-Id: I3df1b452eeaf3a7516eace9268884ff6d1211e44 Reviewed-by: Michael Bruning <michael.bruning@digia.com>
* Fix WebEngineWidgets api build on WindowsZoltan Arvai2014-02-111-0/+8
| | | | | | | | MSVC doesn't know __func__ so it needs to be defined. Also eliminate some unused variable warning. Change-Id: Ia42e411c0af8425a71faf99a87dbc0affac53015 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix string concatenation in WebEngine on WindowsZoltan Arvai2014-02-111-0/+6
| | | | | | | | | | MSVC thinks the firs part of that string is wide while the second part is narrow and it won't allow to concetanete them directly. Adding literal for wide string before ".qml" on Windows will resolve it. Change-Id: I934fed6fe9e9401461a8165a524e8110cec3c3fa Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Fix Qt5WebEngineCore linking on WindowsZoltan Arvai2014-02-112-3/+2
| | | | | | | | | | BUILDING_CHROMIUM define have to be moved to the related project in core from default_pre.prf. Otherwise dllexport would be used instead of dllimport while linking to webengine and webenginewidgets. Change-Id: Ifed117f420591dcb7f97f12924b83ab86ead6216 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com> Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Implement requestFullscreen for QQuickWebEngineView.Zeno Albisser2014-02-117-0/+97
| | | | | | | | | | | | | | This patch adds a property isFullScreen and a signal fullScreenRequested to QQuickWebEngineViewExperimental. The signal fullScreenRequested is emitted when some web content requests fullscreen through the javascript API. The property isFullScreen is supposed to be set programmatically when the view is being shown fullscreen. This information is then available to the WebContentsDelegateQt when checking if the fullscreen request has been accepted. Change-Id: I04cbb45f263a188d26cc87d70ac53b0fbab63936 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Add TakeFocus in WebContentsViewQt for passing on tab focus.Zeno Albisser2014-02-108-1/+38
| | | | | | | | | | Chromium calls RenderViewHostDelegate::TakeFocus when the last focusable item within the page was reached. We then have to move the focus on to the next/previous QQuickItem. Change-Id: Id0128053602ff1220c1bced1b218050b66fef659 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Make sure examples are always builtSimon Hausmann2014-02-081-0/+7
| | | | | | | | | | | When building against Qt 5 release binaries, QT_BUILD_PARTS does not include examples. However we want to unconditionally build examples, until we become part of the Qt 5 module set. (cherry picked from commit f2fb23f23f67db841467752c2a4c2a5cb9ebde43) Change-Id: I6239c3f9280c50f5418947f711924be59265c4ce Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Implement basic support for input method events.Zeno Albisser2014-02-084-0/+27
| | | | | | | | This is needed to get text input working again on Mac. Underlines are currently being ignored. Change-Id: I2a1074a1151e9be6f96ebe12fd0bb40a0eb63d6a Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* Use arm_neon_optional from armv7 onward if not explicitly enabledAndras Becsi2014-02-061-6/+10
| | | | | | | | | This makes our behavior consistent with chromium if the Qt toolchain does not explicitly enable NEON instructions, which would result in undefined symbols otherwise. Change-Id: Idc4f355714ede4206f4650664f6c24784100e7d8 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Register a path provider for Qt instead of using PathService::OverrideAndras Becsi2014-02-065-26/+96
| | | | | Change-Id: I465a5465ec4189b077a8c1cbab7485c628eca899 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Add Ctrl+R shortcut for reload.Zeno Albisser2014-02-061-0/+4
| | | | | Change-Id: Ia7bb688e3ace174da7fd5957a35f47f9b886952f Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Move the implementation of BrowserContextQt to its own cpp fileAndras Becsi2014-02-055-90/+170
| | | | | Change-Id: Ie44a8733e3f9123c3d086f8df9ddcf2833bd235b Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Clean up qtwebengine.gypiAndras Becsi2014-02-051-50/+33
| | | | | | | Fix the indentation and remove some obsolete settings. Change-Id: I59d3c00f481b2ae124e1b3a6434ff5c68acde53d Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Fix the embedded buildAndras Becsi2014-02-058-10/+68
| | | | | | | | | | Adopt to toolchain changes and fix the build with the current snapshot. This patch adds some missing overrides and build system configurations. Change-Id: I488929500347bdb5a077ac14e9553cedfcaa605d Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Make it easier to update patches and apply them manuallyJocelyn Turcotte2014-02-0322-202/+242
| | | | | | | | | | | | | | Clean the way that we maintain patches by keeping them ordered by their number and let the shell order them when giving the list to git am. Provide a update-patches.sh that maintains the proper command lines to use and run a cleaning script on the resulting patch to avoid the SHA1 to be added to the file as it changes every time the patch is applied. Change-Id: Ia93cf4b35f5f847a8723a31fc476443864242737 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Quick: Support reparentingArvid Nilsson2014-01-3114-78/+104
| | | | | | | | | | | | | | | | | To support reparenting, we make the compositing surface independent of the window by using gfx::TEXTURE_TRANSPORT. We also need to be able to keep frame data across window changes so we can reconstruct the QSGNode tree in a new context, so extract that data into DelegatedFrameNodeData class. Any context-specific data is still stored in DelegatedFrameNode. Also hook up window changes to WebContents::WasShown/Hidden for Quick. Remove checking of Qt isVisible state, this mechanism is used to sync Chromium with Qt, not the other way around. WasShown/Hidden is orthogonal to Show/Hide, and can use different triggers. However for Widgets it probably makes sense to hook both up to widget visibility. Change-Id: I1ef4b50cd61b8e54b791e03f0b41929c42fec8bf Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Disable test discovery from the build systemJocelyn Turcotte2014-01-312-2/+6
| | | | | | | | | | CONFIG += testcase enables make check and the CI test planner to find and execute tests. Since our tests aren't 100% passing yet, disable them for now. Change-Id: I0dbafa7f6d6176979b28249b0642905611d791c2 Reviewed-by: Arvid Nilsson <anilsson@blackberry.com> Reviewed-by: Michael Bruning <michael.bruning@digia.com>
* Make the QWebEngineFrame tests passPierre Rossi2014-01-301-22/+24
| | | | | | | | | The unskipped ones that is. This highlights some behavior changes, notably the fact that loadFinished now fires as many times as there were loads initiated. Change-Id: I75665cdf06f4692fbeccb5227aa056e598038748 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* WebPage: Implement javaScriptConsoleMessagePierre Rossi2014-01-3010-6/+37
| | | | | | | And unskip the corresponding autotest. Change-Id: Ida2dcee38b261b2ba4ad0c5c016f5510ed1590a4 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Fix tst_QWebEnginePage's use of evaluateJavaScriptPierre Rossi2014-01-302-129/+128
| | | | | | | Mostly speculative autotest adjustments due to lacking features Change-Id: I5b0cfa8fb586ae4531327c21d03b064d9c307d06 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Fix reload button in the QuickNanoBrowserAdam Kallai2014-01-281-1/+1
| | | | | Change-Id: I3670380d76d014a33e0112631bdb42927b67b9d9 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Remove a FIXME after Chromium update.Szabolcs David2014-01-281-2/+1
| | | | | | | Load progress is already available in the current snapshot. Change-Id: I997b25a1da284b43d442d3105105be3455628087 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Pre-start the render process upon initialiazing the adapterPierre Rossi2014-01-282-4/+9
| | | | | | | | | | | | | | | This should provide us with an initial empty document, which our imported autotests tend to assume all over the place. Initialization of the adapter is moved further down in QQuickWebEngineView's constructor so that the value of q_ptr is set and valid by the time we end up in WebContentsViewQt::CreateViewForWidget. Change-Id: I45d8d61e65caa3a690461b6da44adea9f8981e7e Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com> Reviewed-by: Zeno Albisser <zeno.albisser@digia.com> Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix the build on embedded platformsAndras Becsi2014-01-284-11/+6
| | | | | | | | | | | | | | | We should not include chromium headers outside of core since they might depend on defines or other build options only set in the gyp/ninja environment. This patch removes the need to include net/base/net_errors.h in the API implementation of the QQuickWebEngineView and also removes the chromium source directory from the global include path. This prevents including chromium headers outside of core by mistake and also makes it possible to load the project in QtCreator without disabling indexing. Change-Id: Icd13b6caa52509ef2a1b6b44eaffb34d8ae4addf Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* Add loadIgnoreEmptyUrl test case to loadUrl QML test.Szabolcs David2014-01-282-0/+53
| | | | | Change-Id: I56c78aa7e60194888123d372c6dbbb60624856c5 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Add loadUrl QML test with stopStatus test case.Szabolcs David2014-01-283-0/+73
| | | | | | | Fix the webEngineView.stop() function in the WebContentsAdapter. Change-Id: I82c5000fb3cbc5aff59dd0c4c7c86ca7755a6329 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Get rid of tr1/functionalJocelyn Turcotte2014-01-274-35/+51
| | | | | | | | | | This header requires rtti in libstdc++ on Mac, which we can't recommend since Qt itself is usually built without rtti. Replace its uses with simpler hand-made template functors. Change-Id: Ic020dcceaf262f77d92b31a8318a513fa200428d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Add properties QML test.Szabolcs David2014-01-272-0/+68
| | | | | Change-Id: I55fcbd7958f6dbc51c119133ee631fc2ccad1152 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Support absolute path in chromiumsrcdirArvid Nilsson2014-01-272-3/+3
| | | | | | | | | | Use the second parameter of $$absolute_path to resolve the git config value qtwebengine.chromiumsrcdir, in case it's already absolute. Change-Id: I68caf5c2f208d3caae69c1f6f361c916ce3f3d93 Reviewed-by: Zeno Albisser <zeno.albisser@digia.com> Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix package builds against release builds of QtSimon Hausmann2014-01-271-4/+25
| | | | | | | | | | | | | The Qt build system assumes that when building a module against a release build of Qt, syncqt was already run at package creation time. So we have to run syncqt when creating source packages. This patch changes the syntax to separate the file name base from the package version to use. Change-Id: I4ffb4a7d9d8e8e0a1d681dfb9d337b8ab9f76d9a Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com> Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Small fixes to the packaging scriptSimon Hausmann2014-01-271-2/+9
| | | | | | | | | | * Add a .tag file to the archive that contains the sha1 the package was created from. This is useful for diagnostics. * Use bash and enforce error handling (it's easy to accidentally include bashisms) Change-Id: I217942da2e985772567da91a7635e5e81533ca95 Reviewed-by: Zeno Albisser <zeno.albisser@digia.com> Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com> Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Add loadProgressSignal QML test.Szabolcs David2014-01-242-0/+74
| | | | | Change-Id: I785bbcd81061228d437fd7334809c9b85ab18f38 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Add loadProgress QML test.Szabolcs David2014-01-243-0/+70
| | | | | Change-Id: I3989f114520900246fa78f7f6bb6068be398ee63 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Clear callbacks with an empty value on page destructionJocelyn Turcotte2014-01-223-6/+43
| | | | | | | | | | | | | | | The current implementation offers no way to cancel async requests. This means that normal applications could easily allow callbacks to dereference a destroyed object unless they use a smart pointer within the callback function object. This patch will empty the pending callback list by calling each of them with an empty value. This will at least allow applications to cover the cases where the page is expected to have a shorter or equal lifetime than objects referenced in the callback. Change-Id: Ia9fc556b03f5d83f904a0ff4b05dc9e440ea488c Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Fix html5 videoAndras Becsi2014-01-224-1/+22
| | | | | | | | | | Deploy the built ffmpegsumo library and make chromium find it by overriding the content::DIR_MEDIA_LIBS path with the deploy location. We deploy the plugin to $$[QT_INSTALL_PLUGINS]/qtwebengine. Change-Id: I0aeb37fccd2af62b23f8e6405041655e1f66b7aa Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* Fix a crash in JavaScriptDialogControllerPierre Rossi2014-01-221-4/+5
| | | | | | | | | | We already remove the active dialog for a given WebContents from the map when it's accepted/rejected. We should hence not expect to get a valid dialog controller on subsequent attempts (when the WebContents get destroyed for instance). Change-Id: I522308e20772a55f1bcba26047b3f4e4aef94082 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Fix JavaScriptDialogControllerPrivate's typeZoltan Arvai2014-01-221-1/+1
| | | | | | | | | It used as a struct in javascript_dialog_controller.h but it is a class in javascript_dialog_controller_p.h. Change-Id: I3b2fdf26a1673fb5fef5f7c468367eca559493f8 Reviewed-by: Michael Bruning <michael.bruning@digia.com> Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* gitignore updatePierre Rossi2014-01-221-5/+6
| | | | | | | to unclutter git status --untracked once again Change-Id: Ia329f321e1e1689cbb990d66580234c666bb5416 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix findMocables on WindowsZoltan Arvai2014-01-221-1/+1
| | | | | | | | | | Replace doesn't matches anything with QMAKE_DIR_SEP, that is backslash on Windows, because absolute_path and _PRO_FILE_PWD_ returns forward slashes. Change-Id: Ieba1684782d565885f4069f408cfb129476e301d Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com> Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix Qt's moc path on WindowsZoltan Arvai2014-01-221-1/+1
| | | | | | | | | Backslash from mocCmdBase is processed as an escape sequence in generated gyp file. E.g. Qt5\bin\moc.exe turns to Qt5[BS]in\moc.exe. Change-Id: I09a04b0e168e1139720c44307f192f7a9368ad43 Reviewed-by: Michael Bruning <michael.bruning@digia.com>
* Unskip and ajust tests using setHtml, setContent, toHtml and toPlainTextJocelyn Turcotte2014-01-225-60/+79
| | | | | | | | | | Replace direct calls of toHtml and toPlainText to use a blocking helper function that spins a QEventLoop to wait for the async result. This should work fine for tests where the event loop is less polluted by other events that could cause code reentrancy through stacked stacks. Change-Id: Ic46a06a9abad782a39a620ceecdc51c3bbb6b5a1 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Make tst_QWebEngineFrame compileJocelyn Turcotte2014-01-222-273/+388
| | | | | | | | Even though this code now test QWebEnginePage, keep it in its original file to allow easier tracking of differences with QtWebkit. Change-Id: Id001c2fcba0ee4a756fe5f32d8002e15368a191b Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Implement QWebEnginePage::toHtml and toPlainTextJocelyn Turcotte2014-01-2215-15/+143
| | | | | | | | | | | | | | | | Those methods are now made asynchronous and need to be given a callback to handle the result. Update the code in the browser and fancybrowser examples using std::bind when using C++11 or tr1::bind with C++03 (which should be available with compilers on platforms that we support). Add a (currently failing) earlyToHtml test to make sure that an empty page doesn't crash because of a possibly incomplete attachment of the QtRenderViewObserver. Change-Id: I3ab7cb6f25b91b584dd80df5e4e9ad1e3214348e Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Add a stub message system to communicate with the blink WebViewJocelyn Turcotte2014-01-2215-2/+457
| | | | | | | | | | | | | | | | | This follows the model used by the Android WebView's AwRenderViewExt class. QtRenderViewObserverHost is attached to the WebContents and QtRenderViewObserver is attached to the RenderView in the render process. Both can exchange messages together and allow async commands to be carried from WebContentsAdapter and the result sent back through WebContentsAdapterClient. This patch also adds a renderer subdirectory to start matching the directory structure of Chromium. Change-Id: I724ca2fe2a597dcd2a15e8e1a23c4eeba1190703 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Refactor the callback mechanism used by runJavaScriptJocelyn Turcotte2014-01-227-49/+59
| | | | | | | | | | | | | | | | | | This prepares the way for other API made async like toHtml and toPlainText. Use a callback class with an implicit templated constructor to carry the functor across the API boundary and avoid the intermediate helper method as the ABI that we have to maintain. Also pass the callback result through WebContentsAdapterClient using a bookkeeping ID instead of transferring the callback to WebContentsAdapter. This will allow other calls, which might not already allow passing a callback functor, to use a consisten way of carrying back the result to the top API layer. Change-Id: Ia923767b9c1021a108c26da17d4c41878ef7cb95 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Implement QWebEnginePage::setHtml and setContentJocelyn Turcotte2014-01-224-0/+39
| | | | | | | | | | Load a generated data: URL to carry the data. This is not as efficient as it could be but the behavior matches and this should be fine for now. Change-Id: I26ad2e5976025a3044fb03f066074ce6dd34e575 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Add QML test framework and titleChanged test caseAdam Kallai2014-01-207-0/+323
| | | | | | | Change-Id: Ie38ee02e485702d10d0c171f2168f2685c2de2a6 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com> Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix QWebEngineView to page reattachment.Jocelyn Turcotte2014-01-176-3/+44
| | | | | | | | This fixes the crash in tst_QWebEngineView::reusePage. Also add a test to check the case where show() would react incorrectly. Change-Id: I40247c7c225d74b26675b6a7fa5ff1f06d3bb3e6 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Qt Quick File PickerPierre Rossi2014-01-157-2/+158
| | | | | Change-Id: I6195c49f1647c78b16d9d47770ab37ba998a61a5 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* JS dialogs in QtQuickPierre Rossi2014-01-1520-27/+597
| | | | | | | | | | Refactor JavaScriptDialogManagerQt to support a Qt Quick dialogs friendly approach. Qt Quick dialogs are still missing a prompt, so we use a "handmade" one. This should be solved before 5.3 though. Change-Id: I965df66837b2e81d6e4618a8da1167a37661c26e Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>