summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndras Becsi <andras.becsi@digia.com>2014-09-12 16:26:08 +0200
committerAndras Becsi <andras.becsi@digia.com>2014-09-15 18:53:29 +0200
commit04e7b2f41541bb6bf6e944bbe596c3b582c6daf7 (patch)
tree5225e9052f646972f55165f51f43f84a523256eb
parent12916ced18021768158214e2c4fc877eecb7b9a6 (diff)
Fix the build for embedded android
Change-Id: I1edd16e6875198d7480897e7b2e2fbf68b245883 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
-rw-r--r--src/core/config/embedded_android.pri6
-rw-r--r--src/core/qtwebengine.gypi1
-rw-r--r--src/core/render_widget_host_view_qt.h3
-rw-r--r--src/core/surface_factory_qt.cpp3
-rw-r--r--src/core/surface_factory_qt.h7
-rw-r--r--src/core/web_engine_context.cpp13
-rw-r--r--tools/qmake/mkspecs/features/functions.prf1
7 files changed, 17 insertions, 17 deletions
diff --git a/src/core/config/embedded_android.pri b/src/core/config/embedded_android.pri
index 6ffa1c077..878708786 100644
--- a/src/core/config/embedded_android.pri
+++ b/src/core/config/embedded_android.pri
@@ -12,6 +12,7 @@ GYP_CONFIG += \
build_ffmpegsumo=0 \
configuration_policy=0 \
disable_nacl=1 \
+ embedded=1 \
enable_autofill_dialog=0 \
enable_automation=0 \
enable_background=0 \
@@ -30,7 +31,6 @@ GYP_CONFIG += \
enable_webrtc=0 \
gcc_version=46 \
gtest_target_type=none \
- icu_use_data_file_flag=0 \
input_speech=0 \
java_bridge=0 \
media_use_ffmpeg=0 \
@@ -44,6 +44,7 @@ GYP_CONFIG += \
remoting=0 \
safe_browsing=0 \
skia_os=android \
+ test_isolation_mode=noop \
use_aura=0 \
use_cairo=0 \
use_canvas_skia=0 \
@@ -58,11 +59,12 @@ GYP_CONFIG += \
use_libffmpeg=0 \
use_openmax_dl_fft=0 \
use_openssl=1 \
+ use_openssl_certs=1 \
use_ozone=0 \
use_pango=0 \
use_pulseaudio=0 \
use_system_expat=1 \
- use_system_icu=1 \
+ use_system_icu=0 \
use_system_libjpeg=0 \
use_system_skia=0 \
use_system_sqlite=0 \
diff --git a/src/core/qtwebengine.gypi b/src/core/qtwebengine.gypi
index ba08c72c1..17287669f 100644
--- a/src/core/qtwebengine.gypi
+++ b/src/core/qtwebengine.gypi
@@ -59,6 +59,7 @@
'conditions': [
['qt_os=="embedded_android"', {
'dependencies': [
+ '<(chromium_src_dir)/ui/ozone/ozone.gyp:ozone_base',
'<(chromium_src_dir)/third_party/ashmem/ashmem.gyp:ashmem',
'<(chromium_src_dir)/third_party/freetype/freetype.gyp:ft2',
'<(chromium_src_dir)/third_party/android_tools/ndk/android_tools_ndk.gyp:cpu_features',
diff --git a/src/core/render_widget_host_view_qt.h b/src/core/render_widget_host_view_qt.h
index 855a85fff..301ff2df9 100644
--- a/src/core/render_widget_host_view_qt.h
+++ b/src/core/render_widget_host_view_qt.h
@@ -186,7 +186,8 @@ public:
#if defined(OS_ANDROID)
virtual void ShowDisambiguationPopup(const gfx::Rect&, const SkBitmap&) Q_DECL_OVERRIDE { QT_NOT_YET_IMPLEMENTED }
- virtual void HasTouchEventHandlers(bool) Q_DECL_OVERRIDE { QT_NOT_YET_IMPLEMENTED }
+ virtual void LockCompositingSurface() Q_DECL_OVERRIDE { QT_NOT_YET_IMPLEMENTED }
+ virtual void UnlockCompositingSurface() Q_DECL_OVERRIDE { QT_NOT_YET_IMPLEMENTED }
#endif // defined(OS_ANDROID)
#if defined(OS_WIN)
diff --git a/src/core/surface_factory_qt.cpp b/src/core/surface_factory_qt.cpp
index ca48da46e..85b9eb799 100644
--- a/src/core/surface_factory_qt.cpp
+++ b/src/core/surface_factory_qt.cpp
@@ -36,6 +36,7 @@
#include "surface_factory_qt.h"
+#include "gl_context_qt.h"
#include "type_conversion.h"
#include "base/files/file_path.h"
@@ -95,7 +96,7 @@ bool SurfaceFactoryQt::LoadEGLGLES2Bindings(AddGLLibraryCallback add_gl_library,
intptr_t SurfaceFactoryQt::GetNativeDisplay()
{
- static void *display = qApp->platformNativeInterface()->nativeResourceForIntegration(QByteArrayLiteral("nativedisplay"));
+ static void *display = GLContextHelper::getNativeDisplay();
if (display)
return reinterpret_cast<intptr_t>(display);
diff --git a/src/core/surface_factory_qt.h b/src/core/surface_factory_qt.h
index cf9a00875..1b2ec744d 100644
--- a/src/core/surface_factory_qt.h
+++ b/src/core/surface_factory_qt.h
@@ -39,21 +39,20 @@
#if defined(USE_OZONE) || defined(OS_ANDROID)
-#include "ui/gfx/ozone/surface_factory_ozone.h"
+#include "ui/ozone/public/surface_factory_ozone.h"
#include <QtGlobal>
class SurfaceFactoryQt
- : public gfx::SurfaceFactoryOzone
+ : public ui::SurfaceFactoryOzone
{
virtual bool LoadEGLGLES2Bindings(AddGLLibraryCallback add_gl_library, SetGLGetProcAddressProcCallback set_gl_get_proc_address) Q_DECL_OVERRIDE;
virtual intptr_t GetNativeDisplay() Q_DECL_OVERRIDE;
- virtual gfx::SurfaceFactoryOzone::HardwareState InitializeHardware() Q_DECL_OVERRIDE { return gfx::SurfaceFactoryOzone::INITIALIZED; }
+ virtual ui::SurfaceFactoryOzone::HardwareState InitializeHardware() Q_DECL_OVERRIDE { return ui::SurfaceFactoryOzone::INITIALIZED; }
virtual void ShutdownHardware() Q_DECL_OVERRIDE {}
virtual gfx::AcceleratedWidget GetAcceleratedWidget() Q_DECL_OVERRIDE { return 0; }
virtual gfx::AcceleratedWidget RealizeAcceleratedWidget(gfx::AcceleratedWidget w) Q_DECL_OVERRIDE { return 0; }
virtual bool AttemptToResizeAcceleratedWidget(gfx::AcceleratedWidget w, const gfx::Rect& bounds) Q_DECL_OVERRIDE { return false; }
- virtual gfx::VSyncProvider* GetVSyncProvider(gfx::AcceleratedWidget w) Q_DECL_OVERRIDE { return NULL; }
};
#endif
diff --git a/src/core/web_engine_context.cpp b/src/core/web_engine_context.cpp
index 669beccb4..7c0a45b68 100644
--- a/src/core/web_engine_context.cpp
+++ b/src/core/web_engine_context.cpp
@@ -58,6 +58,7 @@
#include "content/utility/in_process_utility_thread.h"
#include "gpu/command_buffer/service/gpu_switches.h"
#include "ui/events/event_switches.h"
+#include "ui/native_theme/native_theme_switches.h"
#include "ui/gl/gl_switches.h"
#if defined(OS_WIN)
#include "sandbox/win/src/sandbox_types.h"
@@ -144,23 +145,18 @@ WebEngineContext::WebEngineContext()
#if defined(QTWEBENGINE_MOBILE_SWITCHES)
// Inspired from the Android port's default switches
- parsedCommandLine->AppendSwitch(switches::kEnableOverlayScrollbars);
+ parsedCommandLine->AppendSwitch(switches::kEnableOverlayScrollbar);
parsedCommandLine->AppendSwitch(switches::kEnableGestureTapHighlight);
parsedCommandLine->AppendSwitch(switches::kEnablePinch);
parsedCommandLine->AppendSwitch(switches::kEnableViewport);
parsedCommandLine->AppendSwitch(switches::kEnableViewportMeta);
parsedCommandLine->AppendSwitch(switches::kEnableSmoothScrolling);
- parsedCommandLine->AppendSwitch(switches::kDisableAcceleratedVideo);
- parsedCommandLine->AppendSwitch(switches::kDisableAudio);
+ parsedCommandLine->AppendSwitch(switches::kDisableAcceleratedVideoDecode);
parsedCommandLine->AppendSwitch(switches::kEnableAcceleratedOverflowScroll);
parsedCommandLine->AppendSwitch(switches::kEnableCompositingForFixedPosition);
- parsedCommandLine->AppendSwitch(switches::kEnableAcceleratedScrollableFrames);
- parsedCommandLine->AppendSwitch(switches::kEnableCompositedScrollingForFrames);
- parsedCommandLine->AppendSwitch(switches::kForceCompositingMode);
parsedCommandLine->AppendSwitch(switches::kDisableGpuShaderDiskCache);
parsedCommandLine->AppendSwitch(switches::kDisable2dCanvasAntialiasing);
- parsedCommandLine->AppendSwitch(switches::kEnableDeadlineScheduling);
- parsedCommandLine->AppendSwitch(cc::switches::kEnableImplSidePainting);
+ parsedCommandLine->AppendSwitch(switches::kEnableImplSidePainting);
parsedCommandLine->AppendSwitch(cc::switches::kDisableCompositedAntialiasing);
parsedCommandLine->AppendSwitchASCII(switches::kProfilerTiming, switches::kProfilerTimingDisabledValue);
@@ -170,7 +166,6 @@ WebEngineContext::WebEngineContext()
// On eAndroid we use this to get the native display
// from Qt in GLSurfaceEGL::InitializeOneOff.
m_surfaceFactory.reset(new SurfaceFactoryQt());
- gfx::SurfaceFactoryOzone::SetInstance(m_surfaceFactory.get());
#endif
GLContextHelper::initialize();
diff --git a/tools/qmake/mkspecs/features/functions.prf b/tools/qmake/mkspecs/features/functions.prf
index 28bc4307f..2c4b9e0c2 100644
--- a/tools/qmake/mkspecs/features/functions.prf
+++ b/tools/qmake/mkspecs/features/functions.prf
@@ -4,6 +4,7 @@ defineTest(isPlatformSupported) {
win32: !contains(QT_CONFIG, angle): return(false)
linux-g++|win32-msvc2013|macx-clang: return(true)
+ android-g++-b2qt: return(true)
return(false)
}