summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@theqtcompany.com>2015-01-14 10:30:35 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2015-01-14 10:30:35 +0100
commita38215f03d20ccbe2e15c16d0a4e3333614cb682 (patch)
tree0286e23d4edfab7e40198f25d1861dac3e0d7e38 /src/core
parentda3c744b6a97660aae34067466d9624e1ca688e4 (diff)
parent7a318602581fac0d4ad414ee62437554e9c9e959 (diff)
Merge "Merge remote-tracking branch 'origin/5.4' into dev" into refs/staging/dev
Diffstat (limited to 'src/core')
-rw-r--r--src/core/content_browser_client_qt.cpp16
-rw-r--r--src/core/content_browser_client_qt.h1
-rw-r--r--src/core/core_module.pro2
-rw-r--r--src/core/delegated_frame_node.cpp4
-rw-r--r--src/core/web_engine_context.cpp4
-rw-r--r--src/core/web_engine_library_info.cpp4
6 files changed, 25 insertions, 6 deletions
diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp
index 1f29e4bec..6dfaa64c7 100644
--- a/src/core/content_browser_client_qt.cpp
+++ b/src/core/content_browser_client_qt.cpp
@@ -42,6 +42,7 @@
#include "content/public/browser/browser_main_parts.h"
#include "content/public/browser/child_process_security_policy.h"
#include "content/public/browser/media_observer.h"
+#include "content/public/browser/quota_permission_context.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/render_view_host.h"
@@ -291,6 +292,16 @@ void ShareGroupQtQuick::AboutToAddFirstContext()
m_shareContextQtQuick = make_scoped_refptr(new QtShareGLContext(shareContext));
}
+class QuotaPermissionContextQt : public content::QuotaPermissionContext {
+public:
+ virtual void RequestQuotaPermission(const content::StorageQuotaParams &params, int render_process_id, const PermissionCallback &callback) Q_DECL_OVERRIDE
+ {
+ Q_UNUSED(params);
+ Q_UNUSED(render_process_id);
+ callback.Run(QUOTA_PERMISSION_RESPONSE_DISALLOW);
+ }
+};
+
ContentBrowserClientQt::ContentBrowserClientQt()
: m_browserMainParts(0)
{
@@ -364,6 +375,11 @@ void ContentBrowserClientQt::enableInspector(bool enable, content::BrowserContex
}
}
+content::QuotaPermissionContext *ContentBrowserClientQt::CreateQuotaPermissionContext()
+{
+ return new QuotaPermissionContextQt;
+}
+
void ContentBrowserClientQt::AllowCertificateError(int render_process_id, int render_frame_id, int cert_error,
const net::SSLInfo& ssl_info, const GURL& request_url,
ResourceType::Type resource_type,
diff --git a/src/core/content_browser_client_qt.h b/src/core/content_browser_client_qt.h
index cc66f6a3b..d5b49e835 100644
--- a/src/core/content_browser_client_qt.h
+++ b/src/core/content_browser_client_qt.h
@@ -80,6 +80,7 @@ public:
virtual gfx::GLShareGroup* GetInProcessGpuShareGroup() Q_DECL_OVERRIDE;
virtual content::MediaObserver* GetMediaObserver() Q_DECL_OVERRIDE;
virtual content::AccessTokenStore* CreateAccessTokenStore() Q_DECL_OVERRIDE;
+ virtual content::QuotaPermissionContext *CreateQuotaPermissionContext() Q_DECL_OVERRIDE;
virtual void OverrideWebkitPrefs(content::RenderViewHost *, const GURL &, WebPreferences *) Q_DECL_OVERRIDE;
virtual void AllowCertificateError(
int render_process_id,
diff --git a/src/core/core_module.pro b/src/core/core_module.pro
index 1a7b0878f..8801dd4cf 100644
--- a/src/core/core_module.pro
+++ b/src/core/core_module.pro
@@ -1,8 +1,6 @@
MODULE = webenginecore
TARGET = QtWebEngineCore
-CMAKE_MODULE_TESTS = "-"
-
qtHaveModule(positioning):QT += positioning
QT += qml quick
QT_PRIVATE += quick-private gui-private core-private
diff --git a/src/core/delegated_frame_node.cpp b/src/core/delegated_frame_node.cpp
index 0a24333db..8d09794be 100644
--- a/src/core/delegated_frame_node.cpp
+++ b/src/core/delegated_frame_node.cpp
@@ -189,7 +189,7 @@ static void waitChromiumSync(gfx::TransferableFence *sync)
static PFNEGLCLIENTWAITSYNCKHRPROC eglClientWaitSyncKHR = 0;
if (!resolved) {
- if (gfx::GLSurfaceQt::HasEGLExtension("EGL_KHR_reusable_sync")) {
+ if (gfx::GLSurfaceQt::HasEGLExtension("EGL_KHR_fence_sync")) {
QOpenGLContext *context = QOpenGLContext::currentContext();
eglClientWaitSyncKHR = (PFNEGLCLIENTWAITSYNCKHRPROC)context->getProcAddress("eglClientWaitSyncKHR");
}
@@ -232,7 +232,7 @@ static void deleteChromiumSync(gfx::TransferableFence *sync)
static PFNEGLDESTROYSYNCKHRPROC eglDestroySyncKHR = 0;
if (!resolved) {
- if (gfx::GLSurfaceQt::HasEGLExtension("EGL_KHR_reusable_sync")) {
+ if (gfx::GLSurfaceQt::HasEGLExtension("EGL_KHR_fence_sync")) {
QOpenGLContext *context = QOpenGLContext::currentContext();
eglDestroySyncKHR = (PFNEGLDESTROYSYNCKHRPROC)context->getProcAddress("eglDestroySyncKHR");
}
diff --git a/src/core/web_engine_context.cpp b/src/core/web_engine_context.cpp
index d02202760..d48c23815 100644
--- a/src/core/web_engine_context.cpp
+++ b/src/core/web_engine_context.cpp
@@ -41,6 +41,7 @@
#include "base/base_switches.h"
#include "base/command_line.h"
#include "base/files/file_path.h"
+#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "base/threading/thread_restrictions.h"
#include "cc/base/switches.h"
@@ -134,6 +135,9 @@ bool usingQtQuick2DRenderer()
WebEngineContext::~WebEngineContext()
{
+ base::MessagePump::Delegate *delegate = m_runLoop->loop_;
+ // Flush the UI message loop before quitting.
+ while (delegate->DoWork()) { }
GLContextHelper::destroy();
m_runLoop->AfterRun();
}
diff --git a/src/core/web_engine_library_info.cpp b/src/core/web_engine_library_info.cpp
index 5f597b92b..09e2af495 100644
--- a/src/core/web_engine_library_info.cpp
+++ b/src/core/web_engine_library_info.cpp
@@ -171,7 +171,7 @@ QString localesPath()
#if defined(OS_MACOSX) && defined(QT_MAC_FRAMEWORK_BUILD)
return getResourcesPath(frameworkBundle()) % QLatin1String("/qtwebengine_locales");
#else
- return location(QLibraryInfo::TranslationsPath) % QLatin1String("/qtwebengine_locales");
+ return location(QLibraryInfo::TranslationsPath) % QDir::separator() % QLatin1String("qtwebengine_locales");
#endif
}
@@ -204,7 +204,7 @@ base::FilePath WebEngineLibraryInfo::getPath(int key)
#if defined(OS_MACOSX) && defined(QT_MAC_FRAMEWORK_BUILD)
return toFilePath(getResourcesPath(frameworkBundle()) % QLatin1String("/qtwebengine_resources.pak"));
#else
- return toFilePath(location(QLibraryInfo::DataPath) % QLatin1String("/qtwebengine_resources.pak"));
+ return toFilePath(location(QLibraryInfo::DataPath) % QDir::separator() % QLatin1String("qtwebengine_resources.pak"));
#endif
case base::FILE_EXE:
case content::CHILD_PROCESS_EXE: