From e9b510bbf2b1311761c2a2f98d4410ab9b17f9e5 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Thu, 18 Aug 2016 17:06:06 +0200 Subject: Bump module version MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Task-number: QTBUG-55367 Change-Id: If073f0be97d01dfb26ad47803250eb645b386a1c Reviewed-by: Johanna Äijälä Reviewed-by: Oswald Buddenhagen --- .qmake.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.qmake.conf b/.qmake.conf index 13d4ba6b0..9fc9b72fc 100644 --- a/.qmake.conf +++ b/.qmake.conf @@ -2,4 +2,4 @@ QMAKEPATH += $$PWD/tools/qmake load(qt_build_config) CONFIG += warning_clean -MODULE_VERSION = 5.6.1 +MODULE_VERSION = 5.6.2 -- cgit v1.2.3 From 8a4091c2104913294b4dc7b06c8e9fb2c022f51e Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 16 Aug 2016 14:51:33 +0200 Subject: Fix crash when trying to navigate in new window but is blocked Ensure that if QWebEnginePage::createWindow returns 'this' that we fall back to navigating in current tab. Change-Id: Idffe25dcafaaf3c824815b3cf1f0e400eaec2923 Reviewed-by: Michal Klocek --- src/core/web_contents_delegate_qt.cpp | 1 + src/webenginewidgets/api/qwebenginepage.cpp | 11 ++++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/core/web_contents_delegate_qt.cpp b/src/core/web_contents_delegate_qt.cpp index 97f0e515d..5e9157069 100644 --- a/src/core/web_contents_delegate_qt.cpp +++ b/src/core/web_contents_delegate_qt.cpp @@ -97,6 +97,7 @@ content::WebContents *WebContentsDelegateQt::OpenURLFromTab(content::WebContents if (targetAdapter) target = targetAdapter->webContents(); } + Q_ASSERT(target); content::NavigationController::LoadURLParams load_url_params(params.url); load_url_params.referrer = params.referrer; diff --git a/src/webenginewidgets/api/qwebenginepage.cpp b/src/webenginewidgets/api/qwebenginepage.cpp index dbbac1aed..f10833b9b 100644 --- a/src/webenginewidgets/api/qwebenginepage.cpp +++ b/src/webenginewidgets/api/qwebenginepage.cpp @@ -279,9 +279,14 @@ void QWebEnginePagePrivate::adoptNewWindow(QSharedPointer ne if (newPage->d_func() == this) { // If createWindow returns /this/ we must delay the adoption. Q_ASSERT(q == newPage); - QTimer::singleShot(0, q, [this, newPage, newWebContents, initialGeometry] () { - adoptNewWindowImpl(newPage, newWebContents, initialGeometry); - }); + // WebContents might be null if we just opened a new page for navigation, in that case + // avoid referencing newWebContents so that it is deleted and WebContentsDelegateQt::OpenURLFromTab + // will fall back to navigating current page. + if (newWebContents->webContents()) { + QTimer::singleShot(0, q, [this, newPage, newWebContents, initialGeometry] () { + adoptNewWindowImpl(newPage, newWebContents, initialGeometry); + }); + } } else { adoptNewWindowImpl(newPage, newWebContents, initialGeometry); } -- cgit v1.2.3 From e2b8c3fe8f83cf448df4b0476f4f0dd4dd7d1b80 Mon Sep 17 00:00:00 2001 From: Michal Klocek Date: Fri, 13 May 2016 17:53:14 +0200 Subject: Fix textures memory leak on second X11 screen Fix for QTBUG-48969 was only half-baked patch and introduced massive memory leak on fbo and texture alloctaions. Delete fbo and extra allocated textures. Task-number: QTBUG-52575 Task-number: QTBUG-48969 Change-Id: I2148f37cd27dab9e40ab72caeb6857752b69379f Reviewed-by: Allan Sandfeld Jensen --- src/core/delegated_frame_node.cpp | 82 +++++++++++++++++++++++++++++---------- src/core/delegated_frame_node.h | 5 +++ 2 files changed, 67 insertions(+), 20 deletions(-) diff --git a/src/core/delegated_frame_node.cpp b/src/core/delegated_frame_node.cpp index c7c106177..363814789 100644 --- a/src/core/delegated_frame_node.cpp +++ b/src/core/delegated_frame_node.cpp @@ -70,7 +70,6 @@ #include #include #include -#include #include #if !defined(QT_NO_EGL) @@ -91,6 +90,7 @@ namespace QtWebEngineCore { class MailboxTexture : public QSGTexture, protected QOpenGLFunctions { public: MailboxTexture(const gpu::MailboxHolder &mailboxHolder, const QSize textureSize); + ~MailboxTexture(); virtual int textureId() const Q_DECL_OVERRIDE { return m_textureId; } virtual QSize textureSize() const Q_DECL_OVERRIDE { return m_textureSize; } virtual bool hasAlphaChannel() const Q_DECL_OVERRIDE { return m_hasAlpha; } @@ -108,6 +108,9 @@ private: QSize m_textureSize; bool m_hasAlpha; GLenum m_target; +#if defined(USE_X11) + bool m_ownsTexture; +#endif #ifdef Q_OS_QNX EGLStreamData m_eglStreamData; #endif @@ -280,6 +283,9 @@ MailboxTexture::MailboxTexture(const gpu::MailboxHolder &mailboxHolder, const QS , m_textureSize(textureSize) , m_hasAlpha(false) , m_target(GL_TEXTURE_2D) +#if defined(USE_X11) + , m_ownsTexture(false) +#endif { initializeOpenGLFunctions(); @@ -290,6 +296,21 @@ MailboxTexture::MailboxTexture(const gpu::MailboxHolder &mailboxHolder, const QS m_textureSize = QSize(1, 1); } +MailboxTexture::~MailboxTexture() +{ +#if defined(USE_X11) + // This is rare case, where context is not shared + // we created extra texture in current context, so + // delete it now + if (m_ownsTexture) { + QOpenGLContext *currentContext = QOpenGLContext::currentContext() ; + QOpenGLFunctions *funcs = currentContext->functions(); + GLuint id(m_textureId); + funcs->glDeleteTextures(1, &id); + } +#endif +} + void MailboxTexture::bind() { glBindTexture(m_target, m_textureId); @@ -390,8 +411,25 @@ RectClipNode::RectClipNode(const QRectF &rect) DelegatedFrameNode::DelegatedFrameNode() : m_numPendingSyncPoints(0) +#if defined(USE_X11) + , m_contextShared(true) +#endif { setFlag(UsePreprocess); +#if defined(USE_X11) + QOpenGLContext *currentContext = QOpenGLContext::currentContext() ; + QOpenGLContext *sharedContext = qt_gl_global_share_context(); + if (!QOpenGLContext::areSharing(currentContext, sharedContext)) { + static bool allowNotSharedContextWarningShown = true; + if (allowNotSharedContextWarningShown) { + allowNotSharedContextWarningShown = false; + qWarning("Context is not shared, textures will be copied between contexts."); + } + m_offsurface.reset(new QOffscreenSurface); + m_offsurface->create(); + m_contextShared = false; + } +#endif } DelegatedFrameNode::~DelegatedFrameNode() @@ -430,30 +468,28 @@ void DelegatedFrameNode::preprocess() #if defined(USE_X11) // Workaround when context is not shared QTBUG-48969 // Make slow copy between two contexts. - QOpenGLContext *currentContext = QOpenGLContext::currentContext() ; - QOpenGLContext *sharedContext = qt_gl_global_share_context(); - if (!QOpenGLContext::areSharing(currentContext,sharedContext)) { - static bool allowNotSharedContextWarningShown = true; - if (allowNotSharedContextWarningShown) { - allowNotSharedContextWarningShown = false; - qWarning("Context is not shared, textures will be copied between contexts."); - } + if (!m_contextShared) { + QOpenGLContext *currentContext = QOpenGLContext::currentContext() ; + QOpenGLContext *sharedContext = qt_gl_global_share_context(); + + QSurface *surface = currentContext->surface(); + Q_ASSERT(m_offsurface); + sharedContext->makeCurrent(m_offsurface.data()); + QOpenGLFunctions *funcs = sharedContext->functions(); + + GLuint fbo = 0; + funcs->glGenFramebuffers(1, &fbo); Q_FOREACH (MailboxTexture *mailboxTexture, mailboxesToFetch) { gfx::TransferableFence fence = transferredFences.take(mailboxTexture->mailboxHolder().sync_point); waitChromiumSync(&fence); deleteChromiumSync(&fence); - QSurface *surface = currentContext->surface(); // Read texture into QImage from shared context. // Switch to shared context. - QOffscreenSurface offsurface; - offsurface.create(); - sharedContext->makeCurrent(&offsurface); - QOpenGLFunctions *funcs = sharedContext->functions(); + sharedContext->makeCurrent(m_offsurface.data()); + funcs = sharedContext->functions(); QImage img(mailboxTexture->textureSize(), QImage::Format_RGBA8888_Premultiplied); - GLuint fbo = 0; - funcs->glGenFramebuffers(1, &fbo); funcs->glBindFramebuffer(GL_FRAMEBUFFER, fbo); funcs->glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, mailboxTexture->m_textureId, 0); GLenum status = funcs->glCheckFramebufferStatus(GL_FRAMEBUFFER); @@ -461,13 +497,12 @@ void DelegatedFrameNode::preprocess() qWarning("fbo error, skipping slow copy..."); continue; } - - funcs->glReadPixels(0, 0, mailboxTexture->textureSize().width(), mailboxTexture->textureSize().height(), GL_RGBA, GL_UNSIGNED_BYTE, img.bits()); - funcs->glBindFramebuffer(GL_FRAMEBUFFER, 0); + funcs->glReadPixels(0, 0, mailboxTexture->textureSize().width(), mailboxTexture->textureSize().height(), + GL_RGBA, GL_UNSIGNED_BYTE, img.bits()); // Restore current context. - currentContext->makeCurrent(surface); // Create texture from QImage in current context. + currentContext->makeCurrent(surface); GLuint texture = 0; funcs = currentContext->functions(); funcs->glGenTextures(1, &texture); @@ -479,7 +514,14 @@ void DelegatedFrameNode::preprocess() funcs->glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, mailboxTexture->textureSize().width(), mailboxTexture->textureSize().height(), 0, GL_RGBA, GL_UNSIGNED_BYTE, img.bits()); mailboxTexture->m_textureId = texture; + mailboxTexture->m_ownsTexture = true; } + // Cleanup allocated resources + sharedContext->makeCurrent(m_offsurface.data()); + funcs = sharedContext->functions(); + funcs->glBindFramebuffer(GL_FRAMEBUFFER, 0); + funcs->glDeleteFramebuffers(1, &fbo); + currentContext->makeCurrent(surface); } else #endif { diff --git a/src/core/delegated_frame_node.h b/src/core/delegated_frame_node.h index eed03fadd..d888935b2 100644 --- a/src/core/delegated_frame_node.h +++ b/src/core/delegated_frame_node.h @@ -45,6 +45,7 @@ #include #include #include +#include #include "chromium_gpu_helper.h" #include "render_widget_host_view_qt_delegate.h" @@ -98,6 +99,10 @@ private: QMap m_mailboxGLFences; QWaitCondition m_mailboxesFetchedWaitCond; QMutex m_mutex; +#if defined(USE_X11) + bool m_contextShared; + QScopedPointer m_offsurface; +#endif }; } // namespace QtWebEngineCore -- cgit v1.2.3 From 3ddbb2cc3e74e3803c1a36a38715b93b88a3e16d Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Fri, 26 Aug 2016 15:20:21 +0200 Subject: Update Chromium MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pulls in fixes for webcursors and building against FFMPEG3 Change-Id: Ic852604eea1a15cbf96decd536278f01a7f9dcf3 Reviewed-by: Michael Brüning --- src/3rdparty | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/3rdparty b/src/3rdparty index 696c08493..4d61c01b7 160000 --- a/src/3rdparty +++ b/src/3rdparty @@ -1 +1 @@ -Subproject commit 696c084930b870a5b1fd7f176d4e7ccb3eff416c +Subproject commit 4d61c01b71fcbe706ea4220d33294d4f5600ca31 -- cgit v1.2.3 From 74b324b8f328e9d241984de6a9c43825fa298aff Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Fri, 26 Aug 2016 15:23:41 +0200 Subject: Update Chromium MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pulls in a security update and updates our sources to match. Change-Id: I06af8eea04426ee9c695e78cce7c9606eb2b4ab1 Reviewed-by: Michael Brüning --- src/3rdparty | 2 +- src/core/resource_dispatcher_host_delegate_qt.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/3rdparty b/src/3rdparty index 7f6555e99..950d3ff70 160000 --- a/src/3rdparty +++ b/src/3rdparty @@ -1 +1 @@ -Subproject commit 7f6555e9921bfff1886f1e63bb802c252281e882 +Subproject commit 950d3ff70f627f0ee30251a84967222d5449e46d diff --git a/src/core/resource_dispatcher_host_delegate_qt.cpp b/src/core/resource_dispatcher_host_delegate_qt.cpp index 73a640207..af8b02e1b 100644 --- a/src/core/resource_dispatcher_host_delegate_qt.cpp +++ b/src/core/resource_dispatcher_host_delegate_qt.cpp @@ -92,7 +92,7 @@ QString ResourceDispatcherHostLoginDelegateQt::realm() const QString ResourceDispatcherHostLoginDelegateQt::host() const { - return QString::fromStdString(m_authInfo->challenger.ToString()); + return QString::fromStdString(m_authInfo->challenger.host()); } bool ResourceDispatcherHostLoginDelegateQt::isProxy() const -- cgit v1.2.3 From 2209add7a5b019afef7830d8bbf416fbb2a2ecf5 Mon Sep 17 00:00:00 2001 From: Adam Kallai Date: Mon, 29 Aug 2016 18:35:20 +0200 Subject: Clicking on a select box option, did not work There was introcuded a new logic which proves that no mouse / keyboard events are forwarded to Chromium if the view has no focus, and activeFocusOnPress is set to false. The selection box get focus when the user click on it, but the popup window never get (focus is on QuickRootItem) in this case these mouse events are ignored to forward to Chromium. Task-number: QTBUG-54795 Change-Id: Id6e81ee39dcde21a6c5c46e302888b9e9478352f Reviewed-by: Allan Sandfeld Jensen --- src/webengine/render_widget_host_view_qt_delegate_quick.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/webengine/render_widget_host_view_qt_delegate_quick.cpp b/src/webengine/render_widget_host_view_qt_delegate_quick.cpp index e198e5e0d..290f3f9b0 100644 --- a/src/webengine/render_widget_host_view_qt_delegate_quick.cpp +++ b/src/webengine/render_widget_host_view_qt_delegate_quick.cpp @@ -234,7 +234,7 @@ void RenderWidgetHostViewQtDelegateQuick::mousePressEvent(QMouseEvent *event) QQuickItem *parent = parentItem(); if (!m_isPopup && (parent && parent->property("activeFocusOnPress").toBool())) forceActiveFocus(); - if (parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { + if (!m_isPopup && parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { event->ignore(); return; } @@ -254,7 +254,7 @@ void RenderWidgetHostViewQtDelegateQuick::mouseMoveEvent(QMouseEvent *event) void RenderWidgetHostViewQtDelegateQuick::mouseReleaseEvent(QMouseEvent *event) { QQuickItem *parent = parentItem(); - if (parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { + if (!m_isPopup && parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { event->ignore(); return; } @@ -292,7 +292,7 @@ void RenderWidgetHostViewQtDelegateQuick::touchEvent(QTouchEvent *event) void RenderWidgetHostViewQtDelegateQuick::hoverMoveEvent(QHoverEvent *event) { QQuickItem *parent = parentItem(); - if (parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { + if (!m_isPopup && parent && !parent->property("activeFocusOnPress").toBool() && !parent->hasActiveFocus()) { event->ignore(); return; } -- cgit v1.2.3 From 44f41d30ed3efce2f1970dcd158555b41b38014d Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 16 Aug 2016 16:55:24 +0200 Subject: Qt Designer plugin: Add a dummy class for querying properties Add a lightweight "fake" QWebEngineView class that is returned when Qt Designer queries the default property values by calling QDesignerCustomWidgetInterface::createWidget() with 0 parent, preventing crashes during QWebEngine initialization. Task-number: QTBUG-53984 Change-Id: Iced64b7d8af4c958fe7e29fa2f64bb9b681fbab2 Reviewed-by: Kai Koehne --- .../qwebengineview/qwebengineview_plugin.cpp | 4 ++- src/plugins/qwebengineview/qwebengineview_plugin.h | 34 ++++++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/src/plugins/qwebengineview/qwebengineview_plugin.cpp b/src/plugins/qwebengineview/qwebengineview_plugin.cpp index 2d331571b..c885816c5 100644 --- a/src/plugins/qwebengineview/qwebengineview_plugin.cpp +++ b/src/plugins/qwebengineview/qwebengineview_plugin.cpp @@ -91,7 +91,9 @@ bool QWebEngineViewPlugin::isContainer() const QWidget *QWebEngineViewPlugin::createWidget(QWidget *parent) { - return new QWebEngineView(parent); + if (parent) + return new QWebEngineView(parent); + return new fake::QWebEngineView; } bool QWebEngineViewPlugin::isInitialized() const diff --git a/src/plugins/qwebengineview/qwebengineview_plugin.h b/src/plugins/qwebengineview/qwebengineview_plugin.h index 8fa94625c..7c6f02e2a 100644 --- a/src/plugins/qwebengineview/qwebengineview_plugin.h +++ b/src/plugins/qwebengineview/qwebengineview_plugin.h @@ -38,9 +38,43 @@ #define QWEBENGINEVIEW_PLUGIN_H #include +#include +#include +#include QT_BEGIN_NAMESPACE +namespace fake { +// A lightweight "fake" QWebEngineView class that is returned when Qt Designer +// queries the default property values by calling +// QDesignerCustomWidgetInterface::createWidget() with 0 parent, preventing +// crashes during QWebEngine initialization (QTBUG-53984). +// The property list needs to be kept in sync with QWebEngineView. +class QWebEngineView : public QWidget { + Q_OBJECT + Q_PROPERTY(QString title READ title) + Q_PROPERTY(QUrl url READ url WRITE setUrl) // Designable + Q_PROPERTY(QUrl iconUrl READ iconUrl) + Q_PROPERTY(QIcon icon READ icon) + Q_PROPERTY(QString selectedText READ selectedText) + Q_PROPERTY(bool hasSelection READ hasSelection) + Q_PROPERTY(qreal zoomFactor READ zoomFactor WRITE setZoomFactor) // Designable + +public: + explicit QWebEngineView(QWidget *parent = Q_NULLPTR) : QWidget(parent) {} + + QString title() const { return QString(); } + QUrl url() const { return QUrl(); } + void setUrl(const QUrl &) {} + QUrl iconUrl() const { return QUrl(); } + QIcon icon() const { return QIcon(); } + QString selectedText() { return QString(); } + bool hasSelection() { return false; } + qreal zoomFactor() const { return 1; } + void setZoomFactor(qreal) {} +}; +} // namespace fake + class QWebEngineViewPlugin: public QObject, public QDesignerCustomWidgetInterface { Q_OBJECT -- cgit v1.2.3 From 63d45d68fb82c581a634a51b7d48b1f3de2bb97e Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Mon, 5 Sep 2016 16:44:49 +0200 Subject: Improve QWebEngineSettings::JavascriptCanOpenWindows docs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I44105c768a958714590b979d3877724f0db659ee Reviewed-by: Michael Brüning --- src/webengine/api/qquickwebenginesettings.cpp | 2 +- src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/webengine/api/qquickwebenginesettings.cpp b/src/webengine/api/qquickwebenginesettings.cpp index 525d6c8c4..92141704c 100644 --- a/src/webengine/api/qquickwebenginesettings.cpp +++ b/src/webengine/api/qquickwebenginesettings.cpp @@ -96,7 +96,7 @@ bool QQuickWebEngineSettings::javascriptEnabled() const /*! \qmlproperty bool WebEngineSettings::javascriptCanOpenWindows - Allows JavaScript programs to open new windows. + Allows JavaScript programs to open popup windows without user interaction. Enabled by default. */ diff --git a/src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc b/src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc index fde034c6a..0193f41c9 100644 --- a/src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc +++ b/src/webenginewidgets/doc/src/qwebenginesettings_lgpl.qdoc @@ -91,7 +91,8 @@ \value JavascriptEnabled Enables the running of JavaScript programs. Enabled by default. \value JavascriptCanOpenWindows - Allows JavaScript programs to open new windows. Enabled by default. + Allows JavaScript programs to open popup windows without user + interaction. Enabled by default. \value JavascriptCanAccessClipboard Allows JavaScript programs to read from and write to the clipboard. Disabled by default. -- cgit v1.2.3 From ce2f1b140d2d417f925ec54c8a095981827f7e68 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 6 Sep 2016 15:27:50 +0200 Subject: Do not assume neon on armv7 Chromium defaults to arm_neon=1 and then sets -mfpu=neon if the arm architecture is 7. Change-Id: Ib144dd4188ba4221ed35367026de9f9a04c69792 Reviewed-by: Michal Klocek --- src/core/gyp_run.pro | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro index 885df908c..ee62e5d72 100644 --- a/src/core/gyp_run.pro +++ b/src/core/gyp_run.pro @@ -79,6 +79,10 @@ contains(QT_ARCH, "arm") { contains(MFPU, "neon")|contains(MFPU, "neon-vfpv4"): GYP_CONFIG += arm_fpu=\"$$MFPU\" arm_neon=1 else:!lessThan(MARMV, 7): GYP_CONFIG += arm_neon=0 arm_neon_optional=1 else: GYP_CONFIG += arm_fpu=\"$$MFPU\" arm_neon=0 arm_neon_optional=0 + } else { + # Chromium defaults to arm_neon=1, Qt does not. + GYP_CONFIG += arm_neon=0 + !lessThan(MARMV, 7): GYP_CONFIG += arm_neon_optional=1 } contains(QMAKE_CFLAGS, "-marm"): GYP_CONFIG += arm_thumb=0 -- cgit v1.2.3 From aafbdfb92406c9b5459a976170c516773b267a64 Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Thu, 8 Sep 2016 15:52:16 +0200 Subject: Doc: Add type name (WebEngineView) to the SavePage enum value in docs Change-Id: Ica90790662929f1141419ccd38d34d3c9d55be32 Reviewed-by: Kai Koehne --- src/webengine/doc/src/webengineview.qdoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/webengine/doc/src/webengineview.qdoc b/src/webengine/doc/src/webengineview.qdoc index 19804a141..8d0e64416 100644 --- a/src/webengine/doc/src/webengineview.qdoc +++ b/src/webengine/doc/src/webengineview.qdoc @@ -800,7 +800,7 @@ (Added in Qt 5.6) \value WebEngineView.ExitFullScreen Exit the fullscreen mode. (Added in Qt 5.6) - \value SavePage + \value WebEngineView.SavePage Save the current web page to disk. (Added in Qt 5.7) \omitvalue WebActionCount -- cgit v1.2.3 From 8730e6608a72683a67ec89bb201720baf3eae1ed Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Thu, 8 Sep 2016 16:03:09 +0200 Subject: Doc: QWebEngineContextMenuData is in the QtWebEngineWidgets module It was listed in the wrong place, because the value of the \inmodule command was wrong. Task-number: QTBUG-55872 Change-Id: Ie3df6bb261dd75178bbe0f118d7720e2bff6d205 Reviewed-by: Kai Koehne --- src/webenginewidgets/api/qwebenginecontextmenudata.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/webenginewidgets/api/qwebenginecontextmenudata.cpp b/src/webenginewidgets/api/qwebenginecontextmenudata.cpp index c7019977b..4d72071e5 100644 --- a/src/webenginewidgets/api/qwebenginecontextmenudata.cpp +++ b/src/webenginewidgets/api/qwebenginecontextmenudata.cpp @@ -56,7 +56,7 @@ ASSERT_ENUMS_MATCH(QtWebEngineCore::WebEngineContextMenuData::MediaTypePlugin, Q \since 5.7 \brief The QWebEngineContextMenuData class provides context data for populating or extending a context menu with actions. - \inmodule QtWebEngine + \inmodule QtWebEngineWidgets QWebEngineContextMenuData is returned by QWebEnginePage::contextMenuData() after a context menu event, and contains information about where the context menu event took place. This is also in the context -- cgit v1.2.3 From 9766adb01943873d9109968911734be8e5dcb150 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Thu, 8 Sep 2016 11:48:22 +0200 Subject: Fix build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We now get a multiword value from $$pkgConfigExecutable which will cause us to treat it as multiple gyp config sets, which will make gyp fail. Change-Id: Icdf781bb633d804ff6355e882dc4997bb5f3310f Reviewed-by: Michael Brüning --- src/core/gyp_run.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro index 71c1e063c..9b45af3be 100644 --- a/src/core/gyp_run.pro +++ b/src/core/gyp_run.pro @@ -19,7 +19,7 @@ cross_compile { GYP_CONFIG += qtwe_process_name_debug=$$QTWEBENGINEPROCESS_NAME_DEBUG GYP_CONFIG += qtwe_process_name_release=$$QTWEBENGINEPROCESS_NAME_RELEASE GYP_CONFIG += disable_glibcxx_debug=1 -!contains(QT_CONFIG, no-pkg-config): GYP_CONFIG += pkg-config=$$pkgConfigExecutable() +!contains(QT_CONFIG, no-pkg-config): GYP_ARGS += "-D pkg-config=\"$$pkgConfigExecutable()\"" !webcore_debug: GYP_CONFIG += remove_webcore_debug_symbols=1 !v8base_debug: GYP_CONFIG += remove_v8base_debug_symbols=1 -- cgit v1.2.3 From 527af790d460f0ec486fdbb667a36164a829761e Mon Sep 17 00:00:00 2001 From: Viktor Engelmann Date: Tue, 16 Aug 2016 13:50:43 +0200 Subject: Resolved nullptr dereference bug In line 282f of chromium/content/browser/frame_host/render_frame_host_manager.cc, RenderFrameHostManager::Navigate passes nullptr to WebContentsImpl::NotifyViewSwapped. In line 3833f of chromium/content/browser/web_contents/web_contents_impl.cc, this is passed on to the observers, including UserResourceControllerHost::WebContentsObserverHelper::RenderViewHostChanged which dereferenced it unchecked, causing a crash. Task-number: QTBUG-55254 Change-Id: Ibdb6645f63957d28a89c50b51faeb3aea086a8b3 Reviewed-by: Kai Koehne --- src/core/user_script_controller_host.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/user_script_controller_host.cpp b/src/core/user_script_controller_host.cpp index a0d3f6fed..4dcd1a071 100644 --- a/src/core/user_script_controller_host.cpp +++ b/src/core/user_script_controller_host.cpp @@ -78,7 +78,8 @@ void UserScriptControllerHost::WebContentsObserverHelper::RenderViewCreated(cont void UserScriptControllerHost::WebContentsObserverHelper::RenderViewHostChanged(content::RenderViewHost *oldHost, content::RenderViewHost *newHost) { - oldHost->Send(new RenderViewObserverHelper_ClearScripts(oldHost->GetRoutingID())); + if (oldHost) + oldHost->Send(new RenderViewObserverHelper_ClearScripts(oldHost->GetRoutingID())); content::WebContents *contents = web_contents(); Q_FOREACH (const UserScript &script, m_controllerHost->m_perContentsScripts.value(contents)) -- cgit v1.2.3 From 2f24e3c307aecb657736310948c7cdaad5176678 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 6 Sep 2016 13:57:41 +0200 Subject: Add changes file for 5.6.2 Change-Id: I45fcde261328114510ce260a30ad83b8d598c222 Reviewed-by: Kai Koehne --- dist/changes-5.6.2 | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 dist/changes-5.6.2 diff --git a/dist/changes-5.6.2 b/dist/changes-5.6.2 new file mode 100644 index 000000000..7fa2e0052 --- /dev/null +++ b/dist/changes-5.6.2 @@ -0,0 +1,62 @@ +Qt 5.6.2 is a bug-fix release. It maintains both forward and backward +compatibility (source and binary) with Qt 5.6.0. + +Qt 5.6 introduces many new features and improvements as well as bugfixes +over the 5.5.x series. For more details, refer to the online documentation +included in this distribution. The documentation is also available online: + + http://doc.qt.io/qt-5/index.html + +The Qt version 5.6 series is binary compatible with the 5.5.x series. +Applications compiled for 5.5 will continue to run with 5.6. + +Some of the changes listed in this file include issue tracking numbers +corresponding to tasks in the Qt Bug Tracker: + + https://bugreports.qt.io/ + +Each of these identifiers can be entered in the bug tracker to obtain more +information about a particular change. + +**************************************************************************** +* General * +**************************************************************************** + + - Chromium Snapshot: + * Security fixes from Chromium up to version 52.0.2743.116. + Including: CVE-2016-1706, CVE-2016-1710, CVE-2016-1711, CVE-2016-5127, + CVE-2016-5128, CVE-2016-5129, CVE-2016-5130, CVE-2016-5131, + CVE-2016-5134, CVE-2016-5137. + * [QTBUG-53800] Fixed assert on load. + + - QtWebEngineCore: + * Enabled following hotspot hints in custom cursors. + * Added support for more CSS cursor types on Windows and Linux. + * Fixed several IME issues. + * [QTBUG-54419] Fixed crash in user scripts. + + - WebEnginePage: + * Fixed crash on blocked new window requests. + + +**************************************************************************** +* Platform Specific Changes * +**************************************************************************** + + - Linux: + * Fixed builds against system FFMPEG 3. + * [QTBUG-53956] Fixed builds with GCC 6 that were breaking due to + undefined use of 'this' pointer in Chromium. + * Removed potential runtime dependency on Linux 4.5 if MADV_FREE was + defined. + * [QTBUG-53685] Added support for linux-clang-libc++. + * [QTBUG-48969, QTBUG-52575] Fixed memory leak when using two separate + X11 screens instead of xrandr. + + - Windows: + * [QTBUG-48285, QTBUG-52938] Fixed problems with debug symbols. + * [QTBUG-54455] Fixed building with VS 2015 update 3. + + - macOS: + * [QTBUG-54023] Fixed crash in libjpeg_turbo. + -- cgit v1.2.3 From 4688a73f9bc8aab8f64ae8eee64d19e7bb5f63b7 Mon Sep 17 00:00:00 2001 From: Peter Varga Date: Thu, 8 Sep 2016 16:39:47 +0200 Subject: Fix test_scrollPositionAfterReload quick auto test Wait for scroll position change before reload. Task-number: QTBUG-55855 Change-Id: Ia42af1a4a76b2c507f4a88b39a469e3e37184ef7 Reviewed-by: Adam Kallai Reviewed-by: Allan Sandfeld Jensen --- tests/auto/quick/qmltests/data/tst_scrollPosition.qml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/auto/quick/qmltests/data/tst_scrollPosition.qml b/tests/auto/quick/qmltests/data/tst_scrollPosition.qml index 08bb0f3b4..55b71189d 100644 --- a/tests/auto/quick/qmltests/data/tst_scrollPosition.qml +++ b/tests/auto/quick/qmltests/data/tst_scrollPosition.qml @@ -69,7 +69,11 @@ TestWebEngineView { tryCompare(webEngineView.scrollPosition, "y", 0); keyPress(Qt.Key_Return); // Focus is on the scroll button. - scrollPositionSpy.wait(); + + // Wait for proper scroll position change otherwise we cannot expect + // the new y position after reload. + tryCompare(webEngineView.scrollPosition, "x", 0); + tryCompare(webEngineView.scrollPosition, "y", 600); webEngineView.reload(); verify(webEngineView.waitForLoadSucceeded()); -- cgit v1.2.3 From 667fdf11b7d242335254919c898231a48604517d Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Fri, 16 Sep 2016 16:02:05 +0200 Subject: Update Chromium MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pulls in the first batch of cherry-picked security patches from the 53 release. Change-Id: Ife72ecef309249e4f80ca9b7cc478bd4e236e094 Reviewed-by: Michael Brüning --- src/3rdparty | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/3rdparty b/src/3rdparty index 950d3ff70..f2097bbd2 160000 --- a/src/3rdparty +++ b/src/3rdparty @@ -1 +1 @@ -Subproject commit 950d3ff70f627f0ee30251a84967222d5449e46d +Subproject commit f2097bbd2fb2161122764f056b4af6a1260187fa -- cgit v1.2.3 From d6c8a2cf8fa374e6d1c0a578391b57112c047fa4 Mon Sep 17 00:00:00 2001 From: David Faure Date: Mon, 5 Sep 2016 15:25:02 +0200 Subject: Enable -fno_delete_null_pointer_checks for g++ 6 on all of chromium This is necessary e.g. for PaintLayer::enclosingSelfPaintingLayer which also compares this with null. Change-Id: I85d69432a0d7eeb0d8df8f395821880e36180dcc Reviewed-by: Allan Sandfeld Jensen --- src/core/config/linux.pri | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/config/linux.pri b/src/core/config/linux.pri index 9264932c4..a318e170c 100644 --- a/src/core/config/linux.pri +++ b/src/core/config/linux.pri @@ -29,7 +29,7 @@ use?(nss) { use_openssl_certs=1 } -gcc:!clang: greaterThan(QT_GCC_MAJOR_VERSION, 5): GYP_CONFIG += v8_no_delete_null_pointer_checks=1 +gcc:!clang: greaterThan(QT_GCC_MAJOR_VERSION, 5): GYP_CONFIG += no_delete_null_pointer_checks=1 contains(QT_CONFIG, system-zlib): use?(system_minizip): GYP_CONFIG += use_system_zlib=1 contains(QT_CONFIG, system-png): GYP_CONFIG += use_system_libpng=1 -- cgit v1.2.3 From 0e5553a1626cb707499d82c96e136ceb79dfb54d Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Mon, 19 Sep 2016 15:18:03 +0200 Subject: Doc: Fix types of \qmlproperty Change-Id: Ibb470580404f2b09dc8c7c2de275ade97251d612 Reviewed-by: Leena Miettinen --- src/webengine/api/qquickwebenginecontextmenudata.cpp | 10 +++++----- src/webengine/api/qquickwebenginescript.cpp | 2 +- src/webengine/doc/src/webengineview.qdoc | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/webengine/api/qquickwebenginecontextmenudata.cpp b/src/webengine/api/qquickwebenginecontextmenudata.cpp index 8f02b220a..2cc6eaf4b 100644 --- a/src/webengine/api/qquickwebenginecontextmenudata.cpp +++ b/src/webengine/api/qquickwebenginecontextmenudata.cpp @@ -84,7 +84,7 @@ bool QQuickWebEngineContextMenuData::isValid() const } /*! - \qmlproperty QPoint WebEngineContextMenuData::position + \qmlproperty point WebEngineContextMenuData::position Returns the position of the context, usually the mouse position where the context menu event was triggered. @@ -95,7 +95,7 @@ QPoint QQuickWebEngineContextMenuData::position() const } /*! - \qmlproperty QString WebEngineContextMenuData::linkText + \qmlproperty string WebEngineContextMenuData::linkText Returns the text of a link if the context is a link. */ @@ -105,7 +105,7 @@ QString QQuickWebEngineContextMenuData::linkText() const } /*! - \qmlproperty QUrl WebEngineContextMenuData::linkUrl + \qmlproperty url WebEngineContextMenuData::linkUrl Returns the URL of a link if the context is a link. */ @@ -115,7 +115,7 @@ QUrl QQuickWebEngineContextMenuData::linkUrl() const } /*! - \qmlproperty QString WebEngineContextMenuData::selectedText + \qmlproperty string WebEngineContextMenuData::selectedText Returns the selected text of the context. */ @@ -125,7 +125,7 @@ QString QQuickWebEngineContextMenuData::selectedText() const } /*! - \qmlproperty QUrl WebEngineContextMenuData::mediaUrl + \qmlproperty url WebEngineContextMenuData::mediaUrl If the context is a media element, returns the URL of that media. */ diff --git a/src/webengine/api/qquickwebenginescript.cpp b/src/webengine/api/qquickwebenginescript.cpp index a1c903df3..7e08e2fd5 100644 --- a/src/webengine/api/qquickwebenginescript.cpp +++ b/src/webengine/api/qquickwebenginescript.cpp @@ -105,7 +105,7 @@ QString QQuickWebEngineScript::toString() const } /*! - \qmlproperty QString WebEngineScript::name + \qmlproperty string WebEngineScript::name The name of the script. Can be useful to retrieve a particular script from \l{WebEngineView::userScripts}{WebEngineView.userScripts}. diff --git a/src/webengine/doc/src/webengineview.qdoc b/src/webengine/doc/src/webengineview.qdoc index 8d0e64416..b72e405a8 100644 --- a/src/webengine/doc/src/webengineview.qdoc +++ b/src/webengine/doc/src/webengineview.qdoc @@ -342,21 +342,21 @@ */ /*! - \qmlproperty QSizeF WebEngineView::contentsSize + \qmlproperty size WebEngineView::contentsSize \since QtWebEngine 1.3 Size of the page contents. */ /*! - \qmlproperty QPointF WebEngineView::scrollPosition + \qmlproperty point WebEngineView::scrollPosition \since QtWebEngine 1.3 Scroll position of the page contents. */ /*! - \qmlproperty uint WebEngineView::webChannelWorld + \qmlproperty int WebEngineView::webChannelWorld \since QtWebEngine 1.3 JavaScript world that the web channel instance used by this view is -- cgit v1.2.3