summaryrefslogtreecommitdiffstats
path: root/src/core/render_widget_host_view_qt.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Delete WebContentsAdapterClient::dpiScale()Jüri Valdmann2019-02-011-34/+14
| | | | | | | It's always 1. Change-Id: I1c3d5bc3080da90379f03b6d0819c5656334751e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Delete RenderWidgetHostViewQt::m_localSurfaceIdJüri Valdmann2019-01-311-4/+2
| | | | | | | | Not needed due to m_localSurfaceIdAllocator.GetCurrentLocalSurfaceId(). Change-Id: I004a75a4abb8785fd202266d6a2c96137529dd04 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Delete RenderWidgetHostViewQt::m_latestCaptureSequenceNumberJüri Valdmann2019-01-311-4/+2
| | | | | | | | It's only used by layout tests, i.e. never. Change-Id: I50c5fdcefa87c6b5077b706599a667d9160a931d Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Implement touch text selection for QQuickWebEngineViewPeter Varga2019-01-311-4/+92
| | | | | | | | Touch handle and touch selection menu are not implemented for widget. Task-number: QTBUG-59999 Change-Id: Ia492e58b83d3ad38cdf6877d468724c399f34367 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Adaptations for Chromium 71Allan Sandfeld Jensen2019-01-281-4/+4
| | | | | | | Change-Id: Ib650113b05dfd4771240804f94e33c07aa317bf2 Reviewed-by: Michael Brüning <michael.bruning@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* Adaptations for Chromium 70Allan Sandfeld Jensen2019-01-281-13/+11
| | | | | | | Change-Id: I8bb77784dbc8a0b9debd96a4c49421bd34e6a0df Reviewed-by: Michael Brüning <michael.bruning@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* Make AccessiblityActivationObserver separate of RWHVAllan Sandfeld Jensen2019-01-091-34/+0
| | | | | | | | It is a global control anyway, and with future Chromium headers, there are conflicts with qaccessibility.h. Change-Id: Ife43340684b8b9498b1f4cd3f6fbe450d88794ec Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Merge remote-tracking branch 'origin/5.12' into devMichael Brüning2018-12-181-13/+20
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: src/core/compositor/delegated_frame_node.cpp src/core/profile_adapter.cpp src/core/profile_io_data_qt.cpp src/webengine/api/qquickwebengineprofile.cpp src/webenginewidgets/api/qwebengineprofile.cpp Change-Id: I35ec8480e758bbcb6c5942a5401cb1b6dbdcc428
| * Disable external text handles and edit menuPeter Varga2018-12-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | Chromium implements its own ones and we don't want to conflict with them. This disables the QtVirtualKeyboard's selection handle what is not functional with QtWebEngine. Task-number: QTBUG-59999 Change-Id: I6a615a04d5eac1ce2d0392d63ba0fc9039583914 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Disable text prediction for inputPeter Varga2018-12-071-2/+2
| | | | | | | | | | | | | | | | | | | | This is a workaround to avoid issues with QtVirtualKeyboard when used with QtWebEngine. Task-number: QTBUG-70158 Task-number: QTBUG-71995 Change-Id: I1e6fcd4dceb131dbe781dd7ab3856cb154ac6a18 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Fix input method updatePeter Varga2018-11-291-12/+19
| | | | | | | | | | | | | | | | | | | | | | | | Do the update after the input properties are changed in RenderWidgetHostViewQt. Moreover, always update on input state changes, like cursor position, surrounding text and text selection (see QInputMethod::update() docs). Task-number: QTBUG-70158 Task-number: QTBUG-71995 Change-Id: I9d5c6e299826fbe66f5285b648013ef79aabed9b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into devLiang Qi2018-11-281-9/+11
|\| | | | | | | Change-Id: Idf2c89bebf5e09855d764808cac487bc4b76faaa
| * Fix IME with negative start positionPeter Varga2018-11-221-8/+3
| | | | | | | | | | Change-Id: I64a39975788cc40c5e0595c1a0c5db9000889bfd Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Fix emulated touch eventsAllan Sandfeld Jensen2018-11-221-1/+8
| | | | | | | | | | | | | | | | | | Touch events now does hit-testing based on surface, so we need to register outselves as a surface to have touch events do anything. Fixes: QTBUG-71801 Change-Id: Iafd43dfcecf029f9c11e0c0c58a349ff38badbaa Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Merge branch '5.12' into devAllan Sandfeld Jensen2018-11-161-2/+26
|\| | | | | | | | | | | | | | | Conflicts: src/core/compositor/compositor.cpp src/core/compositor/compositor.h Change-Id: I8a4d73d728d93d95e499849f8778cc88dda2105e
| * Speculative fix for disable-pinch not workingAllan Sandfeld Jensen2018-11-141-0/+8
| | | | | | | | | | | | | | | | | | Introduces logic from render_widget_host_view_android.cc to ignore pinch gestures when pinch is disabled. Fixes: QTBUG-70913 Change-Id: Ib88c423c248148afdb2d203f89ab90c63b32012c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Fix autoscrollingAllan Sandfeld Jensen2018-11-141-1/+6
| | | | | | | | | | | | | | | | | | We were missing the connection between on begin frame and progressing auto-scroll. Change-Id: I651b35c031afedc9aeef1dc6a16547757b869633 Fixes: QTBUG-71370 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| * Implement CopyFromSurfaceAllan Sandfeld Jensen2018-11-081-1/+12
| | | | | | | | | | | | | | Means we can get screenshots in devtools. Change-Id: I7b50d6ac5a54d236573bcf5f58ae872bd50dccad Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Move compositor and scene-graph integration to its own dirAllan Sandfeld Jensen2018-11-071-1/+1
| | | | | | | | | | Change-Id: Ib552dc30db5ee886631a108b4ccd866459c432e2 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into devAllan Sandfeld Jensen2018-11-051-72/+16
|\| | | | | | | | | | | | | | | | | Conflicts: src/core/render_widget_host_view_qt.cpp src/core/web_contents_adapter_client.h src/webenginewidgets/api/qwebenginepage_p.h Change-Id: Ibd011c40839c09469218ac4c71a13d0a0b1c9778
| * Fix quicknanobrowser crash on startupJüri Valdmann2018-11-021-4/+5
| | | | | | | | | | | | | | | | Don't call SynchronizeVisualProperties from updatePaintNode Fixes: QTBUG-71430 Change-Id: I6bd231b22c0473f9fd47ca3cdbcb8262f314bd5b Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * Fix background of composition textPeter Varga2018-10-301-4/+3
| | | | | | | | | | | | | | | | | | | | The Chromium API has been changed: https://chromium-review.googlesource.com/c/chromium/src/+/959006/ Task-number: QTBUG-70289 Task-number: QTBUG-71453 Change-Id: Ib20a82bd826d8067aa3eb3bccccda7d8716e20ad Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| * Stop showing speculative framesJüri Valdmann2018-10-291-11/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Chromium creates "speculative" frames (RenderFrameHost and company) for pending cross-process navigations (and maybe other navigations too). For example, a redirect from http://qt.io to https://qt.io will trigger this, as described in the bug report. These speculative frames are loading in the background and only shown once they are officially ready (as decided by the RenderFrameHostManager and signaled to WebContentsObserver::RenderViewHostChanged). At least, this is how it's supposed to work and how it works in Chrome. In WebEngine, however, we actually show these speculative frames as soon as they are created and before they are ready. This runs into the problem that the if the speculative frame is dropped (instead of committed), then Chromium will not ask us to re-show the old frame (since it hasn't actually asked to us to show the new frame, it naturally assumes we are still showing the old one). Fixes: QTBUG-68727 Change-Id: I9d53035ce60e3a002d5412d4473d940a32644b5d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Remove some outdated Qt version checksAllan Sandfeld Jensen2018-10-231-50/+0
| | | | | | | | | | | | | | | | We can't not build with older than Qt 5.9 anyway due to QSG and qmake changes. Change-Id: Iff0247e70d9ffc1e045e2c571f0089d68df9a589 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * Fix four switch related warningsAllan Sandfeld Jensen2018-10-231-3/+6
| | | | | | | | | | Change-Id: If4888c1b170568735953ac715c4a7c40de614dd8 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into devJüri Valdmann2018-10-221-16/+5
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/core/net/network_delegate_qt.cpp Changed to src/3rdparty: 156c2b70 Disable "some invariants violation checks" for Qt 52bf8b45 Support non-base::Thread GPU thread ba4a51bc [Backport] Speculative fix for mac DCHECK failure 508fda09 Add support for static-libraries to our GN integration Change-Id: If0205ce032ce86b5759b321b6d907b0431b6a978
| * Clean up header includes in corev5.12.0-beta3Peter Varga2018-10-201-16/+5
| | | | | | | | | | Change-Id: I3ffc92eacf30265ecb80061870d213e521e4f838 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Update mailboxes before renderingJüri Valdmann2018-10-161-3/+4
|/ | | | | | | | | | | Instead of updating mailboxes during the preprocessing phase of the Qt Quick Scene Graph renderer, do it separately before rendering even starts. Prerequisite for running GPU service on UI thread. Task-number: QTBUG-71126 Change-Id: Iec2acd7233c33e4dc4e33077c14cf6b9170685ed Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* General adaptations for Chromium 69Allan Sandfeld Jensen2018-09-221-4/+25
| | | | | Change-Id: Ifeaf0ee13213dc5a24d2f2b4655cf7f405cddef7 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Handle Chromium resize throttling using surface idsAllan Sandfeld Jensen2018-09-221-7/+31
| | | | | | | | | | We need to change surface id to acknowledge a resize is completed, and we need to handle that Chromium is rejecting resize events because the last one is not yet acknowledged. Change-Id: I93b1e197218906de80d5748a5a100f7a740ea07c Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Adapt to forced scroll-wheel latchingAllan Sandfeld Jensen2018-09-221-6/+19
| | | | | | | | Handle that Chromium now requires all wheel events to be phases despite them not being phased on the majority of platforms. Change-Id: Iabd5630652c0d8fd67563db3d63ef1f2f528c35c Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Adaptations for Chromium 68Allan Sandfeld Jensen2018-09-221-30/+12
| | | | | | Together-with: Tamas Zakor<ztamas@inf.u-szeged.hu> Change-Id: I805246b6f01cb151fff48588744408c676d87c14 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Extract Compositor from RenderWidgetHostViewQtv5.12.0-alpha1Jüri Valdmann2018-09-111-77/+8
| | | | | | | | Split compositing-related functionality from RenderWidgetHostViewQt into a new class Compositor. Change-Id: I97b26a6057734cd8ce8c1df29b373888f7a07c1c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Replace RenderWidgetHostViewQt::m_host by RenderWidgetHostViewBase::host()Tamas Zakor2018-08-241-39/+38
| | | | | Change-Id: I327c2459e803602dae107defec8d03d75f363cd7 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Merge remote-tracking branch 'origin/5.11' into 5.12Michael Brüning2018-08-211-1/+18
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf configure.json examples/webenginewidgets/markdowneditor/resources/3rdparty/marked.js examples/webenginewidgets/markdowneditor/resources/3rdparty/qt_attribution.json examples/webenginewidgets/markdowneditor/resources/markdowneditor.qrc mkspecs/features/platform.prf src/3rdparty src/core/media_capture_devices_dispatcher.cpp src/core/net/url_request_context_getter_qt.cpp src/core/net/url_request_context_getter_qt.h src/core/web_contents_adapter.cpp Change-Id: I467133ba455b1f85f6bb61793794c31cb1094541
| * Close popups when parent window is movedAlexandru Croitor2018-07-271-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When an HTML select box was clicked inside of a QWebEngineView and the parent QWebEngineView window was moved using the mouse (via window decoration toolbar for example) the popup window would stay around instead of being closed. This happened because of the usage of the Qt:Tool window flag for the popup window, which implies a tool that floats near its parent window. The fix is threefold: 1) Use Qt::Popup instead, similarly to how QMenu does it. Whenever the parent window is moved, the popup will now get a CloseEvent. 2) Handle the CloseEvent by telling Chromium to close and destroy the popup. 3) On Windows the OS might send mouse move events to the popup RWHVQD instance after its parent QWebEngineView, RWHVQD, QWebEnginePagePrivate (client adapter) is destroyed. We need to guard the mouse forwarding code not to access the client adapter if it has already been destroyed. The second point is done by telling Chromium that its popup lost focus which it interprets as a sign to hide it, and automatically destroy it. This will destroy the underlying RWHVQtDelegateWidget and RWHVQt instances. Task-number: QTBUG-59891 Change-Id: I47f94a93c495a6caa5de92a6022eaca154994eda Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * Compile with -no-feature-tableteventAndy Shaw2018-06-291-0/+4
| | | | | | | | | | Change-Id: I7e03d6e3347ee9b81a7414574098827b5773b7b4 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Use ozone for x11Michal Klocek2018-08-021-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use ozone also for x11/glx. This way we have a more elegant approach to hook in our gl surface classes and we use ozone for all linux qpa backends. Moreover, we have now also more fine grain control to reimplement gl surface handling logic. This also aims to fix currently broken wayland backend, but instead of patching the broken x11 calls, we simply reuse ozone which does not use x11 for ozone egl. Add webengine-x11 check to handle ozone glx plugin compilation. For ozone egl backend reimplement missing functions. Task-number: QTBUG-65682 Task-number: QTBUG-51631 Change-Id: I8b45c6f4d09a1c703efb12b6452d78ab385371ab Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Implement RenderWidgetHostViewQt::DisplayCursorAllan Sandfeld Jensen2018-07-301-0/+5
| | | | | | | | | | | | | | | | | | It is where the active logic of UpdateCursor should now be. It doesn't matter for us yet, but we might as well follow how it is supposed to be done. Change-Id: I9d7f2ed767c3eef03e637680166b75307081f057 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Fix tooltip regression from 67-basedAllan Sandfeld Jensen2018-07-241-2/+1
| | | | | | | | | | | | | | We do not have a cursor manager. Change-Id: Idf4b89f12a0480d7f522879ba07ee807aaef641f Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Return invalid ImCursorRectangle when height is zeroJüri Valdmann2018-07-191-4/+6
| | | | | | | | | | | | | | | | | | The test tst_QWebEngineView::microFocusCoordinates is flaky due to a timing issue where TextInputManager::GetSelectionRegion() returns a selection rectangle with zero height if called too soon after the HTMLElement.focus() call. Change-Id: Iba52eadd6c2d4f9027284fedbff40c3fcc951a28 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | Merge remote-tracking branch 'origin/5.11' into devAllan Sandfeld Jensen2018-06-261-4/+25
|\| | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf configure.json src/3rdparty tests/auto/widgets/qwebenginepage/tst_qwebenginepage.cpp Change-Id: Id79ff6cf01c2db3a2044881ddcbf044abdf84936
| * Fix WebCursor scaling and hotspotJüri Valdmann2018-06-051-4/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Old behavior: - Hotspot always chosen according to 2x devicePixelRatio. - Image always chosen according to 1x devicePixelRatio. New behavior: - Use actual devicePixelRatio. Task-number: QTBUG-68376 Change-Id: I6eef12a7dcf7fde7f8f488d9f2cba99f21e73cc2 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Adaptations for Chromium 67Allan Sandfeld Jensen2018-06-261-14/+20
| | | | | | | | | | Change-Id: I13cedba56012f74651a044d6fa8f0957487bf3eb Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Adaptations for Chromium 66Allan Sandfeld Jensen2018-06-261-19/+18
| | | | | | | | | | Change-Id: Iee88721a50036d4ef85a23dd1708d4fb84218708 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Map CSS 'copy' and 'alias' to DragCopyCursor and DragLinkCursorJüri Valdmann2018-06-121-8/+6
|/ | | | | Change-Id: Ic2664f6a1043598c43f2f0a4a6dacacb65010df8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix finishing IME compositionPeter Varga2018-04-261-50/+48
| | | | | | | | | | | | | Call RenderWidgetHostImpl::ImeCommitText() instead of RenderWidgetHostImpl::ImeFinishComposingText() to trigger the necessary JavaScript events on composing. This fixes IME composition (eg. for dead keys) on web pages which use custom JavaScript IME handler like facebook. Task-number: QTBUG-66046 Change-Id: Ibc177995ba6e85eca42ae333decacfe6e788ce41 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Protect against null adapter clientAllan Sandfeld Jensen2018-04-121-3/+7
| | | | | | | Task-number: QTBUG-67653 Change-Id: I07c9dca788ee31f691b05f7647ffbf3f9e0b7260 Reviewed-by: Michal Klocek <michal.klocek@qt.io> Reviewed-by: Viktor Engelmann <viktor.engelmann@qt.io>
* Fix multiple shortcut events being delivered on macOSMichael Brüning2018-03-231-2/+5
| | | | | | | | | | | | | | Commit ef1d61a3516182b0a39330b5ac5988f92c82bc4f introduced a regression where multiple shortcut events where delivered on macOS. Instead of using tryShortcut (which triggers shortcut events) to check if the shortcut needs to be overridden, check if the shortcut map has an entry for the key seqeunce in question. Task-number: QTBUG-66207 Change-Id: I8d277e2ac39de8a1f2d2c43dc8486e042c4ea458 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Basic adaptations for 65-basedAllan Sandfeld Jensen2018-03-151-2/+15
| | | | | Change-Id: I121b14d6a44e80f5eea4b159c58f7010d472926e Reviewed-by: Michael Brüning <michael.bruning@qt.io>