From 730947ce5da119ba158a5ee74bea9a26490c20b3 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Fri, 20 Dec 2019 12:08:48 +0530 Subject: [PATCH 01/16] [M76 Migration] Fix Pinch Zoom id is missed in ui::TouchEvent object. This patch fills ui::PointerDetails with id and POINTER_TYPE_TOUCH. Reference: https://review.tizen.org/gerrit/#/c/200850/ Change-Id: I5f7781c8d8a3a8433f731625b06f75bb8f1dd9ba Signed-off-by: Chandan Padhi (cherry picked from commit e34acd8c055ea97c8c48838a9ce534c9ee07fdd0) --- .../content/browser/renderer_host/web_event_factory_efl.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/web_event_factory_efl.cc b/tizen_src/chromium_impl/content/browser/renderer_host/web_event_factory_efl.cc index e3223f4..7a7ddf3 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/web_event_factory_efl.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/web_event_factory_efl.cc @@ -525,10 +525,10 @@ ui::TouchEvent MakeTouchEvent(Evas_Coord_Point pt, if (timestamp == 0) event_timestamp = ui::EventTimeForNow(); - // FIXME: M63 bring up. Fill up pointer details - return ui::TouchEvent(EvasTouchEventTypeToUI(state), - gfx::Point(pt.x / scale, pt.y / scale), event_timestamp, - ui::PointerDetails()); + return ui::TouchEvent( + EvasTouchEventTypeToUI(state), gfx::Point(pt.x / scale, pt.y / scale), + event_timestamp, + ui::PointerDetails(ui::EventPointerType::POINTER_TYPE_TOUCH, id)); } template WebGestureEvent MakeGestureEvent( -- 2.7.4 From c8ad7abbb98b1ce38ae338de11977b55c768c0e3 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Fri, 20 Dec 2019 14:20:51 +0530 Subject: [PATCH 02/16] [M76 Migration][Rendering] Fix scale factor for wearable Currently, device scale factor for wearable profile is calculated similar to that for mobile profile. But in case of wearable profile, device scale factor should be "1.0". Reference: https://review.tizen.org/gerrit/#/c/200822/ Change-Id: I43dd3a79aaed61834138f0a6f5604c5ccd6961de Signed-off-by: Chandan Padhi (cherry picked from commit 8ac80870195691dbc4bae901db444358564015a6) --- tizen_src/chromium_impl/ui/display/device_display_info_efl.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc b/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc index f65fde8..8d522c0 100644 --- a/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc +++ b/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc @@ -169,7 +169,7 @@ int DeviceDisplayInfoEfl::GetDisplayHeight() const { } double DeviceDisplayInfoEfl::ComputeDIPScale(int dpi) const { - if (IsMobileProfile() || IsWearableProfile()) { + if (IsMobileProfile()) { double dip_scale = static_cast(GetDensityRange(dpi)); DCHECK(dip_scale); dip_scale /= kBaselineDPIDensity; -- 2.7.4 From 7054b13c6cc7fc42fd6398d3034bb445ed36bc93 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Fri, 20 Dec 2019 14:14:38 +0530 Subject: [PATCH 03/16] [M76 Migration] Remove pixmap related files This commit removes pixmap related files as we no longer use X11. Reference: https://review.tizen.org/gerrit/c/200799/ Change-Id: Idc30180aa041954b9dbba3f4c3a7fe74f1c51087 Signed-off-by: Chandan Padhi (cherry picked from commit 35cdc5074febf42bc3865e1406aac11b8e0ee396) --- .../gpu/client/gpu_memory_buffer_impl_efl.cc | 134 ----- .../client/gpu_memory_buffer_impl_efl_pixmap.cc | 202 ------- .../gpu/client/gpu_memory_buffer_impl_efl_pixmap.h | 69 --- .../common/gpu/gpu_memory_buffer_factory_efl.cc | 112 ---- .../gpu/gpu_memory_buffer_factory_efl_pixmap.cc | 61 --- .../gpu/gpu_memory_buffer_factory_efl_pixmap.h | 52 -- tizen_src/chromium_impl/ui/gl/efl_pixmap.cc | 578 --------------------- tizen_src/chromium_impl/ui/gl/efl_pixmap.h | 109 ---- .../chromium_impl/ui/gl/gl_image_efl_pixmap.cc | 144 ----- .../chromium_impl/ui/gl/gl_image_efl_pixmap.h | 60 --- 10 files changed, 1521 deletions(-) delete mode 100644 tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl.cc delete mode 100644 tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.cc delete mode 100644 tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h delete mode 100644 tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl.cc delete mode 100644 tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.cc delete mode 100644 tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h delete mode 100644 tizen_src/chromium_impl/ui/gl/efl_pixmap.cc delete mode 100644 tizen_src/chromium_impl/ui/gl/efl_pixmap.h delete mode 100644 tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.cc delete mode 100644 tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.h diff --git a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl.cc b/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl.cc deleted file mode 100644 index 15c7559..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl.cc +++ /dev/null @@ -1,134 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - - -#include "base/command_line.h" -#include "content/common/gpu/client/gpu_memory_buffer_impl.h" -#include "content/public/common/content_switches.h" - - -#include "content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h" -#include "content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.h" - -#include "base/process/process.h" -#include "base/threading/platform_thread.h" - -namespace content { - -namespace { -static bool IsZeroCopyEnabled() { - static bool zero_copy_enabled = - CommandLine::ForCurrentProcess()->HasSwitch(switches::kEnableZeroCopy); - return zero_copy_enabled; -} -} - -// static -void GpuMemoryBufferImpl::Create(gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - Usage usage, - int client_id, - const CreationCallback& callback) { - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - if (IsZeroCopyEnabled() && - GpuMemoryBufferImplEflPixmap::IsConfigurationSupported(format, usage)) { - GpuMemoryBufferImplEflPixmap::Create(id, size, format, client_id, callback); - return; - } -#else - NOTIMPLEMENTED(); -#endif - - if (GpuMemoryBufferImplSharedMemory::IsConfigurationSupported( - size, format, usage)) { - GpuMemoryBufferImplSharedMemory::Create(id, size, format, callback); - return; - } - - callback.Run(scoped_ptr()); -} - -// static -void GpuMemoryBufferImpl::AllocateForChildProcess( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - Usage usage, - base::ProcessHandle child_process, - int child_client_id, - const AllocationCallback& callback) { - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - if (IsZeroCopyEnabled() && - GpuMemoryBufferImplEflPixmap::IsConfigurationSupported(format, usage)) { - GpuMemoryBufferImplEflPixmap::AllocateForChildProcess( - id, size, format, child_client_id, callback); - return; - } -#else - NOTIMPLEMENTED(); -#endif - - if (GpuMemoryBufferImplSharedMemory::IsConfigurationSupported( - size, format, usage)) { - GpuMemoryBufferImplSharedMemory::AllocateForChildProcess( - id, size, format, child_process, callback); - return; - } - - callback.Run(gfx::GpuMemoryBufferHandle()); -} - -// static -void GpuMemoryBufferImpl::DeletedByChildProcess( - gfx::GpuMemoryBufferType type, - gfx::GpuMemoryBufferId id, - base::ProcessHandle child_process, - int child_client_id, - uint32 sync_point) { - switch (type) { - case gfx::SHARED_MEMORY_BUFFER: - break; - case gfx::EFL_PIXMAP_BUFFER: - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - GpuMemoryBufferImplEflPixmap::DeletedByChildProcess( - id, child_client_id, sync_point); -#else - NOTIMPLEMENTED(); -#endif - break; - default: - NOTREACHED(); - break; - } -} - -// static -scoped_ptr GpuMemoryBufferImpl::CreateFromHandle( - const gfx::GpuMemoryBufferHandle& handle, - const gfx::Size& size, - Format format, - const DestructionCallback& callback) { - switch (handle.type) { - case gfx::SHARED_MEMORY_BUFFER: - return GpuMemoryBufferImplSharedMemory::CreateFromHandle( - handle, size, format, callback); - case gfx::EFL_PIXMAP_BUFFER: - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - return GpuMemoryBufferImplEflPixmap::CreateFromHandle( - handle, size, format, callback); -#else - NOTIMPLEMENTED(); - return NULL; -#endif - default: - return scoped_ptr(); - } -} - -} // namespace content diff --git a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.cc b/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.cc deleted file mode 100644 index b4e7faf..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.cc +++ /dev/null @@ -1,202 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h" - -#include "base/atomic_sequence_num.h" -#include "base/bind.h" -#include "base/trace_event/trace_event.h" -#include "base/logging.h" -#include "base/numerics/safe_math.h" -#include "content/common/gpu/client/gpu_memory_buffer_factory_host.h" -#include "ui/gl/efl_pixmap.h" -#include "ui/gl/gl_bindings.h" - -namespace content { -namespace { - -// TODO(prashant.n): Move this to browser side code as per m41. -//base::StaticAtomicSequenceNumber g_next_buffer_id; - - -void GpuMemoryBufferDeleted(gfx::GpuMemoryBufferId id, - int client_id, - uint32 sync_point) { - GpuMemoryBufferFactoryHost::GetInstance()->DestroyGpuMemoryBuffer( - gfx::EFL_PIXMAP_BUFFER, id, client_id, sync_point); -} - - -void GpuMemoryBufferCreated( - const gfx::Size& size, - gfx::GpuMemoryBuffer::Format format, - int client_id, - const GpuMemoryBufferImpl::CreationCallback& callback, - const gfx::GpuMemoryBufferHandle& handle) { - if (handle.is_null()) { - callback.Run(scoped_ptr()); - return; - } - DCHECK_EQ(gfx::EFL_PIXMAP_BUFFER, handle.type); - callback.Run(GpuMemoryBufferImplEflPixmap::CreateFromHandle( - handle, size, format, base::Bind(&GpuMemoryBufferDeleted, handle.id, client_id))); -} - -void GpuMemoryBufferCreatedForChildProcess( - const GpuMemoryBufferImpl::AllocationCallback& callback, - const gfx::GpuMemoryBufferHandle& handle) { - DCHECK_EQ(gfx::EFL_PIXMAP_BUFFER, handle.type); - callback.Run(handle); -} - -} // namespace - -GpuMemoryBufferImplEflPixmap::GpuMemoryBufferImplEflPixmap( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - const DestructionCallback& callback, - scoped_ptr efl_pixmap) - : GpuMemoryBufferImpl(id, size, format, callback), - efl_pixmap_(efl_pixmap.Pass()), - stride_(0u) { -}//Need to check - -GpuMemoryBufferImplEflPixmap::~GpuMemoryBufferImplEflPixmap() { -} - -// static -void GpuMemoryBufferImplEflPixmap::Create( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - int client_id, - const CreationCallback& callback) { - GpuMemoryBufferFactoryHost::GetInstance()->CreateGpuMemoryBuffer( - gfx::EFL_PIXMAP_BUFFER, - id, - size, - format, - MAP, - client_id, - base::Bind(&GpuMemoryBufferCreated, size, format, client_id, callback)); -} - -// static -void GpuMemoryBufferImplEflPixmap::AllocateForChildProcess( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - int child_client_id, - const AllocationCallback& callback) { - GpuMemoryBufferFactoryHost::GetInstance()->CreateGpuMemoryBuffer( - gfx::EFL_PIXMAP_BUFFER, - id, - size, - format, - MAP, - child_client_id, - base::Bind(&GpuMemoryBufferCreatedForChildProcess, callback)); -} -// static -scoped_ptr GpuMemoryBufferImplEflPixmap::CreateFromHandle( - const gfx::GpuMemoryBufferHandle& handle, - const gfx::Size& size, - Format format, - const DestructionCallback& callback) { - DCHECK(IsFormatSupported(format)); - DCHECK(handle.efl_pixmap_id); - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - return make_scoped_ptr(new GpuMemoryBufferImplEflPixmap( - handle.id, size, format, callback,make_scoped_ptr(new gfx::EflPixmapImpl( - gfx::EflPixmapBase::BUFFER, handle.efl_pixmap_id)))); -#else - NOTIMPLEMENTED(); - return NULL; -#endif -} - -void GpuMemoryBufferImplEflPixmap::DeletedByChildProcess( - gfx::GpuMemoryBufferId id, - int child_client_id, - uint32_t sync_point) { - GpuMemoryBufferFactoryHost::GetInstance()->DestroyGpuMemoryBuffer( - gfx::EFL_PIXMAP_BUFFER, id, child_client_id, sync_point); -} - -// static -bool GpuMemoryBufferImplEflPixmap::IsFormatSupported(Format format) { - switch (format) { - case RGBA_8888: - case BGRA_8888: - return true; - case RGBX_8888: - return false; - } - - NOTREACHED(); - return false; -} - -// static -bool GpuMemoryBufferImplEflPixmap::IsUsageSupported(Usage usage) { - switch (usage) { - case MAP: - return true; - case SCANOUT: - return false; - } - - NOTREACHED(); - return false; -} - -// static -bool GpuMemoryBufferImplEflPixmap::IsLayoutSupported(const gfx::Size& size, - Format format) { - if (!IsFormatSupported(format)) - return false; - - return true; -} - -// static -bool GpuMemoryBufferImplEflPixmap::IsConfigurationSupported(Format format, - Usage usage) { - return IsFormatSupported(format) && IsUsageSupported(usage); -} - -void* GpuMemoryBufferImplEflPixmap::Map() { - TRACE_EVENT0("gpu", "GpuMemoryBufferImplEflPixmap::Map"); - DCHECK(efl_pixmap_); - DCHECK(!mapped_); - mapped_ = true; - void* buffer = efl_pixmap_->Map(); - stride_ = efl_pixmap_->GetStride(); - - return buffer; -} - -void GpuMemoryBufferImplEflPixmap::Unmap() { - TRACE_EVENT0("gpu", "GpuMemoryBufferImplEflPixmap::Unmap"); - DCHECK(efl_pixmap_); - DCHECK(mapped_); - efl_pixmap_->UnMap(); - mapped_ = false; -} - -uint32 GpuMemoryBufferImplEflPixmap::GetStride() const { - return stride_; -} - -gfx::GpuMemoryBufferHandle GpuMemoryBufferImplEflPixmap::GetHandle() const { - gfx::GpuMemoryBufferHandle handle; - handle.type = gfx::EFL_PIXMAP_BUFFER; - handle.id = id_; - handle.efl_pixmap_id = efl_pixmap_->GetId(); - return handle; -} - -} // namespace content diff --git a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h b/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h deleted file mode 100644 index 26afa55..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap.h +++ /dev/null @@ -1,69 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_EFL_PIXMAP_H_ -#define CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_EFL_PIXMAP_H_ - -#include "content/common/gpu/client/gpu_memory_buffer_impl.h" - -namespace gfx { -class EflPixmapImpl; -} - -namespace content { - -// Implementation of GPU memory buffer based on efl pixmap. -class GpuMemoryBufferImplEflPixmap : public GpuMemoryBufferImpl { - public: - static void Create(gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - int client_id, - const CreationCallback& callback); - - static void AllocateForChildProcess(gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - int child_client_id, - const AllocationCallback& callback); - - static scoped_ptr CreateFromHandle( - const gfx::GpuMemoryBufferHandle& handle, - const gfx::Size& size, - Format format, - const DestructionCallback& callback); - - static void DeletedByChildProcess(gfx::GpuMemoryBufferId id, - int child_client_id, - uint32_t sync_point); - - static bool IsFormatSupported(Format format); - static bool IsUsageSupported(Usage usage); - static bool IsLayoutSupported(const gfx::Size& size, Format format); - static bool IsConfigurationSupported(Format format, Usage usage); - - // Overridden from gfx::GpuMemoryBuffer: - virtual void* Map() override; - virtual void Unmap() override; - virtual uint32 GetStride() const override; - virtual gfx::GpuMemoryBufferHandle GetHandle() const override; - - private: - GpuMemoryBufferImplEflPixmap(gfx::GpuMemoryBufferId id, - const gfx::Size& size, - Format format, - const DestructionCallback& callback, - scoped_ptr efl_pixmap); - virtual ~GpuMemoryBufferImplEflPixmap(); - - gfx::GpuMemoryBufferId id_; - scoped_ptr efl_pixmap_; - size_t stride_; - - DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImplEflPixmap); -}; - -} // namespace content - -#endif // CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_EFL_PIXMAP_H_ diff --git a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl.cc b/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl.cc deleted file mode 100644 index 6ea39ed..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl.cc +++ /dev/null @@ -1,112 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "content/common/gpu/gpu_memory_buffer_factory.h" - -#include "base/logging.h" -#include "content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h" -#include "gpu/command_buffer/service/image_factory.h" -#include "ui/gl/gl_image.h" -#include "ui/gl/gl_image_efl_pixmap.h" -#include "ui/gl/gl_image_shared_memory.h" - -namespace content { -namespace { - -class GpuMemoryBufferFactoryImpl: - public GpuMemoryBufferFactory , - public gpu::ImageFactory { - public: - // Overridden from GpuMemoryBufferFactory: - virtual gfx::GpuMemoryBufferHandle CreateGpuMemoryBuffer( - gfx::GpuMemoryBufferType type, - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - gfx::GpuMemoryBuffer::Format format, - gfx::GpuMemoryBuffer::Usage usage, - int client_id) override { - switch (type) { - case gfx::EFL_PIXMAP_BUFFER: { - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - return efl_pixmap_factory_.CreateGpuMemoryBuffer( - id, size, format,client_id); -#else - NOTIMPLEMENTED(); - return NULL; -#endif - } - default: - NOTREACHED(); - return gfx::GpuMemoryBufferHandle(); - } - } - virtual void DestroyGpuMemoryBuffer( - gfx::GpuMemoryBufferType type, - gfx::GpuMemoryBufferId id, - int client_id) override { - switch (type) { - case gfx::EFL_PIXMAP_BUFFER: - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - efl_pixmap_factory_.DestroyGpuMemoryBuffer(id, client_id); -#else - NOTIMPLEMENTED(); -#endif - break; - default: - NOTREACHED(); - break; - } - } - - virtual gpu::ImageFactory* AsImageFactory() override { return this; } - virtual scoped_refptr CreateImageForGpuMemoryBuffer( - const gfx::GpuMemoryBufferHandle& handle, - const gfx::Size& size, - gfx::GpuMemoryBuffer::Format format, - unsigned internalformat, - int client_id) override { - switch (handle.type) { - case gfx::SHARED_MEMORY_BUFFER: { - scoped_refptr image( - new gfx::GLImageSharedMemory(size, internalformat)); - if (!image->Initialize(handle, format)) - return NULL; - - return image; - } - case gfx::EFL_PIXMAP_BUFFER: { - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - return efl_pixmap_factory_.CreateImageForGpuMemoryBuffer( - handle.efl_pixmap_id, size, internalformat,client_id); -#else - NOTIMPLEMENTED(); - return NULL; -#endif - } - default: - NOTREACHED(); - return scoped_refptr(); - } - } - -#if !defined(WAYLAND_BRINGUP) - private: - // TODO: Rendering TG will implement following for Wayland. - GpuMemoryBufferFactoryEflPixmap efl_pixmap_factory_; -#endif -}; - -} // namespace - -// static -scoped_ptr GpuMemoryBufferFactory::Create() { - return make_scoped_ptr( - new GpuMemoryBufferFactoryImpl); -} - - -} // namespace content diff --git a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.cc b/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.cc deleted file mode 100644 index 8eafbfe..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.cc +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h" - -#include "ui/gl/efl_pixmap.h" -#include "ui/gl/gl_image_efl_pixmap.h" - -namespace content { - -GpuMemoryBufferFactoryEflPixmap::GpuMemoryBufferFactoryEflPixmap() { -} - -GpuMemoryBufferFactoryEflPixmap::~GpuMemoryBufferFactoryEflPixmap() { -} - -gfx::GpuMemoryBufferHandle -GpuMemoryBufferFactoryEflPixmap::CreateGpuMemoryBuffer( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - unsigned internalformat, - int client_id) { - scoped_refptr efl_pixmap = - gfx::EflPixmap::Create(gfx::EflPixmap::BUFFER, size); - if (!efl_pixmap.get()) - return gfx::GpuMemoryBufferHandle(); - - EflPixmapMapKey key(id, client_id); - DCHECK(efl_pixmaps_.find(key) == efl_pixmaps_.end()); - efl_pixmaps_[key] = efl_pixmap; - - gfx::GpuMemoryBufferHandle handle; - handle.type = gfx::EFL_PIXMAP_BUFFER; - handle.id = id; - handle.efl_pixmap_id = efl_pixmap->GetId(); - return handle; -} - -void GpuMemoryBufferFactoryEflPixmap::DestroyGpuMemoryBuffer( - gfx::GpuMemoryBufferId id,int client_id) { - EflPixmapMapKey key(id, client_id); - EflPixmapMap::iterator it = efl_pixmaps_.find(key); - if (it != efl_pixmaps_.end()) - efl_pixmaps_.erase(it); -} - -scoped_refptr -GpuMemoryBufferFactoryEflPixmap::CreateImageForGpuMemoryBuffer( - unsigned long frame_pixmap_id, - const gfx::Size& size, - unsigned internalformat, - int client_id ) { - scoped_refptr image(new gfx::GLImageEflPixmap(size)); - if (!image->Initialize(frame_pixmap_id)) - return scoped_refptr(); - - return image; -} - -} // namespace content diff --git a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h b/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h deleted file mode 100644 index 43545e10..0000000 --- a/tizen_src/chromium_impl/content/common/gpu/gpu_memory_buffer_factory_efl_pixmap.h +++ /dev/null @@ -1,52 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CONTENT_COMMON_GPU_GPU_MEMORY_BUFFER_FACTORY_EFL_PIXMAP_H_ -#define CONTENT_COMMON_GPU_GPU_MEMORY_BUFFER_FACTORY_EFL_PIXMAP_H_ - -#include "base/containers/hash_tables.h" -#include "base/memory/ref_counted.h" -#include "ui/gfx/geometry/size.h" -#include "ui/gfx/gpu_memory_buffer.h" - -namespace gfx { -class GLImage; -class EflPixmap; -} - -namespace content { - -class GpuMemoryBufferFactoryEflPixmap { - public: - GpuMemoryBufferFactoryEflPixmap(); - ~GpuMemoryBufferFactoryEflPixmap(); - - // Creates a efl pixmap backed GPU memory buffer with |size| and - // |internalformat|. A valid handle is returned on success. - gfx::GpuMemoryBufferHandle CreateGpuMemoryBuffer( - gfx::GpuMemoryBufferId id, - const gfx::Size& size, - unsigned internalformat, - int client_id); - - // Destroy a previously created GPU memory buffer. - void DestroyGpuMemoryBuffer(const gfx::GpuMemoryBufferId id,int client_id); - - // Creates a GLImage instance for a GPU memory buffer. - scoped_refptr CreateImageForGpuMemoryBuffer( - unsigned long frame_pixmap_id, - const gfx::Size& size, - unsigned internalformat, - int client_id); - - private: - typedef std::pair EflPixmapMapKey; - typedef base::hash_map> EflPixmapMap; - EflPixmapMap efl_pixmaps_; -}; - -} // namespace content - -#endif // CONTENT_COMMON_GPU_GPU_MEMORY_BUFFER_FACTORY_EFL_PIXMAP_H_ diff --git a/tizen_src/chromium_impl/ui/gl/efl_pixmap.cc b/tizen_src/chromium_impl/ui/gl/efl_pixmap.cc deleted file mode 100644 index 458f0d6..0000000 --- a/tizen_src/chromium_impl/ui/gl/efl_pixmap.cc +++ /dev/null @@ -1,578 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - - -extern "C" { -#include -#include -#include -#include -#include -#include -#include -#include -#include -} - -#include "ui/gl/efl_pixmap.h" -#include "base/containers/scoped_ptr_hash_map.h" -#include "base/logging.h" -#include "ui/gl/egl_util.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -namespace gl { - -// Helper classes implementation. -class NativeDisplayConnection { - public: - NativeDisplayConnection() { - display_ = XOpenDisplay(0); - if (!display_) { - LOG(ERROR) << "Failed to make connection with X"; - exit(0); - } - } - - ~NativeDisplayConnection() { XCloseDisplay(display_); } - - Display* GetDisplay() { return display_; } - - private: - Display* display_; -}; - -class EGLDisplayConnection { - public: - EGLDisplayConnection(Display* native_display) { - if (native_display) { - egl_display_ = - eglGetDisplay(reinterpret_cast(native_display)); - } else { - LOG(ERROR) << "EGLDisplayConnection failed - Invalid native display."; - return; - } - - if (egl_display_ == EGL_NO_DISPLAY) { - LOG(ERROR) << "EGLDisplayConnection failed - " - << ui::GetLastEGLErrorString(); - return; - } - - EGLint major, minor; - if (eglInitialize(egl_display_, &major, &minor) != EGL_TRUE) { - Terminate(); - LOG(ERROR) << "EGLDisplayConnection failed - " - << ui::GetLastEGLErrorString(); - } - } - - ~EGLDisplayConnection() { Terminate(); } - - EGLDisplay GetDisplay() { return egl_display_; } - - private: - void Terminate() { - if (egl_display_ == EGL_NO_DISPLAY) - return; - - eglTerminate(egl_display_); - egl_display_ = EGL_NO_DISPLAY; - } - - EGLDisplay egl_display_; -}; - -class OffScreenRootWindow { - public: - OffScreenRootWindow(Display* native_display) { - window_ = 0; - - if (!native_display) { - LOG(ERROR) << "OffScreenRootWindow failed - Invalid native display."; - return; - } - - native_display_ = native_display; - XSetWindowAttributes attributes; - attributes.override_redirect = true; - window_ = XCreateSimpleWindow( - native_display, XDefaultRootWindow(native_display), -1, -1, 1, 1, 0, - BlackPixel(native_display, 0), WhitePixel(native_display, 0)); - XChangeWindowAttributes(native_display, window_, CWOverrideRedirect, - &attributes); - XMapWindow(native_display, window_); - - if (!window_) - LOG(ERROR) << "OffScreenRootWindow failed to create window."; - } - - ~OffScreenRootWindow() { - if (!native_display_) - return; - - if (window_) { - XUnmapWindow(native_display_, window_); - XDestroyWindow(native_display_, window_); - window_ = 0; - } - } - - Window GetRootWindow() { return window_; } - - private: - Window window_; - Display* native_display_; -}; - -Window GetOffscreenRootWindow() { - static OffScreenRootWindow offscreen_root_window( - EflPixmap::GetNativeDisplay()); - return offscreen_root_window.GetRootWindow(); -} - -// Tizen buffer implementation. -struct TbmInfo { - int fd; - tbm_bufmgr bufmgr; - - TbmInfo() : fd(-1), bufmgr(0) {} -}; - -TbmInfo g_tbm_info; - -class NativeBufferManager { - public: - static void AddRef() { - ++s_ref; - - if (s_native_buffer_manager == NULL) - s_native_buffer_manager = new NativeBufferManager; - } - - static void RemoveRef() { - DCHECK(s_ref > 0); - --s_ref; - - if (s_ref == 0) { - delete s_native_buffer_manager; - s_native_buffer_manager = NULL; - } - } - - private: - NativeBufferManager() { Initialize(); } - ~NativeBufferManager() { Finalize(); } - - bool Initialize() { - int event_base = 0; - int error_base = 0; - int dri2_major = 0; - int dri2_minor = 0; - char* driver_name = 0; - char* device_name = 0; - drm_magic_t magic = 0; - int fd = -1; - - Display* dpy = EflPixmap::GetNativeDisplay(); - int screen = XDefaultScreen(dpy); - if (!DRI2QueryExtension(dpy, &event_base, &error_base)) { - LOG(ERROR) << "'DRI2QueryExtension' failed to get dri2 extension."; - goto error; - } - - if (!DRI2QueryVersion(dpy, &dri2_major, &dri2_minor)) { - LOG(ERROR) << "'DRI2QueryVersion' failed to get dri2 version."; - goto error; - } - - if (!DRI2Connect(dpy, RootWindow(dpy, screen), &driver_name, - &device_name)) { - LOG(ERROR) << "'DRI2Connect' failed to get dri2 connect."; - goto error; - } - - fd = open(device_name, O_RDWR); - if (fd < 0) { - LOG(ERROR) << "'DRM] couldn't open : "; - goto error; - } - - if (drmGetMagic(fd, &magic)) { - LOG(ERROR) << "'drmGetMagic' failed to get magic."; - goto error; - } - - if (!DRI2Authenticate(dpy, RootWindow(dpy, screen), (unsigned int)magic)) { - LOG(ERROR) << "'DRI2Authenticate' failed to get authentication."; - goto error; - } - - g_tbm_info.fd = fd; - - setenv("BUFMGR_LOCK_TYPE", "always", 1); - setenv("BUFMGR_MAP_CACHE", "true", 1); - g_tbm_info.bufmgr = tbm_bufmgr_init(fd); - - free(driver_name); - free(device_name); - return true; - - error: - free(driver_name); - free(device_name); - if (fd > -1) - close(fd); - return false; - } - - void Finalize() { - if (g_tbm_info.bufmgr) - tbm_bufmgr_deinit(g_tbm_info.bufmgr); - - if (g_tbm_info.fd > -1) { - close(g_tbm_info.fd); - g_tbm_info.fd = -1; - } - } - - static int s_ref; - static NativeBufferManager* s_native_buffer_manager; -}; - -int NativeBufferManager::s_ref = 0; -NativeBufferManager* NativeBufferManager::s_native_buffer_manager = NULL; - -class NativeBuffer { - public: - NativeBuffer(); - ~NativeBuffer(); - - void CreateDrawable(unsigned long pixmap_id); - void DestroyDrawable(unsigned long pixmap_id); - void* Lock(unsigned long pixmap_id, int count); - bool Unlock(); - int GetStride(unsigned long pixmap_id); - - private: - int pixmap_; - DRI2Buffer* buffer_; - tbm_bo buffer_object_; -}; - -NativeBuffer::NativeBuffer() : buffer_(NULL), - buffer_object_(NULL) { - NativeBufferManager::AddRef(); -} - -NativeBuffer::~NativeBuffer() { - if (buffer_) { - XFree(buffer_); - buffer_ = NULL; - } - - NativeBufferManager::RemoveRef(); -} - -void NativeBuffer::CreateDrawable(unsigned long pixmap_id) { - DRI2CreateDrawable(EflPixmap::GetNativeDisplay(), pixmap_id); -} - -void NativeBuffer::DestroyDrawable(unsigned long pixmap_id) { - DRI2DestroyDrawable(EflPixmap::GetNativeDisplay(), pixmap_id); -} - -void* NativeBuffer::Lock(unsigned long pixmap_id, int count) { - tbm_bo_handle handle; - unsigned int attach = DRI2BufferFrontLeft; - int num = -1, width = 0, height = 0; - - DCHECK(pixmap_id); - - if (!buffer_) { - DRI2Buffer* buffer = DRI2GetBuffers(EflPixmap::GetNativeDisplay(), - pixmap_id, - &width, - &height, - &attach, - 1, - &num); - if (!buffer || !buffer->name) { - LOG(ERROR) << "'DRI2GetBuffers' failed to get dri2 buffers count :" - << count << "buf :" << buffer << "buf->name" << buffer->name; - XFree(buffer); - return NULL; - } - - buffer_ = buffer; - } - - if (!buffer_object_) { - buffer_object_ = tbm_bo_import(g_tbm_info.bufmgr, buffer_->name); - if (!buffer_object_) { - LOG(ERROR) << "'tbm_bo_import' failed to import buffer"; - return NULL; - } - } - - handle = tbm_bo_map(buffer_object_, - TBM_DEVICE_CPU, - TBM_OPTION_READ | TBM_OPTION_WRITE); - - if (!handle.ptr) { - LOG(ERROR) << "'tbm_bo_map' failed to map tbm buffer for GPU"; - return NULL; - } - - return handle.ptr; -} - -bool NativeBuffer::Unlock() { - if (!buffer_object_) - return false; - - tbm_bo_unmap(buffer_object_); - tbm_bo_unref(buffer_object_); - buffer_object_ = NULL; - return true; -} - -int NativeBuffer::GetStride(unsigned long pixmap_id) { - DCHECK(buffer_); - return buffer_->pitch; -} - -// EflPixmapBase implemetation. -int EflPixmapBase::s_pixmap_surface_count = 0; - -EflPixmapBase::EflPixmapBase(UsageType usage_type) - : usage_type_(usage_type), - pixmap_id_(0), - native_buffer_(NULL) { - native_buffer_ = new NativeBuffer; -} - -EflPixmapBase::~EflPixmapBase() { - DCHECK(native_buffer_); - delete native_buffer_; - native_buffer_ = NULL; - pixmap_id_ = 0; -} - -void* EflPixmapBase::Map() { - DCHECK(usage_type_ == BUFFER); - return native_buffer_->Lock(pixmap_id_, - EflPixmapBase::s_pixmap_surface_count); -} - -bool EflPixmapBase::UnMap() { - DCHECK(usage_type_ == BUFFER); - return native_buffer_->Unlock(); -} - -int EflPixmapBase::GetStride() { - DCHECK(usage_type_ == BUFFER); - return native_buffer_->GetStride(pixmap_id_); -} - - -// EflPixmap implemetation. -// static -scoped_refptr EflPixmap::Create(UsageType usage_type, - const gfx::Size& size) { - EflPixmap* efl_pixmap = new EflPixmap(usage_type, size); - - if (!efl_pixmap->Initialize()) { - LOG(ERROR) << "EflPixmap creation failed."; - - delete efl_pixmap; - efl_pixmap = NULL; - } - - return make_scoped_refptr(efl_pixmap); -} - -EflPixmap::EflPixmap(UsageType usage_type, const gfx::Size& size) - : EflPixmapBase(usage_type), - size_(size), - surface_(EGL_NO_SURFACE), - used_(false) { - EflPixmapBase::s_pixmap_surface_count++; -} - -EflPixmap::~EflPixmap() { - DCHECK(GetDisplay()); - - if (surface_ != EGL_NO_SURFACE) { - DestroySurface(surface_); - surface_ = EGL_NO_SURFACE; - } - - if (pixmap_id_) { - native_buffer_->DestroyDrawable(pixmap_id_); - FreePixmap(pixmap_id_); - pixmap_id_ = 0; - } - - delete native_buffer_; - native_buffer_ = NULL; - - EflPixmapBase::s_pixmap_surface_count--; -} - -// static -const char* EflPixmap::GetEglExtensions() { - return eglQueryString(GetNativeDisplay(), EGL_EXTENSIONS); -} - -// static -Display* EflPixmap::GetNativeDisplay() { - static NativeDisplayConnection native_display_connection; - return native_display_connection.GetDisplay(); -} - -// static -EGLDisplay EflPixmap::GetDisplay() { - static EGLDisplayConnection egl_display_connection(GetNativeDisplay()); - return egl_display_connection.GetDisplay(); -} - -// static -EGLConfig EflPixmap::GetConfig() { - static EGLConfig config = EflPixmap::ChooseConfig(); - return config; -} - -bool EflPixmap::Initialize() { - if (size_.IsEmpty() || !GetDisplay() || !GetConfig()) - return false; - - pixmap_id_ = CreatePixmap(size_); - if (!pixmap_id_) - return false; - - native_buffer_->CreateDrawable(pixmap_id_); - - if (usage_type_ == SURFACE) { - surface_ = CreateSurface(pixmap_id_); - - if (surface_ == EGL_NO_SURFACE) - return false; - } - - XSync(GetNativeDisplay(), false); - - return true; -} - -// static -EGLConfig EflPixmap::ChooseConfig() { - EGLint config_attributes_list[] = { - EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT, - EGL_SURFACE_TYPE, EGL_WINDOW_BIT | EGL_PBUFFER_BIT | EGL_PIXMAP_BIT, - EGL_RED_SIZE, 8, - EGL_GREEN_SIZE, 8, - EGL_BLUE_SIZE, 8, - EGL_ALPHA_SIZE, 8, - EGL_DEPTH_SIZE, 24, - EGL_STENCIL_SIZE, 8, - EGL_SAMPLES, 2, - EGL_NONE - }; - - EGLConfig config = NULL; - EGLint config_count = 0; - if ((eglChooseConfig(GetDisplay(), - config_attributes_list, - &config, - 1, - &config_count) != EGL_TRUE) && config_count) { - LOG(ERROR) << "eglChooseConfig failed - " << ui::GetLastEGLErrorString(); - return NULL; - } - - return config; -} - -EGLSurface EflPixmap::CreateSurface(unsigned long pixmap_id) { - DCHECK(GetDisplay()); - DCHECK(GetConfig()); - DCHECK(pixmap_id); - - EGLSurface surface = - eglCreatePixmapSurface(GetDisplay(), GetConfig(), pixmap_id, 0); - - if (surface == EGL_NO_SURFACE) { - LOG(ERROR) << "eglCreatePixmapSurface failed - " - << ui::GetLastEGLErrorString(); - } else { - eglSurfaceAttrib(GetDisplay(), - surface, - EGL_SWAP_BEHAVIOR, - EGL_BUFFER_PRESERVED); - } - - return surface; -} - -void EflPixmap::DestroySurface(EGLSurface surface) { - DCHECK(GetDisplay()); - DCHECK(surface); - - if (eglMakeCurrent(GetDisplay(), - EGL_NO_SURFACE, - EGL_NO_SURFACE, - EGL_NO_CONTEXT) != EGL_TRUE) { - LOG(ERROR) << "eglMakeCurrent failed - " << ui::GetLastEGLErrorString(); - } - - eglDestroySurface(GetDisplay(), surface); -} - -unsigned long EflPixmap::CreatePixmap(const gfx::Size& size) { - DCHECK(!size.IsEmpty()); - - // FIXME(prashant.n): Get depth (value 24) from xvisuals or geometry. - unsigned long pixmap_id = XCreatePixmap(GetNativeDisplay(), - GetOffscreenRootWindow(), - size.width(), - size.height(), - 24); - XFlush(GetNativeDisplay()); - return pixmap_id; -} - -void EflPixmap::FreePixmap(unsigned long pixmap_id) { - DCHECK(pixmap_id); - XFreePixmap(GetNativeDisplay(), pixmap_id); -} - -// EflPixmapImpl implementation. -EflPixmapImpl::EflPixmapImpl(UsageType usage_type, unsigned long pixmap_id) - : EflPixmapBase(usage_type) { - DCHECK(usage_type_ == BUFFER); - DCHECK(pixmap_id); - pixmap_id_ = pixmap_id; - native_buffer_->CreateDrawable(pixmap_id_); -} - -EflPixmapImpl::~EflPixmapImpl() { - native_buffer_->DestroyDrawable(pixmap_id_); - pixmap_id_ = 0; - -} - -} // namespace gl diff --git a/tizen_src/chromium_impl/ui/gl/efl_pixmap.h b/tizen_src/chromium_impl/ui/gl/efl_pixmap.h deleted file mode 100644 index 9871098..0000000 --- a/tizen_src/chromium_impl/ui/gl/efl_pixmap.h +++ /dev/null @@ -1,109 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef UI_GL_EFL_PIXMAP_H_ -#define UI_GL_EFL_PIXMAP_H_ - -#include "base/containers/hash_tables.h" -#include "base/memory/ref_counted.h" -#include "ui/gfx/geometry/size.h" -#include "ui/gl/gl_bindings.h" - -#if !defined(WAYLAND_BRINGUP) -#include -#endif - -namespace gl { - -class NativeBuffer; - -// TODO(prashant.n): Refactor the code into different files. -// Basic Pixmap implementation. -class GL_EXPORT EflPixmapBase { - public: - enum UsageType { - BUFFER, - SURFACE - }; - - virtual unsigned long GetId() { return pixmap_id_; } - - virtual void* Map(); - virtual bool UnMap(); - virtual int GetStride(); - - protected: - EflPixmapBase(UsageType usage_type); - virtual ~EflPixmapBase(); - - UsageType usage_type_; - unsigned long pixmap_id_; - NativeBuffer* native_buffer_; - - static int s_pixmap_surface_count; -}; - -// Pixmap implementation - to be used in GPU process/thread. -class GL_EXPORT EflPixmap : public EflPixmapBase, - public base::RefCountedThreadSafe { - public: - static scoped_refptr Create(UsageType usage_type, - const gfx::Size& size); - virtual ~EflPixmap(); - - static const char* GetEglExtensions(); - // TODO: Rendering TG will implement following for Wayland. -#if !defined(WAYLAND_BRINGUP) - static Display* GetNativeDisplay(); -#endif - static EGLDisplay GetDisplay(); - static EGLConfig GetConfig(); - - const gfx::Size GetSize() const { return size_; } - bool Used() { return used_; } - void SetUsed(bool used) { used_ = used; } - EGLSurface GetSurface() { return surface_; } - - // EflPixmapBase functions: - using EflPixmapBase::GetId; - using EflPixmapBase::Map; - using EflPixmapBase::UnMap; - using EflPixmapBase::GetStride; - - private: - EflPixmap(UsageType usage_type, const gfx::Size& size); - bool Initialize(); - static EGLConfig ChooseConfig(); - - EGLSurface CreateSurface(unsigned long pixmap_id); - void DestroySurface(EGLSurface surface); - unsigned long CreatePixmap(const gfx::Size& size); - void FreePixmap(unsigned long pixmap_id); - - gfx::Size size_; - EGLSurface surface_; - bool used_; - - DISALLOW_COPY_AND_ASSIGN(EflPixmap); -}; - -// Pixmap implementation - to be used in renderer and browser processes. -class GL_EXPORT EflPixmapImpl : public EflPixmapBase { - public: - explicit EflPixmapImpl(UsageType usage_type, unsigned long pixmap_id); - ~EflPixmapImpl(); - - // EflPixmapBase functions: - using EflPixmapBase::GetId; - using EflPixmapBase::Map; - using EflPixmapBase::UnMap; - using EflPixmapBase::GetStride; - - private: - DISALLOW_COPY_AND_ASSIGN(EflPixmapImpl); -}; - -} // namespace gl - -#endif // UI_GL_EFL_PIXMAP_H_ diff --git a/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.cc b/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.cc deleted file mode 100644 index 1b700a6..0000000 --- a/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.cc +++ /dev/null @@ -1,144 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "ui/gl/gl_image_efl_pixmap.h" - -#include "base/trace_event/trace_event.h" -#include "base/process/process_handle.h" -#include "ui/gl/efl_pixmap.h" -#include "ui/gl/egl_util.h" - -namespace { - -PFNEGLCREATEIMAGEKHRPROC eglCreateImageKHRPfn = 0; -PFNGLEGLIMAGETARGETTEXTURE2DOESPROC glEGLImageTargetTexture2DOESPfn = 0; -PFNEGLDESTROYIMAGEKHRPROC eglDestroyImageKHRPfn = 0; - -EGLDisplay g_display = NULL; - -void EnsureGLImageFunctions() { - if (!g_display) { - g_display = eglGetCurrentDisplay(); - eglCreateImageKHRPfn = - (PFNEGLCREATEIMAGEKHRPROC)eglGetProcAddress("eglCreateImageKHR"); - glEGLImageTargetTexture2DOESPfn = - (PFNGLEGLIMAGETARGETTEXTURE2DOESPROC)eglGetProcAddress( - "glEGLImageTargetTexture2DOES"); - eglDestroyImageKHRPfn = - (PFNEGLDESTROYIMAGEKHRPROC)eglGetProcAddress("eglDestroyImageKHR"); - } -} - -} // namespace - -namespace gl { - -GLImageEflPixmap::GLImageEflPixmap(gfx::Size size) - : size_(size), - in_use_(false), - egl_image_(EGL_NO_IMAGE_KHR), - target_(0) { -} - -GLImageEflPixmap::~GLImageEflPixmap() { -} - -bool GLImageEflPixmap::Initialize(unsigned long efl_pixmap_id) { - EnsureGLImageFunctions(); - efl_pixmap_id_ = efl_pixmap_id; - egl_image_ = eglCreateImageKHRPfn(g_display, EGL_NO_CONTEXT, - EGL_NATIVE_PIXMAP_KHR, - (EGLClientBuffer)(efl_pixmap_id_), - NULL); - - if (egl_image_ == EGL_NO_IMAGE_KHR) - LOG(ERROR) << "eglCreateImageKHR failed - " << ui::GetLastEGLErrorString(); - - return true; -} - -#if !defined(EWK_BRINGUP) -void GLImageEflPixmap::Destroy(bool have_context) { - if (egl_image_ == EGL_NO_IMAGE_KHR) - return; - - EGLBoolean success = eglDestroyImageKHRPfn(g_display, egl_image_); - - if (success == EGL_FALSE) - LOG(ERROR) << "eglDestroyImageKHR failed - " << ui::GetLastEGLErrorString(); - - efl_pixmap_id_ = 0; - egl_image_ = EGL_NO_IMAGE_KHR; -} - -gfx::Size GLImageEflPixmap::GetSize() { - return size_; -} -#endif - -unsigned GLImageEflPixmap::GetInternalFormat() { - // FIXME: Check this for pixmap. - return -1; -} - -bool GLImageEflPixmap::BindTexImage(unsigned target) { - TRACE_EVENT0("gpu", "GLImageEflPixmap::BindTexImage"); - - if (egl_image_ == EGL_NO_IMAGE_KHR) { - LOG(ERROR) << "NULL EGLImage - " << ui::GetLastEGLErrorString(); - return false; - } - - if (target_ && target_ != target) { - LOG(ERROR) << "EGLImage can only be bound to one target"; - return false; - } - target_ = target; - - if (in_use_) - return true; - - glEGLImageTargetTexture2DOESPfn(target_, (EGLClientBuffer)egl_image_); - EGLint error = eglGetError(); - if (error != EGL_SUCCESS) { - LOG(ERROR) << "glEGLImageTargetTexture2DOES failed - " - << ui::GetLastEGLErrorString(); - } - - DCHECK_EQ(static_cast(GL_NO_ERROR), glGetError()); - in_use_ = true; - return true; -} - -void GLImageEflPixmap::ReleaseTexImage(unsigned target) {} - -bool GLImageEflPixmap::CopyTexImage(unsigned target) { - return false; -} - -bool GLImageEflPixmap::CopyTexSubImage(unsigned target, - const gfx::Point& offset, - const gfx::Rect& rect) { - return false; -} - -bool GLImageEflPixmap::ScheduleOverlayPlane(gfx::AcceleratedWidget widget, - int z_order, - gfx::OverlayTransform transform, - const gfx::Rect& bounds_rect, - const gfx::RectF& crop_rect) { - return false; -} - -void GLImageEflPixmap::Flush() {} - -void GLImageEflPixmap::OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, - uint64_t process_tracing_id, - const std::string& dump_name) {} - -GLImage::Type GLImageEflPixmap::GetType() const { - return Type::DXGI_IMAGE; -} - -} // namespace gl diff --git a/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.h b/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.h deleted file mode 100644 index cfc9eb7..0000000 --- a/tizen_src/chromium_impl/ui/gl/gl_image_efl_pixmap.h +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef UI_GL_GL_IMAGE_EFL_PIXMAP_H_ -#define UI_GL_GL_IMAGE_EFL_PIXMAP_H_ - -#include "ui/gl/gl_image.h" -#include "ui/gfx/gpu_memory_buffer.h" -#include "ui/gl/gl_bindings.h" - - -namespace gl { - -class GL_EXPORT GLImageEflPixmap : public GLImage { - public: - GLImageEflPixmap(gfx::Size size); - - bool Initialize(unsigned long efl_pixmap_id); - - // Overridden from GLImage: -#if !defined(EWK_BRINGUP) - // This API is removed. Just keeping for reference. - void Destroy(bool have_context) override; -#endif - gfx::Size GetSize() override; - unsigned GetInternalFormat() override; - bool BindTexImage(unsigned target) override; - void ReleaseTexImage(unsigned target) override; - bool CopyTexImage(unsigned target) override; - bool CopyTexSubImage(unsigned target, - const gfx::Point& offset, - const gfx::Rect& rect) override; - bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget, - int z_order, - gfx::OverlayTransform transform, - const gfx::Rect& bounds_rect, - const gfx::RectF& crop_rect) override; - void Flush() override; - void OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, - uint64_t process_tracing_id, - const std::string& dump_name) override; - Type GetType() const override; - - protected: - ~GLImageEflPixmap(); - - private: - unsigned long efl_pixmap_id_; - const gfx::Size size_; - bool in_use_; - EGLImageKHR egl_image_; - unsigned target_; - - DISALLOW_COPY_AND_ASSIGN(GLImageEflPixmap); -}; - -} // namespace gl - -#endif // UI_GL_GL_IMAGE_EFL_PIXMAP_H_ -- 2.7.4 From 8f59cc973260daddd8446cc3a983cab338994c28 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Thu, 26 Dec 2019 11:37:21 +0530 Subject: [PATCH 04/16] [M76 Migration] Set default DIP scale as 1.0 DIP scale value can not be 0 and if this value is used before initialization from |RWHVEfl::InitializeDeviceDisplayInfo|, it causes layout error. Reference: https://review.tizen.org/gerrit/#/c//202076/ Change-Id: I62d2f79542470fb3e3fdde8a542c61f5fd992e29 Signed-off-by: Chandan Padhi (cherry picked from commit 6ce2eead7fe78dfab9ced4a4673ccbd5436dd7e8) (cherry picked from commit 391156033f20840a83b5f999cb9f89b850a725f9) --- tizen_src/chromium_impl/ui/display/device_display_info_efl.cc | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc b/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc index 8d522c0..22846cf 100644 --- a/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc +++ b/tizen_src/chromium_impl/ui/display/device_display_info_efl.cc @@ -139,11 +139,10 @@ int DeviceDisplayInfoEflImpl::GetRotationDegrees() const { } DeviceDisplayInfoEflImpl::DeviceDisplayInfoEflImpl() - : display_width_(0), - display_height_(0), - dip_scale_(0), - rotation_degrees_(kInvalidRotationDegrees) { -} + : display_width_(0), + display_height_(0), + dip_scale_(1.0), + rotation_degrees_(kInvalidRotationDegrees) {} // DeviceDisplayInfoEfl DeviceDisplayInfoEfl::DeviceDisplayInfoEfl() { -- 2.7.4 From 208c8c81d394b5adcd613f2d9c3ca7da96220f51 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Thu, 26 Dec 2019 11:47:58 +0530 Subject: [PATCH 05/16] [M76 Migration] Fix crash during destruction of EvasGLDelegatedFrameHost This change ensures that EvasGLDelegatedFrameHost member variables are accessed only when its initialization is done. Reference: https://review.tizen.org/gerrit/#/c/201648/ Change-Id: Ie0ab831f019ecb8584132254b73569b160bc9152 Signed-off-by: Chandan Padhi (cherry picked from commit ed4706b13d59527e90b03c0090570d456acbab1b) (cherry picked from commit ab3f131e756c49e0e8afc4fbf1cd0e4ad2e46204) --- .../content/browser/compositor/evasgl_delegated_frame_host.cc | 11 ++++++++++- .../content/browser/compositor/evasgl_delegated_frame_host.h | 1 + 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc index d48539a..c477f64 100644 --- a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc +++ b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc @@ -15,9 +15,11 @@ namespace content { EvasGLDelegatedFrameHost::EvasGLDelegatedFrameHost( EvasGLDelegatedFrameHostClient* client) - : client_(client), weak_ptr_factory_(this) {} + : client_(client), is_initialized_(false), weak_ptr_factory_(this) {} EvasGLDelegatedFrameHost::~EvasGLDelegatedFrameHost() { + if (!is_initialized_) + return; ClearRenderPasses(); ClearChildId(); } @@ -43,11 +45,15 @@ void EvasGLDelegatedFrameHost::Initialize() { &settings_, output_surface_.get(), resource_provider_.get(), nullptr); renderer_->Initialize(); renderer_->SetVisible(true); + is_initialized_ = true; } void EvasGLDelegatedFrameHost::SwapDelegatedFrame( const viz::LocalSurfaceId& local_surface_id, viz::CompositorFrame frame) { + if (!is_initialized_) + return; + DCHECK(renderer_); DCHECK(resource_provider_); DCHECK(!frame.render_pass_list.empty()); @@ -93,6 +99,9 @@ void EvasGLDelegatedFrameHost::SwapDelegatedFrame( } void EvasGLDelegatedFrameHost::RenderDelegatedFrame(const gfx::Rect& bounds) { + if (!is_initialized_) + return; + DCHECK(renderer_); if (render_pass_list_.empty()) diff --git a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h index 5df4e13..eca2efa 100644 --- a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h +++ b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h @@ -56,6 +56,7 @@ class CONTENT_EXPORT EvasGLDelegatedFrameHost void ClearChildId(); EvasGLDelegatedFrameHostClient* client_; + bool is_initialized_; // TODO(prashant.n): Decouple context provider and surface from this class. scoped_refptr context_provider_; std::unique_ptr output_surface_; -- 2.7.4 From 14978745569ec5ffbadd9437ff5812ae03c1b76e Mon Sep 17 00:00:00 2001 From: "suyambu.rm" Date: Mon, 6 Jan 2020 02:32:03 -0800 Subject: [PATCH 06/16] Move GetUserAgent() from ContentClientEfl to ContentBrowserClientEfl. This change moves overriden methods GetUserAgent, GetProduct to ContentBrowserClientEfl, as per M76 upstream. This helps setting useragent properly in chromium-efl. Change-Id: I2a66ca3f4dc356203ae2c0c199d06fbb261e4fe0 Signed-off-by: suyambu.rm --- tizen_src/ewk/efl_integration/common/content_client_efl.cc | 9 --------- tizen_src/ewk/efl_integration/common/content_client_efl.h | 2 -- tizen_src/ewk/efl_integration/content_browser_client_efl.cc | 10 ++++++++++ tizen_src/ewk/efl_integration/content_browser_client_efl.h | 3 +++ 4 files changed, 13 insertions(+), 11 deletions(-) diff --git a/tizen_src/ewk/efl_integration/common/content_client_efl.cc b/tizen_src/ewk/efl_integration/common/content_client_efl.cc index da63c02..ac0e580 100644 --- a/tizen_src/ewk/efl_integration/common/content_client_efl.cc +++ b/tizen_src/ewk/efl_integration/common/content_client_efl.cc @@ -4,19 +4,10 @@ #include "common/content_client_efl.h" -#include "common/version_info.h" #include "ipc/ipc_message.h" #include "ui/base/resource/resource_bundle.h" #include "ui/base/l10n/l10n_util.h" -std::string ContentClientEfl::GetProduct() const { - return EflWebView::VersionInfo::GetInstance()->ProductNameAndVersionForUserAgent(); -} - -std::string ContentClientEfl::GetUserAgent() const { - return EflWebView::VersionInfo::GetInstance()->DefaultUserAgent(); -} - base::string16 ContentClientEfl::GetLocalizedString(int message_id) const { // TODO(boliu): Used only by WebKit, so only bundle those resources for // Android WebView. diff --git a/tizen_src/ewk/efl_integration/common/content_client_efl.h b/tizen_src/ewk/efl_integration/common/content_client_efl.h index 8d4a924..d36062e 100644 --- a/tizen_src/ewk/efl_integration/common/content_client_efl.h +++ b/tizen_src/ewk/efl_integration/common/content_client_efl.h @@ -16,8 +16,6 @@ namespace IPC { class ContentClientEfl : public content::ContentClient { public: // ContentClient implementation. - std::string GetProduct() const; - std::string GetUserAgent() const; virtual base::string16 GetLocalizedString(int message_id) const override; virtual base::StringPiece GetDataResource( int resource_id, diff --git a/tizen_src/ewk/efl_integration/content_browser_client_efl.cc b/tizen_src/ewk/efl_integration/content_browser_client_efl.cc index ac19277..e912fd5 100644 --- a/tizen_src/ewk/efl_integration/content_browser_client_efl.cc +++ b/tizen_src/ewk/efl_integration/content_browser_client_efl.cc @@ -26,6 +26,7 @@ #include "content/public/browser/resource_dispatcher_host.h" #include "content/public/browser/web_contents.h" #include "content/public/common/content_switches.h" +#include "common/version_info.h" #include "common/web_contents_utils.h" #if defined(OS_TIZEN) @@ -352,4 +353,13 @@ scoped_refptr ContentBrowserClientEfl::CreateQuotaPermissionContext() { return new QuotaPermissionContextEfl(); } + +std::string ContentBrowserClientEfl::GetProduct() const { + return EflWebView::VersionInfo::GetInstance()->ProductNameAndVersionForUserAgent(); +} + +std::string ContentBrowserClientEfl::GetUserAgent() const { + return EflWebView::VersionInfo::GetInstance()->DefaultUserAgent(); +} + } diff --git a/tizen_src/ewk/efl_integration/content_browser_client_efl.h b/tizen_src/ewk/efl_integration/content_browser_client_efl.h index 25a8059..1864567 100644 --- a/tizen_src/ewk/efl_integration/content_browser_client_efl.h +++ b/tizen_src/ewk/efl_integration/content_browser_client_efl.h @@ -113,6 +113,9 @@ class ContentBrowserClientEfl : public ContentBrowserClient { browser_context_efl_ = context; } + std::string GetProduct() const override; + std::string GetUserAgent() const override; + private: static void SetCertificatePemOnUIThread(int render_process_id, int render_view_id, -- 2.7.4 From d3b7a2f6df3c39f33eb69a72bd33180356dccc74 Mon Sep 17 00:00:00 2001 From: "suyambu.rm" Date: Sun, 29 Dec 2019 22:24:31 -0800 Subject: [PATCH 07/16] [M76 Migration] Enable MSAA sample count for Canvas2D. This helps skia to use accelerated rendering for canvas2d. This change also removes unwanted canvas command line flags. Reference: https://review.tizen.org/gerrit/c/platform/framework/web/chromium-efl/+/203296 Change-Id: I8ef938f68b77a1e72ac7eb57e12679da633fa8dc Signed-off-by: suyambu.rm (cherry picked from commit fe15cb8a166b69b9d74e9a210310d37c32357a3a) --- tizen_src/chromium_impl/efl/init.cc | 4 ---- tizen_src/ewk/efl_integration/command_line_efl.cc | 9 ++------- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/tizen_src/chromium_impl/efl/init.cc b/tizen_src/chromium_impl/efl/init.cc index 2941cc1..2bdfa61 100644 --- a/tizen_src/chromium_impl/efl/init.cc +++ b/tizen_src/chromium_impl/efl/init.cc @@ -100,10 +100,6 @@ void AppendPortParams(base::CommandLine& cmdline) { #if !defined(OS_TIZEN) cmdline.AppendSwitch(switches::kIgnoreGpuBlacklist); #endif - - if (IsTvProfile()) { - cmdline.AppendSwitchASCII(switches::kAcceleratedCanvas2dMSAASampleCount, "4"); - } } } // namespace efl diff --git a/tizen_src/ewk/efl_integration/command_line_efl.cc b/tizen_src/ewk/efl_integration/command_line_efl.cc index 573710e..d95fe15 100644 --- a/tizen_src/ewk/efl_integration/command_line_efl.cc +++ b/tizen_src/ewk/efl_integration/command_line_efl.cc @@ -64,14 +64,12 @@ content::MainFunctionParams CommandLineEfl::GetDefaultPortParams() { #endif #if defined(OS_TIZEN) + p_command_line->AppendSwitchASCII( + switches::kAcceleratedCanvas2dMSAASampleCount, "4"); #if !defined(EWK_BRINGUP) p_command_line->AppendSwitch(switches::kEnableGestureTapHighlight); p_command_line->AppendSwitch(switches::kEnableSpatialNavigation); p_command_line->AppendSwitch(switches::kMainFrameResizesAreOrientationChanges); - p_command_line->AppendSwitch(switches::kForceAccelerated2dCanvas); -// [M44_2403] Temporary disabling the codes for switching to new chromium -// FIXME: http://web.sec.samsung.net/bugzilla/show_bug.cgi?id=14040 - p_command_line->AppendSwitch(cc::switches::kEnableParallelCanvasMode); #endif // EWK_BRINGUP #endif @@ -82,9 +80,6 @@ content::MainFunctionParams CommandLineEfl::GetDefaultPortParams() { switches::kTouchEventFeatureDetectionEnabled); #if !defined(EWK_BRINGUP) p_command_line->AppendSwitch(switches::kEnablePinch); - // [M42_2231] FIXME: Need Parallel Canvas patch for S-Chromium/S-Blink/S-Skia - p_command_line->AppendSwitchASCII( - switches::kAcceleratedCanvas2dMSAASampleCount, "4"); #endif } -- 2.7.4 From 43d73cffb917841bfa43b8c80dff43e18a1c762e Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Fri, 10 Jan 2020 11:05:34 +0530 Subject: [PATCH 08/16] [M76 Migration] Replace elm naviframe with elm layout A naviframe is an element which holds and manages views. It allows to create special effects when one view is being changed to another one. But chromium-efl does not use such special effects because naviframe contains only one view at a time and the transition between views does not occur. This patch replaces elm naviframe with elm layout. 3D Memory for google.com on TM1 target: With Patch : 1644 Without Patch : 5372 Reference: https://review.tizen.org/gerrit/#/c/202482/ Change-Id: I236adc97ec98059b96c660765090d0d4096d7c74 Signed-off-by: Chandan Padhi --- .../renderer_host/render_widget_host_view_efl.cc | 1 + .../browser/web_contents/web_contents_view_efl.cc | 23 ++++++++++------------ tizen_src/chromium_impl/edje_resources/BUILD.gn | 1 + .../chromium_impl/edje_resources/MainLayout.edc | 20 +++++++++++++++++++ 4 files changed, 32 insertions(+), 13 deletions(-) create mode 100644 tizen_src/chromium_impl/edje_resources/MainLayout.edc diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc index 89768a4..8abd4fa 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc @@ -173,6 +173,7 @@ RenderWidgetHostViewEfl::RenderWidgetHostViewEfl(RenderWidgetHost* widget_host, void RenderWidgetHostViewEfl::InitAsChild(gfx::NativeView /* parent_view */) { content_image_elm_host_ = elm_bg_add(parent_view_); + elm_object_part_content_set(parent_view_, "content", content_image_elm_host_); content_image_ = evas_object_image_filled_add(evas_); elm_object_part_content_set(content_image_elm_host_, "overlay", content_image_); diff --git a/tizen_src/chromium_impl/content/browser/web_contents/web_contents_view_efl.cc b/tizen_src/chromium_impl/content/browser/web_contents/web_contents_view_efl.cc index 0589ac5..5fc7fab 100644 --- a/tizen_src/chromium_impl/content/browser/web_contents/web_contents_view_efl.cc +++ b/tizen_src/chromium_impl/content/browser/web_contents/web_contents_view_efl.cc @@ -8,12 +8,15 @@ #include #include "base/command_line.h" +#include "base/files/file_path.h" #include "base/logging.h" +#include "base/path_service.h" #include "base/strings/utf_string_conversions.h" #include "content/browser/renderer_host/render_widget_host_view_efl.h" #include "content/browser/web_contents/web_contents_impl.h" #include "content/browser/web_contents/web_drag_dest_efl.h" #include "content/browser/web_contents/web_drag_source_efl.h" +#include "content/common/paths_efl.h" #include "content/common/view_messages.h" #include "content/public/browser/interstitial_page.h" #include "content/public/browser/render_view_host.h" @@ -68,13 +71,14 @@ void WebContentsViewEfl::CreateView(const gfx::Size& initial_size, gfx::NativeView context) { Evas_Object* root_window = efl::WindowFactory::GetHostWindow(web_contents_); - native_view_ = elm_naviframe_add(root_window); - elm_naviframe_content_preserve_on_pop_set(native_view_, EINA_TRUE); + native_view_ = elm_layout_add(root_window); - if (!initial_size.IsEmpty()) - evas_object_resize(native_view_, initial_size.width(), - initial_size.height()); - evas_object_show(native_view_); + base::FilePath edj_dir; + base::PathService::Get(PathsEfl::EDJE_RESOURCE_DIR, &edj_dir); + + base::FilePath main_edj = edj_dir.Append(FILE_PATH_LITERAL("MainLayout.edj")); + elm_layout_file_set(native_view_, main_edj.AsUTF8Unsafe().c_str(), + "main_layout"); GLSharedContextEfl::Initialize(root_window); @@ -88,13 +92,6 @@ RenderWidgetHostViewBase* WebContentsViewEfl::CreateViewForWidget( RenderWidgetHostViewEfl* view = new RenderWidgetHostViewEfl(render_widget_host, *web_contents_); view->InitAsChild(nullptr); - - elm_naviframe_item_pop(native_view_); - Evas_Object* content_view = static_cast(view->GetNativeView()); - Elm_Object_Item* item = elm_naviframe_item_push(native_view_, NULL, NULL, - NULL, content_view, NULL); - elm_naviframe_item_title_enabled_set(item, EINA_FALSE, EINA_FALSE); - view->SetTouchEventsEnabled(touch_enabled_); view->Show(); diff --git a/tizen_src/chromium_impl/edje_resources/BUILD.gn b/tizen_src/chromium_impl/edje_resources/BUILD.gn index 9c03ac4..8174d55 100644 --- a/tizen_src/chromium_impl/edje_resources/BUILD.gn +++ b/tizen_src/chromium_impl/edje_resources/BUILD.gn @@ -33,6 +33,7 @@ edje_res_efl("edje_resources_efl") { "DisambiguationPopup.edc", "Edge.edc", "Magnifier.edc", + "MainLayout.edc", "SelectionHandles.edc", ] } diff --git a/tizen_src/chromium_impl/edje_resources/MainLayout.edc b/tizen_src/chromium_impl/edje_resources/MainLayout.edc new file mode 100644 index 0000000..3c4c1ac --- /dev/null +++ b/tizen_src/chromium_impl/edje_resources/MainLayout.edc @@ -0,0 +1,20 @@ +collections { base_scale: 2.0; + group { + name: "main_layout"; + parts { + part { + name: "content"; + type: SWALLOW; + scale: 1; + description { + state: "default" 0.0; + visible: 1; + fixed: 1 1; + align: 0.0 0.0; + rel1 { relative: 0.0 0.0; } + rel2 { relative: 1.0 1.0; } + } + } + } + } +} -- 2.7.4 From 1a6b215ca1f3d0cae1d84e0ad4c3a54009529733 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Mon, 13 Jan 2020 14:37:19 +0530 Subject: [PATCH 09/16] Remove EWK_BRINGUP in gpu_info_collector_efl.cc This patch removes unused code in gpu_info_collector_efl.cc. Change-Id: I77c094db81919ca5025eaadcfbb21c7defca4bcb Signed-off-by: Chandan Padhi --- .../gpu/config/gpu_info_collector_efl.cc | 44 ---------------------- 1 file changed, 44 deletions(-) diff --git a/tizen_src/chromium_impl/gpu/config/gpu_info_collector_efl.cc b/tizen_src/chromium_impl/gpu/config/gpu_info_collector_efl.cc index 41d15c4..d2b33b5 100644 --- a/tizen_src/chromium_impl/gpu/config/gpu_info_collector_efl.cc +++ b/tizen_src/chromium_impl/gpu/config/gpu_info_collector_efl.cc @@ -4,10 +4,6 @@ #include "gpu/config/gpu_info_collector.h" -#include "base/strings/string_number_conversions.h" -#include "base/strings/string_piece.h" -#include "base/strings/string_split.h" -#include "base/strings/string_util.h" #include "gpu/config/gpu_preferences.h" #include "gpu/config/scoped_restore_non_owned_egl_context.h" @@ -17,37 +13,6 @@ #include "media/gpu/ipc/service/gpu_video_encode_accelerator.h" #endif -namespace { - -std::string GetDriverVersionFromString(const std::string& version_string) { - // Extract driver version from the second number in a string like: - // "OpenGL ES 2.0 V@6.0 AU@ (CL@2946718)" - - // Exclude first "2.0". - size_t begin = version_string.find_first_of("0123456789"); - if (begin == std::string::npos) - return "0"; - size_t end = version_string.find_first_not_of("01234567890.", begin); - - // Extract number of the form "%d.%d" - begin = version_string.find_first_of("0123456789", end); - if (begin == std::string::npos) - return "0"; - end = version_string.find_first_not_of("01234567890.", begin); - std::string sub_string; - if (end != std::string::npos) - sub_string = version_string.substr(begin, end - begin); - else - sub_string = version_string.substr(begin); - std::vector pieces = base::SplitString( - sub_string, ".", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); - if (pieces.size() < 2) - return "0"; - return pieces[0] + "." + pieces[1]; -} - -} // namespace - namespace gpu { bool CollectBasicGraphicsInfo(GPUInfo* gpu_info) { @@ -75,13 +40,4 @@ bool CollectContextGraphicsInfo(GPUInfo* gpu_info) { return success; } -void CollectDriverInfoGL(GPUInfo* gpu_info) { - DCHECK(gpu_info); -#if !defined(EWK_BRINGUP) - gpu_info->driver_version = GetDriverVersionFromString(gpu_info->gl_version); -#endif - gpu_info->gpu.vendor_string = gpu_info->gl_vendor; - gpu_info->gpu.device_string = gpu_info->gl_renderer; -} - } // namespace gpu -- 2.7.4 From d4a10babe0c097e64c5842672e214562b409c942 Mon Sep 17 00:00:00 2001 From: Gajendra N Date: Tue, 31 Dec 2019 11:34:04 +0530 Subject: [PATCH 10/16] Cleanup old device_sensors code After M63, DataFetcher* classes were removed and replaced by generic_sensor. Hence, code related to device_sensors can be removed. This patch does the same. Change-Id: I979326056b36319c7623746ca9bd518726ad197c Signed-off-by: Gajendra N (cherry picked from commit eb347d19aa7dfafd774f867267f3a766fb56f3b2) --- .../device_sensors/data_fetcher_impl_tizen.cc | 262 --------------------- .../device_sensors/data_fetcher_impl_tizen.h | 65 ----- .../data_fetcher_shared_memory_tizen.cc | 67 ------ 3 files changed, 394 deletions(-) delete mode 100644 tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.cc delete mode 100644 tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.h delete mode 100644 tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_shared_memory_tizen.cc diff --git a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.cc b/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.cc deleted file mode 100644 index 5ac64bf..0000000 --- a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.cc +++ /dev/null @@ -1,262 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "content/browser/device_sensors/data_fetcher_impl_tizen.h" - -#include "base/logging.h" -#include "base/memory/singleton.h" -#include "build/tizen_version.h" - -namespace content { - -static sensor_h sensor_orientation_; -static sensor_h sensor_accelerometer_; -static sensor_h sensor_gyroscope_; -static sensor_listener_h listener_orientation_; -static sensor_listener_h listener_accelerometer_; -static sensor_listener_h listener_gyroscope_; - -DataFetcherImplTizen::DataFetcherImplTizen() - : device_motion_buffer_(NULL), - device_orientation_buffer_(NULL), - has_last_motion_data_(false), - last_motion_timestamp_(0), - is_orientation_buffer_ready_(false) { - sensor_get_default_sensor(SENSOR_ORIENTATION, &sensor_orientation_); - sensor_get_default_sensor(SENSOR_ACCELEROMETER, &sensor_accelerometer_); - sensor_get_default_sensor(SENSOR_GYROSCOPE, &sensor_gyroscope_); - - sensor_create_listener(sensor_orientation_, &listener_orientation_); - sensor_create_listener(sensor_accelerometer_, &listener_accelerometer_); - sensor_create_listener(sensor_gyroscope_, &listener_gyroscope_); -} - -DataFetcherImplTizen::~DataFetcherImplTizen() { - sensor_listener_unset_event_cb(listener_orientation_); - sensor_listener_stop(listener_orientation_); - sensor_destroy_listener(listener_orientation_); - - sensor_listener_unset_event_cb(listener_accelerometer_); - sensor_listener_stop(listener_accelerometer_); - sensor_destroy_listener(listener_accelerometer_); - - sensor_listener_stop(listener_gyroscope_); - sensor_destroy_listener(listener_gyroscope_); -} - -DataFetcherImplTizen* DataFetcherImplTizen::GetInstance() { - return base::Singleton >::get(); -} - -bool DataFetcherImplTizen::StartFetchingDeviceMotionData( - DeviceMotionHardwareBuffer* buffer) { - DCHECK(buffer); - { - base::AutoLock autolock(motion_buffer_lock_); - device_motion_buffer_ = buffer; - } - sensor_listener_set_event_cb( - listener_accelerometer_, kDeviceSensorIntervalMicroseconds / 1000, - DataFetcherImplTizen::onAccelerationChanged, this); - return Start(CONSUMER_TYPE_MOTION); -} - -void DataFetcherImplTizen::StopFetchingDeviceMotionData() { - Stop(CONSUMER_TYPE_MOTION); - { - base::AutoLock autolock(motion_buffer_lock_); - if (device_motion_buffer_) { - sensor_listener_unset_event_cb(listener_accelerometer_); - device_motion_buffer_ = NULL; - } - } -} - -bool DataFetcherImplTizen::StartFetchingDeviceOrientationData( - DeviceOrientationHardwareBuffer* buffer) { - DCHECK(buffer); - { - base::AutoLock autolock(orientation_buffer_lock_); - device_orientation_buffer_ = buffer; - } - sensor_listener_set_event_cb( - listener_orientation_, kDeviceSensorIntervalMicroseconds / 1000, - DataFetcherImplTizen::onOrientationChanged, this); - bool success = Start(CONSUMER_TYPE_ORIENTATION); - - { - base::AutoLock autolock(orientation_buffer_lock_); - // If Start() was unsuccessful then set the buffer ready flag to true - // to start firing all-null events. - SetOrientationBufferReadyStatus(!success); - } - return success; -} - -void DataFetcherImplTizen::StopFetchingDeviceOrientationData() { - Stop(CONSUMER_TYPE_ORIENTATION); - { - base::AutoLock autolock(orientation_buffer_lock_); - if (device_orientation_buffer_) { - SetOrientationBufferReadyStatus(false); - sensor_listener_unset_event_cb(listener_orientation_); - device_orientation_buffer_ = NULL; - } - } -} - -bool DataFetcherImplTizen::Start(ConsumerType type) { - switch(type) { - case CONSUMER_TYPE_ORIENTATION: - return (SENSOR_ERROR_NONE == sensor_listener_start(listener_orientation_)); - case CONSUMER_TYPE_MOTION: - if (SENSOR_ERROR_NONE != sensor_listener_start(listener_accelerometer_)) { - return false; - } - return (SENSOR_ERROR_NONE == sensor_listener_start(listener_gyroscope_)); - default: - NOTREACHED(); - return false; - } - -} - -void DataFetcherImplTizen::Stop(ConsumerType type) { - switch(type) { - case CONSUMER_TYPE_ORIENTATION: - sensor_listener_stop(listener_orientation_); - return; - case CONSUMER_TYPE_MOTION: - sensor_listener_stop(listener_accelerometer_); - sensor_listener_stop(listener_gyroscope_); - memset(&last_motion_data_, 0, sizeof(last_motion_data_)); - has_last_motion_data_ = false; - return; - default: - NOTREACHED(); - return; - } -} - -//static -void DataFetcherImplTizen::onOrientationChanged(sensor_h sensor, - sensor_event_s *event, void* userData) { - DataFetcherImplTizen *fetcher = static_cast(userData); - base::AutoLock autolock(fetcher->orientation_buffer_lock_); - - if (!fetcher->device_orientation_buffer_) - return; - - fetcher->device_orientation_buffer_->seqlock.WriteBegin(); - - float azimuth = event->values[0]; - float pitch = event->values[1]; - float roll = event->values[2]; - - fetcher->device_orientation_buffer_->data.alpha = azimuth; - fetcher->device_orientation_buffer_->data.has_alpha = true; - fetcher->device_orientation_buffer_->data.beta = pitch; - fetcher->device_orientation_buffer_->data.has_beta = true; - fetcher->device_orientation_buffer_->data.gamma = roll; - fetcher->device_orientation_buffer_->data.has_gamma = true; - fetcher->device_orientation_buffer_->seqlock.WriteEnd(); - - if (!fetcher->is_orientation_buffer_ready_) - fetcher->SetOrientationBufferReadyStatus(true); -} - -//static -void DataFetcherImplTizen::onAccelerationChanged(sensor_h sensor, - sensor_event_s *event, void* userData) { - DataFetcherImplTizen *self = static_cast(userData); - - float x = event->values[0]; - float y = event->values[1]; - float z = event->values[2]; - - float gravityX = x * 0.2f; - float gravityY = y * 0.2f; - float gravityZ = z * 0.2f; - bool accelerationAvailable = false; - - unsigned long long timestamp = event->timestamp; - - double interval = static_cast( - self->last_motion_timestamp_ - ? (timestamp - self->last_motion_timestamp_) / 1000 - : kDeviceSensorIntervalMicroseconds / 1000); - self->last_motion_timestamp_ = timestamp; - - if (self->has_last_motion_data_) { - const DeviceMotionHardwareBuffer* m = self->last_motion_data_; - gravityX += - (m->data.acceleration_including_gravity_x - m->data.acceleration_x) * - 0.8f; - gravityY += - (m->data.acceleration_including_gravity_x - m->data.acceleration_y) * - 0.8f; - gravityZ += - (m->data.acceleration_including_gravity_z - m->data.acceleration_z) * - 0.8f; - accelerationAvailable = true; - } - - float alpha, beta, gamma; - bool rotationRateAvailable = false; - - sensor_event_s event_gyroscope; - if (!sensor_listener_read_data(listener_gyroscope_, &event_gyroscope)) - rotationRateAvailable = true; - - alpha = event_gyroscope.values[0]; - beta = event_gyroscope.values[1]; - gamma = event_gyroscope.values[2]; - - self->device_motion_buffer_->seqlock.WriteBegin(); - - self->device_motion_buffer_->data.acceleration_including_gravity_x = x; - self->device_motion_buffer_->data.has_acceleration_including_gravity_x = true; - self->device_motion_buffer_->data.acceleration_including_gravity_x = y; - self->device_motion_buffer_->data.has_acceleration_including_gravity_x = true; - self->device_motion_buffer_->data.acceleration_including_gravity_z = z; - self->device_motion_buffer_->data.has_acceleration_including_gravity_z = true; - - self->device_motion_buffer_->data.acceleration_x = x - gravityX; - self->device_motion_buffer_->data.has_acceleration_x = accelerationAvailable; - self->device_motion_buffer_->data.acceleration_y = y - gravityY; - self->device_motion_buffer_->data.has_acceleration_y = accelerationAvailable; - self->device_motion_buffer_->data.acceleration_z = z - gravityZ; - self->device_motion_buffer_->data.has_acceleration_z = accelerationAvailable; - - self->device_motion_buffer_->data.rotation_rate_alpha = alpha; - self->device_motion_buffer_->data.has_rotation_rate_alpha = - rotationRateAvailable; - self->device_motion_buffer_->data.rotation_rate_beta = beta; - self->device_motion_buffer_->data.has_rotation_rate_beta = - rotationRateAvailable; - self->device_motion_buffer_->data.rotation_rate_gamma = gamma; - self->device_motion_buffer_->data.has_rotation_rate_gamma = - rotationRateAvailable; - - self->device_motion_buffer_->data.all_available_sensors_are_active = - (accelerationAvailable && rotationRateAvailable); - - self->last_motion_data_ = self->device_motion_buffer_; - self->has_last_motion_data_ = true; - - self->device_motion_buffer_->data.interval = interval; - - self->device_motion_buffer_->seqlock.WriteEnd(); -} - -void DataFetcherImplTizen::SetOrientationBufferReadyStatus(bool ready) { - device_orientation_buffer_->seqlock.WriteBegin(); - device_orientation_buffer_->data.absolute = ready; - device_orientation_buffer_->data.all_available_sensors_are_active = ready; - device_orientation_buffer_->seqlock.WriteEnd(); - is_orientation_buffer_ready_ = ready; -} - -} // namespace content diff --git a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.h b/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.h deleted file mode 100644 index 18a259d..0000000 --- a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_impl_tizen.h +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef DATA_FETCHER_IMPL_TIZEN_H_ -#define DATA_FETCHER_IMPL_TIZEN_H_ - -#include - -#include "base/synchronization/lock.h" -#include "device/sensors/device_sensors_consts.h" -#include "device/sensors/public/cpp/device_motion_hardware_buffer.h" -#include "device/sensors/public/cpp/device_orientation_hardware_buffer.h" - -namespace base { -template struct DefaultSingletonTraits; -} - -namespace content { - -using namespace device; - -// FIXME: This class should be moved to device namespace. -class DataFetcherImplTizen { - public: - static DataFetcherImplTizen* GetInstance(); - - // Shared memory related methods. - bool StartFetchingDeviceMotionData(DeviceMotionHardwareBuffer* buffer); - void StopFetchingDeviceMotionData(); - - bool StartFetchingDeviceOrientationData( - DeviceOrientationHardwareBuffer* buffer); - void StopFetchingDeviceOrientationData(); - - virtual bool Start(ConsumerType); - virtual void Stop(ConsumerType); - - protected: - DataFetcherImplTizen(); - virtual ~DataFetcherImplTizen(); - static void onOrientationChanged(sensor_h sensor, sensor_event_s *event, void* userData); - static void onAccelerationChanged(sensor_h sensor, sensor_event_s *event, void* userData); - - private: - friend struct base::DefaultSingletonTraits; - - void SetOrientationBufferReadyStatus(bool ready); - - DeviceMotionHardwareBuffer* device_motion_buffer_; - DeviceOrientationHardwareBuffer* device_orientation_buffer_; - DeviceMotionHardwareBuffer* last_motion_data_; - bool has_last_motion_data_; - unsigned long long last_motion_timestamp_; - bool is_orientation_buffer_ready_; - - base::Lock motion_buffer_lock_; - base::Lock orientation_buffer_lock_; - - DISALLOW_COPY_AND_ASSIGN(DataFetcherImplTizen); -}; - -} // namespace content - -#endif // DATA_FETCHER_IMPL_TIZEN_H_ diff --git a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_shared_memory_tizen.cc b/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_shared_memory_tizen.cc deleted file mode 100644 index 29e1cc2..0000000 --- a/tizen_src/chromium_impl/content/browser/device_sensors/data_fetcher_shared_memory_tizen.cc +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#if defined(OS_TIZEN) -#include "content/browser/device_sensors/data_fetcher_impl_tizen.h" -#endif - -#include "base/logging.h" -#include "content/browser/device_sensors/data_fetcher_shared_memory.h" -#include "device/sensors/public/cpp/device_motion_hardware_buffer.h" -#include "device/sensors/public/cpp/device_orientation_hardware_buffer.h" -#include "tizen/system_info.h" - -namespace content { - -DataFetcherSharedMemory::DataFetcherSharedMemory() { -} - -DataFetcherSharedMemory::~DataFetcherSharedMemory() { -} - -bool DataFetcherSharedMemory::Start(ConsumerType consumer_type, void* buffer) { - if (!(IsMobileProfile() || IsWearableProfile())) - return false; - - DCHECK(buffer); - - switch (consumer_type) { - case CONSUMER_TYPE_MOTION: - return DataFetcherImplTizen::GetInstance()-> - StartFetchingDeviceMotionData( - static_cast(buffer)); - case CONSUMER_TYPE_ORIENTATION: - return DataFetcherImplTizen::GetInstance()-> - StartFetchingDeviceOrientationData( - static_cast(buffer)); - default: - NOTREACHED(); - } - return false; -} - -bool DataFetcherSharedMemory::Stop(ConsumerType consumer_type) { - if (!(IsMobileProfile() || IsWearableProfile())) - return false; - - switch (consumer_type) { - case CONSUMER_TYPE_MOTION: - DataFetcherImplTizen::GetInstance()->StopFetchingDeviceMotionData(); - return true; - case CONSUMER_TYPE_ORIENTATION: - DataFetcherImplTizen::GetInstance()->StopFetchingDeviceOrientationData(); - return true; - default: - NOTREACHED(); - } - return false; -} - -#if !defined(EWK_BRINGUP) -DataFetcherSharedMemory::FetcherType DataFetcherSharedMemory::GetType() const { - return FETCHER_TYPE_SEPARATE_THREAD; -} -#endif - -} // namespace content -- 2.7.4 From b1f5d81a0ca6d6f45ecbde49f35465613f4786ad Mon Sep 17 00:00:00 2001 From: "suyambu.rm" Date: Tue, 28 Jan 2020 04:38:38 -0800 Subject: [PATCH 11/16] [M76 Migration] Handle fling gesture events in the browser process for EFL port Fling events handling has been moved from renderer to browser in upstream chromium as per [1]. Fling scroll was not working in M69 as fling events were not handled in the browser for chromium-efl. With this change, DidStopFlinging gets called naturally when fling ends which fixes hidden contextmenu not shown issue in [2]. Reference: https://review.tizen.org/gerrit/c/platform/framework/web/chromium-efl/+/217340 Change-Id: Ie601be59ab05ef51c762c9ebd1cdc20dd67ce36e Signed-off-by: suyambu.rm --- .../browser/compositor/evasgl_delegated_frame_host.cc | 3 +-- .../browser/compositor/evasgl_delegated_frame_host.h | 2 +- .../browser/renderer_host/render_widget_host_view_efl.cc | 13 +++++++++++-- .../browser/renderer_host/render_widget_host_view_efl.h | 4 +++- 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc index c477f64..e483ac9 100644 --- a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc +++ b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc @@ -93,8 +93,7 @@ void EvasGLDelegatedFrameHost::SwapDelegatedFrame( ClearRenderPasses(resources_in_frame); DCHECK(!invalid_frame); - client_->DelegatedFrameHostSendReclaimCompositorResources( - local_surface_id, returned_resources_); + client_->DidReceiveCompositorFrameAck(local_surface_id, returned_resources_); returned_resources_.clear(); } diff --git a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h index eca2efa..ff87648 100644 --- a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h +++ b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.h @@ -30,7 +30,7 @@ class CONTENT_EXPORT EvasGLDelegatedFrameHostClient { // and surface from EvasGLDelegatedFrameHost. virtual Evas_GL_API* GetEvasGLAPI() = 0; virtual Evas_GL* GetEvasGL() = 0; - virtual void DelegatedFrameHostSendReclaimCompositorResources( + virtual void DidReceiveCompositorFrameAck( const viz::LocalSurfaceId& local_surface_id, const std::vector& resources) = 0; }; diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc index 8abd4fa..8127a23 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc @@ -331,10 +331,12 @@ Evas_GL* RenderWidgetHostViewEfl::GetEvasGL() { return evas_gl_; } -void RenderWidgetHostViewEfl::DelegatedFrameHostSendReclaimCompositorResources( +void RenderWidgetHostViewEfl::DidReceiveCompositorFrameAck( const viz::LocalSurfaceId& local_surface_id, const std::vector& resources) { renderer_compositor_frame_sink_->DidReceiveCompositorFrameAck(resources); + if (needs_begin_frames_) + host_->ProgressFlingIfNeeded(base::TimeTicks::Now()); } void RenderWidgetHostViewEfl::InitializeDeviceDisplayInfo() { @@ -963,7 +965,14 @@ bool RenderWidgetHostViewEfl::RequestSnapshotAsync( void RenderWidgetHostViewEfl::SetWantsAnimateOnlyBeginFrames() {} -void RenderWidgetHostViewEfl::SetNeedsBeginFrames(bool needs_begin_frames) {} +void RenderWidgetHostViewEfl::SetNeedsBeginFrames(bool needs_begin_frames) { + if (needs_begin_frames_ == needs_begin_frames) + return; + + needs_begin_frames_ = needs_begin_frames; + if (needs_begin_frames_) + host_->ProgressFlingIfNeeded(base::TimeTicks::Now()); +} void RenderWidgetHostViewEfl::DidOverscroll( const ui::DidOverscrollParams& params) { diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.h b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.h index a9bdf83..6dc4ad9 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.h +++ b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.h @@ -244,7 +244,7 @@ class CONTENT_EXPORT RenderWidgetHostViewEfl // EvasGLDelegatedFrameHostClient implementation. Evas_GL_API* GetEvasGLAPI() override; - void DelegatedFrameHostSendReclaimCompositorResources( + void DidReceiveCompositorFrameAck( const viz::LocalSurfaceId& local_surface_id, const std::vector& resources) override; Evas_GL* GetEvasGL() override; @@ -361,6 +361,8 @@ class CONTENT_EXPORT RenderWidgetHostViewEfl viz::mojom::CompositorFrameSinkClient* renderer_compositor_frame_sink_ = nullptr; + bool needs_begin_frames_ = false; + base::WeakPtrFactory weak_factory_; DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewEfl); -- 2.7.4 From 87f721a48e3618075719bc6b392b434fa9d2ce59 Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Mon, 2 Mar 2020 16:29:07 +0530 Subject: [PATCH 12/16] [SVACE] Fix SVACE issues This commit also includes changes from https://review.tizen.org/gerrit/#/c/212346/. Change-Id: I7dc953af267b09c31106dd146f6f40da7aa17c12 Signed-off-by: Chandan Padhi --- .../compositor/evasgl_delegated_frame_host.cc | 5 +- .../renderer_host/disambiguation_popup_efl.cc | 14 ++-- .../content/browser/renderer_host/edge_effect.cc | 4 +- .../renderer_host/render_widget_host_view_efl.cc | 1 + .../browser/selection/selection_controller_efl.cc | 3 - .../browser/selection/selection_controller_efl.h | 1 + .../media/base/tizen/media_player_bridge_capi.h | 2 - .../ewk/efl_integration/autofill_popup_view_efl.cc | 12 ++-- .../browser/autofill/autofill_client_efl.cc | 4 +- .../browser/browsing_data_remover_efl.cc | 75 ++++++++++++++-------- .../password_manager/password_store_factory.cc | 5 +- .../password_manager/password_store_factory.h | 6 +- .../common/navigation_policy_params.cc | 4 +- .../efl_integration/context_menu_controller_efl.cc | 10 +++ .../efl_integration/context_menu_controller_efl.h | 12 +--- .../ewk/efl_integration/devtools_delegate_efl.cc | 3 +- .../ewk/efl_integration/devtools_delegate_efl.h | 2 - tizen_src/ewk/efl_integration/eweb_view.cc | 3 + .../efl_integration/private/ewk_settings_private.h | 1 - .../private/ewk_user_media_private.cc | 4 +- tizen_src/ewk/efl_integration/public/ewk_view.cc | 5 +- .../url_request_context_getter_efl.cc | 18 +++--- .../efl_integration/web_contents_delegate_efl.cc | 8 +-- tizen_src/ewk/efl_webview_app/app.c | 22 +++---- 24 files changed, 122 insertions(+), 102 deletions(-) diff --git a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc index e483ac9..4e06095 100644 --- a/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc +++ b/tizen_src/chromium_impl/content/browser/compositor/evasgl_delegated_frame_host.cc @@ -15,7 +15,10 @@ namespace content { EvasGLDelegatedFrameHost::EvasGLDelegatedFrameHost( EvasGLDelegatedFrameHostClient* client) - : client_(client), is_initialized_(false), weak_ptr_factory_(this) {} + : client_(client), + is_initialized_(false), + child_id_(0), + weak_ptr_factory_(this) {} EvasGLDelegatedFrameHost::~EvasGLDelegatedFrameHost() { if (!is_initialized_) diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/disambiguation_popup_efl.cc b/tizen_src/chromium_impl/content/browser/renderer_host/disambiguation_popup_efl.cc index aaad053..e6c6fa9 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/disambiguation_popup_efl.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/disambiguation_popup_efl.cc @@ -55,12 +55,14 @@ void TouchedOnOutterArea(void* data, Evas*, Evas_Object* image, void* event_info } // namespace -DisambiguationPopupEfl::DisambiguationPopupEfl( - Evas_Object* parent_view, RenderWidgetHostViewEfl* rwhv) - : rwhv_(rwhv) - , parent_view_(parent_view) - , content_image_(NULL) - , popup_(NULL) { +DisambiguationPopupEfl::DisambiguationPopupEfl(Evas_Object* parent_view, + RenderWidgetHostViewEfl* rwhv) + : rwhv_(rwhv), + parent_view_(parent_view), + content_image_(nullptr), + popup_(nullptr), + height_(0), + width_(0) { CHECK(parent_view); CHECK(rwhv); diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/edge_effect.cc b/tizen_src/chromium_impl/content/browser/renderer_host/edge_effect.cc index 806c19d..a4e3648 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/edge_effect.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/edge_effect.cc @@ -123,7 +123,7 @@ void EdgeEffect::Show(const std::string& source) { else if (source.find("right") != std::string::npos) state = edje_object_part_state_get(edge_object_, "edge_effect_right", &ret); - if (!strcmp(state, "visible")) + if (state && !strcmp(state, "visible")) return; edje_object_signal_emit(edge_object_, "edge,show", source.c_str()); @@ -141,7 +141,7 @@ void EdgeEffect::Hide(const std::string& source) { else if (source.find("right") != std::string::npos) state = edje_object_part_state_get(edge_object_, "edge_effect_right", &ret); - if (strcmp(state, "visible")) + if (state && strcmp(state, "visible")) return; edje_object_signal_emit(edge_object_, "edge,hide", source.c_str()); diff --git a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc index 8127a23..585037a 100644 --- a/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc +++ b/tizen_src/chromium_impl/content/browser/renderer_host/render_widget_host_view_efl.cc @@ -145,6 +145,7 @@ RenderWidgetHostViewEfl::RenderWidgetHostViewEfl(RenderWidgetHost* widget_host, evas_gl_surface_(NULL), handling_disambiguation_popup_gesture_(false), touch_events_enabled_(false), + background_color_(SK_ColorWHITE), web_contents_(web_contents), weak_factory_(this) { parent_view_ = static_cast(web_contents.GetNativeView()); diff --git a/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.cc b/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.cc index 59c0370..861a7b7 100644 --- a/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.cc +++ b/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.cc @@ -24,7 +24,6 @@ namespace content { static const int menuHeight = 140;// The Height fo the context menu. static const int menuPadding = 60;// This is padding for deciding when to modify context menu position. static const int spacePadding = 0; // 24;// This is for making context menu closer to the handles. -static const int textSelectionScrollSize = 50;// Scroll step when selection handler is moving out of viewport. bool IsRectEmpty(const gfx::Rect& rect) { return rect == gfx::Rect(); @@ -51,7 +50,6 @@ SelectionControllerEfl::SelectionControllerEfl(Evas_Object* parent_view, WebCont start_handle_(new SelectionHandleEfl(*this, SelectionHandleEfl::HANDLE_TYPE_LEFT, parent_view)), end_handle_(new SelectionHandleEfl(*this, SelectionHandleEfl::HANDLE_TYPE_RIGHT, parent_view)), input_handle_(new SelectionHandleEfl(*this, SelectionHandleEfl::HANDLE_TYPE_INPUT, parent_view)), - magnifier_(new SelectionMagnifierEfl(this, web_contents)), is_selection_visible_(false), handle_being_dragged_(false), @@ -59,7 +57,6 @@ SelectionControllerEfl::SelectionControllerEfl(Evas_Object* parent_view, WebCont web_contents_(web_contents), selection_mode_(None) { evas_object_event_callback_add(parent_view_, EVAS_CALLBACK_MOVE, &EvasParentViewMoveCallback, this); - #if defined(OS_TIZEN) vconf_notify_key_changed(VCONFKEY_LANGSET, PlatformLanguageChanged, this); #endif diff --git a/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.h b/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.h index 417c6d7..1847407 100644 --- a/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.h +++ b/tizen_src/chromium_impl/content/browser/selection/selection_controller_efl.h @@ -202,6 +202,7 @@ class CONTENT_EXPORT SelectionControllerEfl { SelectionHandleEfl* stationary_handle_; bool is_selection_visible_; + bool handle_being_dragged_; bool selection_on_empty_form_control_; diff --git a/tizen_src/chromium_impl/media/base/tizen/media_player_bridge_capi.h b/tizen_src/chromium_impl/media/base/tizen/media_player_bridge_capi.h index a632176..0acf828d 100644 --- a/tizen_src/chromium_impl/media/base/tizen/media_player_bridge_capi.h +++ b/tizen_src/chromium_impl/media/base/tizen/media_player_bridge_capi.h @@ -86,8 +86,6 @@ class MEDIA_EXPORT MediaPlayerBridgeCapi GURL url_; double volume_; - int media_type_; - bool is_end_reached_; bool is_file_url_; bool is_paused_; diff --git a/tizen_src/ewk/efl_integration/autofill_popup_view_efl.cc b/tizen_src/ewk/efl_integration/autofill_popup_view_efl.cc index 97f79c6..602ec04 100644 --- a/tizen_src/ewk/efl_integration/autofill_popup_view_efl.cc +++ b/tizen_src/ewk/efl_integration/autofill_popup_view_efl.cc @@ -33,10 +33,11 @@ enum AutofillSavePassword { }; AutofillPopupViewEfl::AutofillPopupViewEfl(EWebView* view) - : webview_(view) - , autofill_popup_(NULL) - , autofill_list_(NULL) - , password_popup_(NULL) { + : webview_(view), + autofill_popup_(nullptr), + autofill_list_(nullptr), + password_popup_(nullptr), + selected_line_(-1) { Evas_Object* widgetWin_ = elm_object_top_widget_get( elm_object_parent_widget_get(view->evas_object())); if (!widgetWin_) @@ -197,7 +198,7 @@ void AutofillPopupViewEfl::UpdateFormDataPopup(const gfx::RectF& bounds) evas_object_propagate_events_set(autofill_popup_, false); } -bool isAutofillSpecial(autofill::Suggestion suggestion) { +bool isAutofillSpecial(const autofill::Suggestion& suggestion) { return suggestion.frontend_id != POPUP_ITEM_ID_AUTOCOMPLETE_ENTRY && suggestion.frontend_id != POPUP_ITEM_ID_DATALIST_ENTRY; } @@ -223,7 +224,6 @@ void AutofillPopupViewEfl::InitFormData( labels_[i].resize(AUTOFILL_POPUP_LABEL_LEN); } delegate_ = delegate; - selected_line_ = -1; } void AutofillPopupViewEfl::AcceptSuggestion(size_t index) diff --git a/tizen_src/ewk/efl_integration/browser/autofill/autofill_client_efl.cc b/tizen_src/ewk/efl_integration/browser/autofill/autofill_client_efl.cc index 49ed53c..772746c 100644 --- a/tizen_src/ewk/efl_integration/browser/autofill/autofill_client_efl.cc +++ b/tizen_src/ewk/efl_integration/browser/autofill/autofill_client_efl.cc @@ -49,7 +49,7 @@ void AutofillClientEfl::TabActivated() { } PersonalDataManager* AutofillClientEfl::GetPersonalDataManager() { - if (webview_) { + if (webview_ && webview_->context()) { content::BrowserContextEfl* ctx = webview_->context()->GetImpl()->browser_context(); @@ -67,7 +67,7 @@ scoped_refptr AutofillClientEfl::GetDatabase() { } PrefService* AutofillClientEfl::GetPrefs() { - if(webview_) { + if (webview_ && webview_->context()) { content::BrowserContextEfl* ctx = webview_->context()->GetImpl()->browser_context(); return user_prefs::UserPrefs::Get(ctx); diff --git a/tizen_src/ewk/efl_integration/browser/browsing_data_remover_efl.cc b/tizen_src/ewk/efl_integration/browser/browsing_data_remover_efl.cc index 9a2390e..1d141c9 100644 --- a/tizen_src/ewk/efl_integration/browser/browsing_data_remover_efl.cc +++ b/tizen_src/ewk/efl_integration/browser/browsing_data_remover_efl.cc @@ -1,4 +1,4 @@ -// Copyright 2014 Samsung Electronics. All rights reserved. +// Copyright 2014 Samsung Eaectronics. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -52,21 +52,26 @@ int BrowsingDataRemoverEfl::GenerateQuotaClientMask(int remove_mask) { return quota_client_mask; } -BrowsingDataRemoverEfl::BrowsingDataRemoverEfl(content::BrowserContext* browser_context, base::Time delete_begin, - base::Time delete_end) - : browser_context_(browser_context) - , app_cache_service_(NULL) - , quota_manager_(NULL) - , dom_storage_context_(NULL) - , delete_begin_(delete_begin) - , delete_end_(delete_end) - , next_cache_state_(STATE_NONE) - , cache_(NULL) - , main_context_getter_(NULL) - , media_context_getter_(NULL) - , waiting_for_clear_cache_(false) - , waiting_for_clear_local_storage_(false) - , waiting_for_clear_quota_managed_data_(false) { +BrowsingDataRemoverEfl::BrowsingDataRemoverEfl( + content::BrowserContext* browser_context, + base::Time delete_begin, + base::Time delete_end) + : browser_context_(browser_context), + app_cache_service_(nullptr), + quota_manager_(nullptr), + dom_storage_context_(nullptr), + delete_begin_(delete_begin), + delete_end_(delete_end), + next_cache_state_(STATE_NONE), + cache_(nullptr), + main_context_getter_(nullptr), + media_context_getter_(nullptr), + waiting_for_clear_cache_(false), + waiting_for_clear_local_storage_(false), + waiting_for_clear_quota_managed_data_(false), + quota_managed_origins_to_delete_count_(0), + quota_managed_storage_types_to_delete_count_(0), + remove_mask_(0) { if (browser_context_) { app_cache_service_ = browser_context->GetStoragePartition(browser_context_, NULL)->GetAppCacheService(); main_context_getter_ = @@ -111,18 +116,32 @@ void BrowsingDataRemoverEfl::DoClearCache(int rv) { case STATE_CREATE_MAIN: case STATE_CREATE_MEDIA: { // Get a pointer to the cache. - net::URLRequestContextGetter* getter = - (next_cache_state_ == STATE_CREATE_MAIN) - ? main_context_getter_.get() - : media_context_getter_.get(); - net::HttpTransactionFactory* factory = - getter->GetURLRequestContext()->http_transaction_factory(); - - next_cache_state_ = (next_cache_state_ == STATE_CREATE_MAIN) ? - STATE_DELETE_MAIN : STATE_DELETE_MEDIA; - rv = factory->GetCache()->GetBackend( - &cache_, base::Bind(&BrowsingDataRemoverEfl::DoClearCache, - base::Unretained(this))); + net::URLRequestContextGetter* getter = nullptr; + if (next_cache_state_ == STATE_CREATE_MAIN) { + if (main_context_getter_) + getter = main_context_getter_.get(); + } else { + if (media_context_getter_) + getter = media_context_getter_.get(); + } + if (getter && getter->GetURLRequestContext()) { + net::HttpTransactionFactory* factory = + getter->GetURLRequestContext()->http_transaction_factory(); + if (factory) { + next_cache_state_ = (next_cache_state_ == STATE_CREATE_MAIN) + ? STATE_DELETE_MAIN + : STATE_DELETE_MEDIA; + rv = factory->GetCache()->GetBackend( + &cache_, base::Bind(&BrowsingDataRemoverEfl::DoClearCache, + base::Unretained(this))); + } else { + LOG(ERROR) << "Could not get HttpTransactionFactory."; + next_cache_state_ = STATE_NONE; + } + } else { + LOG(ERROR) << "Could not get URLRequestContext."; + next_cache_state_ = STATE_NONE; + } break; } case STATE_DELETE_MAIN: diff --git a/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.cc b/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.cc index eb4cdc3..af9cf1f 100644 --- a/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.cc +++ b/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.cc @@ -53,8 +53,7 @@ PasswordStoreFactory* PasswordStoreFactory::GetInstance() return base::Singleton::get(); } -PasswordStoreFactory::PasswordStoreFactory() - : service_(NULL) { +PasswordStoreFactory::PasswordStoreFactory() { WebDataServiceFactory::GetInstance(); Init(); } @@ -87,7 +86,7 @@ void PasswordStoreFactory::Init() return; } - service_ = new PasswordStoreService(ps); + service_ = std::make_unique(ps); } #endif // TIZEN_AUTOFILL_SUPPORT diff --git a/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.h b/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.h index ac21ae4..93321ef 100644 --- a/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.h +++ b/tizen_src/ewk/efl_integration/browser/password_manager/password_store_factory.h @@ -36,15 +36,15 @@ class PasswordStoreFactory { static scoped_refptr GetPasswordStore(); static PasswordStoreFactory* GetInstance(); - PasswordStoreService* GetService() { return service_; } + PasswordStoreService* GetService() { return service_.get(); } private: friend struct base::DefaultSingletonTraits; - void Init(); PasswordStoreFactory(); virtual ~PasswordStoreFactory(); + void Init(); - PasswordStoreService* service_; + std::unique_ptr service_; DISALLOW_COPY_AND_ASSIGN(PasswordStoreFactory); }; diff --git a/tizen_src/ewk/efl_integration/common/navigation_policy_params.cc b/tizen_src/ewk/efl_integration/common/navigation_policy_params.cc index 56ec05b4..19d24c74 100644 --- a/tizen_src/ewk/efl_integration/common/navigation_policy_params.cc +++ b/tizen_src/ewk/efl_integration/common/navigation_policy_params.cc @@ -8,9 +8,7 @@ NavigationPolicyParams::NavigationPolicyParams() : render_view_id(-1), -#if !defined(EWK_BRINGUP) // FIXME: m73 bringup - policy(blink::kWebNavigationPolicyIgnore), -#endif + policy(blink::kWebNavigationPolicyCurrentTab), type(blink::kWebNavigationTypeOther), should_replace_current_entry(false), is_main_frame(false), diff --git a/tizen_src/ewk/efl_integration/context_menu_controller_efl.cc b/tizen_src/ewk/efl_integration/context_menu_controller_efl.cc index dd54ef2..991222c 100644 --- a/tizen_src/ewk/efl_integration/context_menu_controller_efl.cc +++ b/tizen_src/ewk/efl_integration/context_menu_controller_efl.cc @@ -42,6 +42,16 @@ int ContextMenuControllerEfl::_popup_item_height = 96; bool ContextMenuControllerEfl::_context_menu_resized = false; std::vector ContextMenuControllerEfl::_context_menu_listdata; +ContextMenuControllerEfl::ContextMenuControllerEfl(EWebView* wv, + WebContents& web_contents) + : webview_(wv), + native_view_(static_cast(web_contents.GetNativeView())), + popup_(nullptr), + menu_items_(nullptr), + web_contents_(web_contents), + is_text_selection_(false), + weak_ptr_factory_(this) {} + ContextMenuControllerEfl::~ContextMenuControllerEfl() { for (std::set::iterator it = clipboard_download_items_.begin(); diff --git a/tizen_src/ewk/efl_integration/context_menu_controller_efl.h b/tizen_src/ewk/efl_integration/context_menu_controller_efl.h index 67e735e..49773b8 100644 --- a/tizen_src/ewk/efl_integration/context_menu_controller_efl.h +++ b/tizen_src/ewk/efl_integration/context_menu_controller_efl.h @@ -67,15 +67,7 @@ class ContextMenuControllerEfl : public download::DownloadItem::Observer { static void ContextMenuItemSelectedCallback(void* data, Evas_Object* obj, void* event_info); static void ContextMenuHWBackKey(void* data, Evas_Object* obj, void* event_info); - ContextMenuControllerEfl(EWebView* wv, WebContents& web_contents) - : webview_(wv), - native_view_(static_cast(web_contents.GetNativeView())), - popup_(NULL), - menu_items_(NULL), - web_contents_(web_contents), - weak_ptr_factory_(this) { - } - + ContextMenuControllerEfl(EWebView* wv, WebContents& web_contents); ~ContextMenuControllerEfl(); bool PopulateAndShowContextMenu(const ContextMenuParams& params); @@ -129,13 +121,13 @@ class ContextMenuControllerEfl : public download::DownloadItem::Observer { Eina_List* menu_items_; ContextMenuParams params_; WebContents& web_contents_; - base::WeakPtrFactory weak_ptr_factory_; gfx::Point context_menu_show_pos_; bool is_text_selection_; std::set clipboard_download_items_; std::set disk_download_items_; std::unique_ptr file_saved_dialog_; std::unique_ptr save_fail_dialog_; + base::WeakPtrFactory weak_ptr_factory_; }; } // namespace diff --git a/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc b/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc index 1187d24..49caec4 100644 --- a/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc +++ b/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc @@ -68,8 +68,7 @@ class TCPServerSocketFactory : public content::DevToolsSocketFactory { namespace content { -DevToolsDelegateEfl::DevToolsDelegateEfl(int port) - : port_(0), browser_context_(NULL) { +DevToolsDelegateEfl::DevToolsDelegateEfl(int port) : port_(0) { // It's a hacky way to early detected if port is available. The problem is // that the only thing we can do after checking is hope that noone will take // the port until it's initialized on IO thread again. The best approach would diff --git a/tizen_src/ewk/efl_integration/devtools_delegate_efl.h b/tizen_src/ewk/efl_integration/devtools_delegate_efl.h index 9c68bb9..ceb8f42 100644 --- a/tizen_src/ewk/efl_integration/devtools_delegate_efl.h +++ b/tizen_src/ewk/efl_integration/devtools_delegate_efl.h @@ -11,7 +11,6 @@ namespace content { -class BrowserContext; class DevToolsHttpHandler; // This class is to create RemoteInspector Server(Remote Debugger) and return devtools front resources. @@ -39,7 +38,6 @@ class DevToolsDelegateEfl : public DevToolsManagerDelegate { private: int port_; - content::BrowserContext* browser_context_; std::unique_ptr devtools_http_handler_; }; diff --git a/tizen_src/ewk/efl_integration/eweb_view.cc b/tizen_src/ewk/efl_integration/eweb_view.cc index 7e4ed2f..a9f8e7b 100644 --- a/tizen_src/ewk/efl_integration/eweb_view.cc +++ b/tizen_src/ewk/efl_integration/eweb_view.cc @@ -1940,6 +1940,9 @@ bool EWebView::RestoreFromSessionData(const char* data, unsigned length) { if (!entryCount) return true; + if (!context()) + return false; + std::vector> scopedEntries = sessions::ContentSerializedNavigationBuilder::ToNavigationEntries( serializedEntries, context()->browser_context()); diff --git a/tizen_src/ewk/efl_integration/private/ewk_settings_private.h b/tizen_src/ewk/efl_integration/private/ewk_settings_private.h index d11756b..598e8f7 100644 --- a/tizen_src/ewk/efl_integration/private/ewk_settings_private.h +++ b/tizen_src/ewk/efl_integration/private/ewk_settings_private.h @@ -131,7 +131,6 @@ class Ewk_Settings { bool m_defaultKeypadEnabled; bool m_useKeyPadWithoutUserAction; bool m_textStyleState; - bool m_autoFitting; bool m_detectContentsAutomatically; Evas_Object* m_evas_object; diff --git a/tizen_src/ewk/efl_integration/private/ewk_user_media_private.cc b/tizen_src/ewk/efl_integration/private/ewk_user_media_private.cc index 76e6bcf..6c0f637 100644 --- a/tizen_src/ewk/efl_integration/private/ewk_user_media_private.cc +++ b/tizen_src/ewk/efl_integration/private/ewk_user_media_private.cc @@ -13,7 +13,9 @@ _Ewk_User_Media_Permission_Request::_Ewk_User_Media_Permission_Request( : web_contents_(web_contents), request_(media_request), callback_(std::move(callback)), - origin_(new _Ewk_Security_Origin(media_request.security_origin)) {} + origin_(new _Ewk_Security_Origin(media_request.security_origin)), + decided_(false), + suspended_(false) {} void _Ewk_User_Media_Permission_Request::ProceedPermissionCallback(bool allowed) { CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); diff --git a/tizen_src/ewk/efl_integration/public/ewk_view.cc b/tizen_src/ewk/efl_integration/public/ewk_view.cc index 4ae1287..9ab82e1 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_view.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_view.cc @@ -998,8 +998,9 @@ char* ewk_view_get_cookies_for_url(Evas_Object* view, const char* url) { EWK_VIEW_IMPL_GET_OR_RETURN(view, impl, 0); EINA_SAFETY_ON_NULL_RETURN_VAL(url, 0); - std::string cookiesForURL; - cookiesForURL = impl->context()->cookieManager()->GetCookiesForURL(std::string(url)); + EINA_SAFETY_ON_NULL_RETURN_VAL(impl->context(), 0); + std::string cookiesForURL = + impl->context()->cookieManager()->GetCookiesForURL(std::string(url)); if (cookiesForURL.empty()) return NULL; return strndup(cookiesForURL.c_str(), cookiesForURL.length()); diff --git a/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc b/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc index a960709..d0854a1 100644 --- a/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc +++ b/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc @@ -281,17 +281,17 @@ void URLRequestContextGetterEfl::SetCookieStoragePath( } DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); - // Remove below "false" this was added as part of M67 Brinup to avoid - // crash related to CreateSQLitePersistentCookieStore - if (file_storage == EWK_COOKIE_PERSISTENT_STORAGE_SQLITE -#if defined(EWK_BRINGUP) // FIXME: m67 bringup - && false -#endif - ) { + +// This was added as part of M67 Brinup to avoid crash related to +// CreateSQLitePersistentCookieStore. +#if !defined(EWK_BRINGUP) // FIXME: m67 bringup + if (file_storage == EWK_COOKIE_PERSISTENT_STORAGE_SQLITE) CreateSQLitePersistentCookieStore(path, persist_session_cookies); - } else { + else CreatePersistentCookieStore(path, persist_session_cookies); - } +#else + CreatePersistentCookieStore(path, persist_session_cookies); +#endif } void URLRequestContextGetterEfl::CreateSQLitePersistentCookieStore( diff --git a/tizen_src/ewk/efl_integration/web_contents_delegate_efl.cc b/tizen_src/ewk/efl_integration/web_contents_delegate_efl.cc index da3a827..b4e9d4c 100644 --- a/tizen_src/ewk/efl_integration/web_contents_delegate_efl.cc +++ b/tizen_src/ewk/efl_integration/web_contents_delegate_efl.cc @@ -98,13 +98,13 @@ WebContentsDelegateEfl::WebContentsDelegateEfl(EWebView* view) weak_ptr_factory_(this) { #if defined(TIZEN_AUTOFILL_SUPPORT) AutofillClientEfl::CreateForWebContents(&web_contents_); - AutofillClientEfl* autofill_manager = + AutofillClientEfl* autofill_client = AutofillClientEfl::FromWebContents(&web_contents_); - autofill_manager->SetEWebView(view); + autofill_client->SetEWebView(view); PasswordManagerClientEfl::CreateForWebContentsWithAutofillClient( - &web_contents_, autofill_manager); + &web_contents_, autofill_client); ContentAutofillDriverFactory::CreateForWebContentsAndDelegate( - &web_contents_, autofill_manager, EWebView::GetPlatformLocale(), + &web_contents_, autofill_client, EWebView::GetPlatformLocale(), AutofillManager::DISABLE_AUTOFILL_DOWNLOAD_MANAGER); #endif } diff --git a/tizen_src/ewk/efl_webview_app/app.c b/tizen_src/ewk/efl_webview_app/app.c index 49a6efe..98b1f4f 100644 --- a/tizen_src/ewk/efl_webview_app/app.c +++ b/tizen_src/ewk/efl_webview_app/app.c @@ -39,8 +39,8 @@ uint64_t current_notification_id; static Ewk_Auth_Challenge* auth_challenge_holder = NULL; static Evas_Object* credentials[2] = {0};//username and password -static Eina_Bool fullscreen_enabled; -static Eina_Bool clear_cache; +static Eina_Bool fullscreen_enabled = EINA_FALSE; +static Eina_Bool clear_cache = EINA_FALSE; static Eina_Bool disable_cache = EINA_FALSE; static char* pdf_filename = NULL; static char* cache_policy = NULL; @@ -456,7 +456,7 @@ int main(int argc, char** argv) int idx = ecore_getopt_parse(&options, values, argc, argv); for (; idx < argc; ++idx) { // Treat first argument not starting with - as the url to load - if (argv[idx][0] != '-') { + if (argv[idx][0] != '-' && start_url == NULL) { start_url = strdup(argv[idx]); } else if (strcmp(argv[idx], "--incognito") == 0) { incognito = EINA_TRUE; @@ -486,13 +486,6 @@ int main(int argc, char** argv) ecore_evas_callback_delete_request_set(ee, _evas_close_cb); -#if defined(OS_TIZEN) - // Ignore fullscreen option, we should always go fullscreen on device. - Eina_Bool use_fullscreen = EINA_TRUE; -#else - Eina_Bool use_fullscreen = fullscreen_enabled; -#endif - if (incognito == EINA_TRUE) { fprintf(stderr, "Creating incognito web view\n"); view = ewk_view_add_in_incognito_mode(e); @@ -502,13 +495,18 @@ int main(int argc, char** argv) view = ewk_view_add_with_context(e, context); } - if (use_fullscreen) { - ecore_evas_fullscreen_set(ee, EINA_TRUE); +#if defined(OS_TIZEN) + // we should always go fullscreen on device. + ecore_evas_fullscreen_set(ee, EINA_TRUE); +#else + if (fullscreen_enabled) { // When in fullscreen, we don't need to manually specify the dimensions of // EwkView. + ecore_evas_fullscreen_set(ee, EINA_TRUE); } else { evas_object_resize(view, width, height); } +#endif ecore_evas_callback_resize_set(ee, &on_evas_resize); -- 2.7.4 From bb338a28df06f54e05eb0a502550211189c28d1c Mon Sep 17 00:00:00 2001 From: Chandan Padhi Date: Thu, 5 Mar 2020 15:27:33 +0530 Subject: [PATCH 13/16] [Coverity] Fix coverity defects This commit also includes changes from https://review.tizen.org/gerrit/#/c/213680/. Change-Id: Iccccadb1cf718bd102ab51e80a656cec87416107 Signed-off-by: Chandan Padhi --- .../browser/ssl_host_state_delegate_efl.cc | 22 +++------------- .../browser/ssl_host_state_delegate_efl.h | 5 +--- .../ewk/efl_integration/devtools_delegate_efl.cc | 4 +-- .../renderer/print_web_view_helper_efl.cc | 12 ++++++--- .../url_request_context_getter_efl.cc | 18 +++++++------ .../ewk/efl_integration/wrt/wrt_widget_host.cc | 7 ++++- tizen_src/ewk/ubrowser/logger.cc | 30 ++++++++++------------ 7 files changed, 44 insertions(+), 54 deletions(-) diff --git a/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.cc b/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.cc index 2a1935e3..9375715 100644 --- a/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.cc +++ b/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.cc @@ -11,16 +11,6 @@ using content::SSLHostStateDelegate; namespace content { namespace internal { -net::SHA256HashValue getChainFingerprint256(const net::X509Certificate& cert) { -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup - net::SHA256HashValue fingerprint = - net::X509Certificate::CalculateChainFingerprint256( - cert.os_cert_handle(), cert.GetIntermediateCertificates()); -#else - net::SHA256HashValue fingerprint; -#endif - return fingerprint; -} CertPolicy::CertPolicy() { } @@ -33,16 +23,13 @@ CertPolicy::~CertPolicy() { // in the saved CertStatus. bool CertPolicy::Check(const net::X509Certificate& cert, net::CertStatus error) const { -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup - net::SHA256HashValue fingerprint = getChainFingerprint256(cert); - std::map::const_iterator allowed_iter = + net::SHA256HashValue fingerprint = cert.CalculateChainFingerprint256(); + std::map::const_iterator allowed_iter = allowed_.find(fingerprint); if ((allowed_iter != allowed_.end()) && (allowed_iter->second & error) && ((allowed_iter->second & error) == error)) { return true; } -#endif return false; } @@ -50,10 +37,8 @@ void CertPolicy::Allow(const net::X509Certificate& cert, net::CertStatus error) { // If this same cert had already been saved with a different error status, // this will replace it with the new error status. -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup - net::SHA256HashValue fingerprint = getChainFingerprint256(cert); + net::SHA256HashValue fingerprint = cert.CalculateChainFingerprint256(); allowed_[fingerprint] = error; -#endif } } // namespace internal @@ -106,7 +91,6 @@ void SSLHostStateDelegateEfl::RevokeUserAllowExceptions( } bool SSLHostStateDelegateEfl::HasAllowException(const std::string& host) const { - NOTIMPLEMENTED(); return false; } diff --git a/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.h b/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.h index b3a19fb2..5e9992d 100644 --- a/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.h +++ b/tizen_src/ewk/efl_integration/browser/ssl_host_state_delegate_efl.h @@ -32,10 +32,7 @@ class CertPolicy { private: // The set of fingerprints of allowed certificates. -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup - std::map - allowed_; -#endif + std::map allowed_; }; } // namespace internal diff --git a/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc b/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc index 49caec4..c88678c 100644 --- a/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc +++ b/tizen_src/ewk/efl_integration/devtools_delegate_efl.cc @@ -86,8 +86,8 @@ DevToolsDelegateEfl::DevToolsDelegateEfl(int port) : port_(0) { int temp_port = 0; std::string port_str = command_line->GetSwitchValueASCII(switches::kRemoteDebuggingPort); - base::StringToInt(port_str, &temp_port); - if (temp_port > 0 && temp_port < 65535) { + if (base::StringToInt(port_str, &temp_port) && (temp_port > 0) && + (temp_port < 65535)) { port = temp_port; } else { DLOG(WARNING) << "Invalid http debugger port number " << temp_port; diff --git a/tizen_src/ewk/efl_integration/renderer/print_web_view_helper_efl.cc b/tizen_src/ewk/efl_integration/renderer/print_web_view_helper_efl.cc index a68026b..67d494d 100644 --- a/tizen_src/ewk/efl_integration/renderer/print_web_view_helper_efl.cc +++ b/tizen_src/ewk/efl_integration/renderer/print_web_view_helper_efl.cc @@ -116,7 +116,9 @@ bool PrintWebViewHelperEfl::RenderPagesForPrint(blink::WebFrame* frame) { const PrintParams& print_params = params.params; blink::WebPrintParams webkit_print_params; ComputeWebKitPrintParamsInDesiredDpi(print_params, &webkit_print_params); -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup +#if defined(EWK_BRINGUP) // FIXME: m67 bringup + return false; +#else int page_count = frame->printBegin(webkit_print_params); gfx::Size print_canvas_size(webkit_print_params.printContentArea.width, webkit_print_params.printContentArea.height); @@ -128,7 +130,9 @@ bool PrintWebViewHelperEfl::RenderPagesForPrint(blink::WebFrame* frame) { bool PrintWebViewHelperEfl::PrintPagesToPdf(blink::WebFrame* frame, int page_count, const gfx::Size& canvas_size) { -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup +#if defined(EWK_BRINGUP) // FIXME: m67 bringup + return false; +#else printing::PdfMetafileSkia metafile(printing::PDF_SKIA_DOCUMENT_TYPE); if (!metafile.Init()) return false; @@ -200,7 +204,9 @@ bool PrintWebViewHelperEfl::PrintPageInternal( PrintParams result; double scale_factor = 1.0f; gfx::Rect canvas_area(canvas_size); -#if !defined(EWK_BRINGUP) // FIXME: m67 bringup +#if defined(EWK_BRINGUP) // FIXME: m67 bringup + return false; +#else // FIXME: cannot convert ‘cc::PaintCanvas*’ to ‘skia::VectorCanvas* {aka // SkCanvas*}’ in initialization skia::VectorCanvas* canvas = metafile->GetVectorCanvasForNewPage( diff --git a/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc b/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc index d0854a1..9f37947 100644 --- a/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc +++ b/tizen_src/ewk/efl_integration/url_request_context_getter_efl.cc @@ -195,17 +195,19 @@ net::URLRequestContext* URLRequestContextGetterEfl::GetURLRequestContext() { ignore_certificate_errors_; if (command_line.HasSwitch(switches::kTestingFixedHttpPort)) { int value; - base::StringToInt( - command_line.GetSwitchValueASCII(switches::kTestingFixedHttpPort), - &value); - network_session_params.testing_fixed_http_port = value; + if (base::StringToInt( + command_line.GetSwitchValueASCII(switches::kTestingFixedHttpPort), + &value)) { + network_session_params.testing_fixed_http_port = value; + } } if (command_line.HasSwitch(switches::kTestingFixedHttpsPort)) { int value; - base::StringToInt( - command_line.GetSwitchValueASCII(switches::kTestingFixedHttpsPort), - &value); - network_session_params.testing_fixed_https_port = value; + if (base::StringToInt(command_line.GetSwitchValueASCII( + switches::kTestingFixedHttpsPort), + &value)) { + network_session_params.testing_fixed_https_port = value; + } } http_network_session_.reset(new net::HttpNetworkSession( diff --git a/tizen_src/ewk/efl_integration/wrt/wrt_widget_host.cc b/tizen_src/ewk/efl_integration/wrt/wrt_widget_host.cc index 5f75ddd..d57a495 100644 --- a/tizen_src/ewk/efl_integration/wrt/wrt_widget_host.cc +++ b/tizen_src/ewk/efl_integration/wrt/wrt_widget_host.cc @@ -34,7 +34,12 @@ bool SendToAllRenderers(IPC::Message* message) { } bool SendToRenderer(int renderer_id, IPC::Message* message) { - return content::RenderProcessHost::FromID(renderer_id)->Send(message); + content::RenderProcessHost* host = + content::RenderProcessHost::FromID(renderer_id); + if (!host) + return false; + + return host->Send(message); } } diff --git a/tizen_src/ewk/ubrowser/logger.cc b/tizen_src/ewk/ubrowser/logger.cc index e2c38fb..373619e 100644 --- a/tizen_src/ewk/ubrowser/logger.cc +++ b/tizen_src/ewk/ubrowser/logger.cc @@ -92,26 +92,25 @@ _make_format(MESSAGE_TYPE type, int add_newline, const char* fmt) { void log_message(MESSAGE_TYPE type, int add_newline, const char* fmt, ...) { - char* msg_fmt = NULL; - va_list list; - - if (!logger_show_trace && type == TRACE) { + if (!logger_show_trace && type == TRACE) return; - } - msg_fmt = _make_format(type, add_newline, fmt); + char* msg_fmt = _make_format(type, add_newline, fmt); + va_list list; va_start(list, fmt); if (msg_fmt == NULL) { vfprintf(stderr, fmt, list); + va_end(list); + return; } - if (type == ERROR) { + if (type == ERROR) vfprintf(stderr, msg_fmt, list); - } else { + else vfprintf(stdout, msg_fmt, list); - } + va_end(list); free(msg_fmt); @@ -119,23 +118,20 @@ log_message(MESSAGE_TYPE type, int add_newline, const char* fmt, ...) { void vlog_message(MESSAGE_TYPE type, int add_newline, const char* fmt, va_list vl) { - char* msg_fmt = NULL; - - if (!logger_show_trace && type == TRACE) { + if (!logger_show_trace && type == TRACE) return; - } - msg_fmt = _make_format(type, add_newline, fmt); + char* msg_fmt = _make_format(type, add_newline, fmt); if (msg_fmt == NULL) { vfprintf(stderr, fmt, vl); + return; } - if (type == ERROR) { + if (type == ERROR) vfprintf(stderr, msg_fmt, vl); - } else { + else vfprintf(stdout, msg_fmt, vl); - } free(msg_fmt); } -- 2.7.4 From c77a868f275403099a259efd43faef32c6eb9b41 Mon Sep 17 00:00:00 2001 From: Youngsoo Choi Date: Tue, 2 Jun 2020 16:10:27 +0900 Subject: [PATCH 14/16] Enable dev build with the latest repo This patch is to support initial build. - Fix build issue caused by the latest platform ninja - Provide build option --tizen_5.5 for upgradable web engine - Refactor common.sh and gn_chromiumefl.sh - Remove dependency of openssl, print, and pulse - Update gbs.conf with the latest - Use costomized job number for ninja build - Use platform gcc version in build time - Use system icu for public profile Change-Id: I2fdb92e074fac3dfec406c159c6184cf7136f59f Signed-off-by: Youngsoo Choi --- .gitignore | 1 + media/media_options.gni | 2 +- packaging/chromium-efl.spec | 21 +- third_party/blink/renderer/core/dom/document.cc | 2 +- third_party/harfbuzz-ng/src/src/hb-icu.cc | 2 +- tizen_src/build/common.sh | 213 +++-- tizen_src/build/config/compiler/BUILD.gn | 4 +- tizen_src/build/config/tizen_features.gni | 1 + tizen_src/build/gbs.conf | 1044 ----------------------- tizen_src/build/gbs.conf.in | 202 +++++ tizen_src/build/gn_chromiumefl.sh | 111 ++- 11 files changed, 439 insertions(+), 1164 deletions(-) delete mode 100755 tizen_src/build/gbs.conf create mode 100755 tizen_src/build/gbs.conf.in diff --git a/.gitignore b/.gitignore index c47ffec..232e336 100644 --- a/.gitignore +++ b/.gitignore @@ -258,6 +258,7 @@ vs-chromium-project.txt /sync_testserver.log /testing/libfuzzer/fuzzer_corpus_for_bots/ /testserver.log +/tizen_src/build/gbs.conf # See third_party/.gitignore for entries covering src/third_party. /tools/.bisect-builds-cache.json /tools/cygprofile/*.wprgo diff --git a/media/media_options.gni b/media/media_options.gni index 6e04076..cf4d3d1 100644 --- a/media/media_options.gni +++ b/media/media_options.gni @@ -117,7 +117,7 @@ declare_args() { use_alsa = true # Pulse is not supported on Chromecast platforms. - if (!use_cras && !is_chromecast) { + if (!use_cras && !is_chromecast && !is_tizen) { use_pulseaudio = true } } diff --git a/packaging/chromium-efl.spec b/packaging/chromium-efl.spec index f4c6245..b5fc91b 100644 --- a/packaging/chromium-efl.spec +++ b/packaging/chromium-efl.spec @@ -24,10 +24,23 @@ Source1: content_shell.in %define _debug_mode 1 %endif +# Do not use the hardcoded CPU numbers such as "jobs 20" or "_smp_mflags -j20" +# . The below statement is compatible with RPM 4.4.2.1+. +# . /usr/bin/getconf depends on the libc-common (or libc-bin) base package. +%if "%{?_costomized_smp_mflags}" != "" +%define _smp_mflags %{_costomized_smp_mflags} +%else %define _smp_mflags -j%(echo $((`/usr/bin/getconf _NPROCESSORS_ONLN` / 2))) +%endif %define tizen_version %{tizen_version_major}%{tizen_version_minor} +%{?_use_system_icu: %define __use_system_icu %{_use_system_icu}} +# Product tv can't utilize system icu due to nacl dependency. +%if "%{?profile}" != "tv" && %{tizen_version} == 60 && %{?_use_system_icu: 0}%{!?_use_system_icu: 1} +%define __use_system_icu 1 +%endif + Requires: /usr/bin/systemctl Requires(post): /sbin/ldconfig Requires(post): xkeyboard-config @@ -81,7 +94,6 @@ BuildRequires: pkgconfig(minizip) BuildRequires: pkgconfig(mm-player) BuildRequires: pkgconfig(nspr) BuildRequires: pkgconfig(nss) -BuildRequires: pkgconfig(openssl) BuildRequires: pkgconfig(scim) BuildRequires: pkgconfig(security-manager) BuildRequires: pkgconfig(sqlite3) @@ -143,7 +155,7 @@ BuildRequires: binutils-gold %define ARCHITECTURE x86_64 %endif -%if ("%{?tizen_profile_name}" == "tv" && "%{?_clang}" == "1") || ("%{?tizen_profile_name}" != "tv" && "%{?_gcc}" != "1" && "%{ARCHITECTURE}" == "armv7l") +%if "%{?_clang}" == "1" && "%{ARCHITECTURE}" == "armv7l" %define __use_clang 1 %else %define __use_clang 0 @@ -288,6 +300,11 @@ fi %else "is_clang=false" \ %endif +%if "%{?__use_system_icu}" == "1" + "use_system_icu=true" \ +%else + "use_system_icu=false" \ +%endif %endif # _skip_gn ninja %{_smp_mflags} -C "%{OUTPUT_FOLDER}" \ diff --git a/third_party/blink/renderer/core/dom/document.cc b/third_party/blink/renderer/core/dom/document.cc index 7e782a2..8bdb4ad 100644 --- a/third_party/blink/renderer/core/dom/document.cc +++ b/third_party/blink/renderer/core/dom/document.cc @@ -5632,7 +5632,7 @@ static ParseQualifiedNameResult ParseQualifiedNameInternal( for (unsigned i = 0; i < length;) { UChar32 c; - U16_NEXT(characters, i, length, c) + U16_NEXT(characters, i, length, c); if (c == ':') { if (saw_colon) return ParseQualifiedNameResult(kQNMultipleColons); diff --git a/third_party/harfbuzz-ng/src/src/hb-icu.cc b/third_party/harfbuzz-ng/src/src/hb-icu.cc index 399829a..5238056 100644 --- a/third_party/harfbuzz-ng/src/src/hb-icu.cc +++ b/third_party/harfbuzz-ng/src/src/hb-icu.cc @@ -51,7 +51,7 @@ /* ICU doesn't do-while(0) around their statements. Ugh! * https://unicode-org.atlassian.net/browse/CLDR-13027 */ -#define HB_ICU_STMT(S) do { S } while (0) +#define HB_ICU_STMT(S) do { S; } while (0) hb_script_t hb_icu_script_to_script (UScriptCode script) diff --git a/tizen_src/build/common.sh b/tizen_src/build/common.sh index b1cf646..5b214a8 100755 --- a/tizen_src/build/common.sh +++ b/tizen_src/build/common.sh @@ -3,26 +3,59 @@ export SCRIPTDIR=$(readlink -e $(dirname $0)) export TOPDIR=$(readlink -f "${SCRIPTDIR}/../..") export CHROME_SRC="${TOPDIR}" -# Please set DEFAULT_TIZEN_VERSION to 'latest' for the latest tizen version -# or set DEFAULT_TIZEN_VERSION to current tizen version for the others. -export DEFAULT_TIZEN_VERSION=latest +export LATEST_TIZEN_VERSION=6.0 +export DEFAULT_TIZEN_VERSION=$LATEST_TIZEN_VERSION if [ "$(echo "$@" | grep -e "--tizen")" != "" ]; then tizen_version=$(echo $@ | sed -e 's#.*--tizen_\([0-9.]*\).*#\1#') - if $(echo $tizen_version | grep -qe "^[-\?[0-9]\+\.\?[0-9]*$" && echo true || echo false); then - DEFAULT_TIZEN_VERSION=$tizen_version - else - DEFAULT_TIZEN_VERSION=latest - fi + DEFAULT_TIZEN_VERSION=$tizen_version fi +# Generate gbs.conf +export REPO_VERSION= +if [ "$DEFAULT_TIZEN_VERSION" != "${LATEST_TIZEN_VERSION}" ]; then + REPO_VERSION=$DEFAULT_TIZEN_VERSION- +fi +sed -e "s/@TIZEN_VERSION@/$REPO_VERSION/g" \ + tizen_src/build/gbs.conf.in > tizen_src/build/gbs.conf + +function getSystemDeps() { + local host_arch=$(getHostArch) + local platform=$1 + local system_deps="--system-libraries + libevent + libpng + libxml + libxslt + zlib + " + # Tizen profile + if [ "$platform" != "desktop" ]; then + # Emulator profile + if [ "$host_arch" == "x86" -o "$host_arch" == "x64" ]; then + system_deps+="libjpeg + " + fi + # Non product tv profiles on tizen 6.0 + if [ "$platform" != "tv" -a "$DEFAULT_TIZEN_VERSION" == "6.0" ]; then + system_deps+="icu + " + fi + fi + echo $system_deps +} + function getHostOs() { echo $(uname -s | sed -e 's/Linux/linux/;s/Darwin/mac/') } function getHostArch() { echo $(uname -m | sed -e \ - 's/i.86/ia32/;s/x86_64/x64/;s/amd64/x64/;s/arm.*/arm/;s/i86pc/ia32/;s/aarch64/arm64/') + 's/i.86/x86/;s/x86_64/x64/;s/amd64/x64/;s/arm.*/arm/;s/i86pc/x86/;s/aarch64/arm64/') +} + +function getGccVersion() { + echo $(gcc -dumpversion) } function getPythonVersion() { @@ -39,7 +72,6 @@ function setIfUndef() { fi } - function hostBuldScriptUsage() { cat << EOF usage: $1 [OPTIONS] @@ -63,8 +95,17 @@ EOF exit } -function parseHostBuildScriptParams() { +function undoReplacedGn() { + local system_deps=$(getSystemDeps $1) + if [ "$system_deps" != "" ]; then + echo "** use system lib : undo **" + # Restore gn files to their original states not to mess up the tree permanently. + $TOPDIR/build/linux/unbundle/replace_gn_files.py --undo $system_deps icu + fi +} +function parseHostBuildScriptParams() { + trap 'undoReplacedGn $1' SIGINT export USE_CCACHE=0 export USE_CLANG=1 export FORCE_JHBUILD=0 @@ -153,6 +194,7 @@ function hostNinja() { BUILDDIR=${GN_GENERATOR_OUTPUT}/${BUILD_SUBDIRECTORY} ninja -C $BUILDDIR ${JOBS} ${TARGETS} fi + undoReplacedGn $1 } function error_report() { @@ -177,11 +219,11 @@ function setupAndExecuteTargetBuild() { local CONF_FLAG local -a ARGS - local count=0 local exclusive_options=0 local RPMLINT=0 local NOINIT=0 local MIRROR=0 + local LOCAL_BUILD=1 # "|| :" means "or always succeeding built-in command" PROFILE=$(echo "$@" | grep -Po "(?<=\-P\s)[^\s]*" | head -1 || :) @@ -189,103 +231,88 @@ function setupAndExecuteTargetBuild() { GBS_ROOT=$(echo "$@" | grep -Po "(?<=\-B\s)[^\s]*" | head -1 || :) while [[ $# > 0 ]]; do - count=$(( $count + 1 )) case "$1" in --debug) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_debug_mode 1" + ARGS+=(--define "_debug_mode 1") ;; --skip-ninja) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_skip_ninja 1" + ARGS+=(--define "_skip_ninja 1") ;; --skip-gn) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_skip_gn 1" + ARGS+=(--define "_skip_gn 1") ;; --component-build) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="component_build 1" + ARGS+=(--define "component_build 1") + ;; + --disable-wrtjs) + ARGS+=(--define "_disable_wrt_js 1") ;; --gbs-debug) - ARGS[$count]=--debug + ARGS+=(--debug) + ;; + --icu=*) + ARGS+=(--define "_use_system_icu $(echo $1 | sed -e 's/--icu=//g')") ;; --rpmlint) RPMLINT=1 - count=$(( $count + 1 )) ;; --nodebug) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_nodebug 1" + ARGS+=(--define "_nodebug 1") ;; --noinit) NOINIT=1 - ARGS[$count]="$1" - count=$(( $count + 1 )) + ARGS+=("$1") ;; --mirror) MIRROR=1 ;; + --release) + LOCAL_BUILD=0 + ARGS+=(--define "_local_build 0") + ARGS+=(--define "_clang 0") + ;; --gcc) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_gcc 1" + LOCAL_BUILD=0 + ARGS+=(--define "_clang 0") ;; --clang) - ARGS[$count]=--define - count=$(( $count + 1 )) - ARGS[$count]="_clang 1" + LOCAL_BUILD=0 + ARGS+=(--define "_clang 1") ;; --standard*) - if [ "$DEFAULT_TIZEN_VERSION" == "latest" ]; then - echo $1 - PROFILE=tz_$(echo $1 | sed 's/--//g') - elif [ "$DEFAULT_TIZEN_VERSION" == "4.0" ]; then - PROFILE=tz_${DEFAULT_TIZEN_VERSION}_$(echo $1 | sed 's/--//g')_$(echo $ARCHITECTURE | grep "i586" -q && echo "ia32" || echo $ARCHITECTURE) - else - PROFILE=tz_${DEFAULT_TIZEN_VERSION}_$(echo $1 | sed 's/--//g') - fi + PROFILE=tz_$(echo $1 | sed 's/--//g') ;; --emulator*) - if [ "$DEFAULT_TIZEN_VERSION" == "latest" ]; then - PROFILE=tz_$(echo $1 | sed 's/--//g') - elif [ "$DEFAULT_TIZEN_VERSION" == "4.0" ]; then - PROFILE=tz_${DEFAULT_TIZEN_VERSION}_$(echo $1 | sed 's/--//g')_$(echo $ARCHITECTURE | grep "i586" -q && echo "ia32" || echo $ARCHITECTURE) - else - PROFILE=tz_${DEFAULT_TIZEN_VERSION}_$(echo $1 | sed 's/--//g') - fi + PROFILE=tz_$(echo $1 | sed 's/--//g') ;; --tizen*) ;; *) - ARGS[$count]="$1" + ARGS+=("$1") ;; esac shift; done + if [ "$LOCAL_BUILD" == "1" ]; then + ARGS+=(--define "_local_build 1") + local _jobs=$((`/usr/bin/getconf _NPROCESSORS_ONLN` / 2 - `ps -ef | grep " ninja " | wc -l` -1)) + local _smp_mflags=-j$(if ((${_jobs} > 10)); then echo ${_jobs}; else echo 10; fi) + ARGS+=(--define "_costomized_smp_mflags $_smp_mflags") + # Default values + if [[ $platform == "tv" ]]; then + ARGS+=(--define "_clang 0") + else + ARGS+=(--define "_clang 1") + fi + fi if [ "$PROFILE" == "" ]; then - if [[ $platform == "mobile" ]]; then - PROFILE=tzmb_3.0_target-TM1 - elif [[ $platform == "tv" ]]; then - if [ "$DEFAULT_TIZEN_VERSION" == "latest" ]; then - PROFILE=tztv_5.5_arm-musem - elif [ "$DEFAULT_TIZEN_VERSION" == "4.0" ]; then - PROFILE=tztv_4.0_arm-kantm - else - PROFILE=tztv_arm-musem - fi + if [[ $platform == "tv" ]]; then + PROFILE=tztv_${DEFAULT_TIZEN_VERSION}_arm-nikem elif [[ $platform == "da" ]]; then - if [ "$DEFAULT_TIZEN_VERSION" == "latest" ]; then - PROFILE=tzda_arm-kantm - else - PROFILE=tzda_${DEFAULT_TIZEN_VERSION}_arm-kantm - fi + PROFILE=tzda_${DEFAULT_TIZEN_VERSION}_arm-kantm + elif [[ $platform == "wearable" ]]; then + PROFILE=tzwr_5.5_arm-spin else echo "Cannot set default PROFILE for platform=${platform}" exit 1 @@ -299,22 +326,11 @@ function setupAndExecuteTargetBuild() { echo "Set the profile : $PROFILE" if [ "$ARCHITECTURE" == "" ]; then - if [[ $platform == "mobile" ]]; then - ARCHITECTURE=armv7l - elif [[ $platform == "mobile_emulator" ]]; then - ARCHITECTURE=i586 - elif [[ $platform == "tv" ]]; then - ARCHITECTURE=armv7l - elif [[ $platform == "tv_emulator" ]]; then - ARCHITECTURE=i586 - else - echo "Cannot set default ARCHITECTURE for platform=${platform}" - exit 1 - fi + ARCHITECTURE=armv7l fi echo "Set the architecture : $ARCHITECTURE" - if [ "$(echo "${PROFILE}" | grep -P "muse|kant|jazz|hawk|product")" == "" -a "$NOINIT" == 0 ]; then + if [ "$(echo "${PROFILE}" | grep -P "tz_standard")" != "" -a "$NOINIT" == 0 ]; then processRpmlintOption $PROFILE $RPMLINT fi local BRANCH=$(echo $(basename $(git symbolic-ref HEAD))) @@ -337,7 +353,34 @@ function setupAndExecuteTargetBuild() { fi fi + processICU initialize_icu gbs $CONF_FLAG build -P $PROFILE --include-all -A $ARCHITECTURE "${ARGS[@]}" $BUILD_CONF_OPTS --incremental $GBS_ROOT_OPT + + undoReplacedGn $platform + processICU restore_icu +} + +function processICU() { + local ICU_PATH="$TOPDIR/third_party/icu/source" + local ICU_REPLACE_PATH="$TOPDIR/third_party/icu/source_replace" + + if [ "$1" == "replace_icu" ]; then + if [ ! -e $ICU_REPLACE_PATH ] && [ -e $ICU_PATH ]; then + echo "** third_party/icu/source is replaced to use system icu." + mv $ICU_PATH $ICU_REPLACE_PATH + fi + elif [ "$1" == "restore_icu" ]; then + if [ -e $ICU_REPLACE_PATH ] && [ ! -e $ICU_PATH ]; then + echo "** third_party/icu/source is restored." + mv $ICU_REPLACE_PATH $ICU_PATH + fi + elif [ "$1" == "initialize_icu" ]; then + if [ -e $ICU_REPLACE_PATH ]; then + echo "** third_party/icu/source is initialized." + rm -rf $ICU_PATH + mv $ICU_REPLACE_PATH $ICU_PATH + fi + fi } function processRpmlintOption() { @@ -365,7 +408,7 @@ function processRpmlintOption() { mkdir $BUILD_CONF_DIR URL_TARGET=$(echo $PROFILE | sed -e 's#.*\.[0-9]*_\([-a-zA-Z0-9]*\).*#\1#;s/tz_//g') # The latest version doesn't have tizen version in snapshot repository url. - if [ "$(echo $DEFAULT_TIZEN_VERSION)" == "latest" ]; then + if [ "$DEFAULT_TIZEN_VERSION" == "${LATEST_TIZEN_VERSION}" ]; then URL_TIZEN_VERSION= else URL_TIZEN_VERSION=$DEFAULT_TIZEN_VERSION- @@ -382,6 +425,10 @@ function processRpmlintOption() { fi gunzip $BUILD_CONF_DIR/$BUILD_CONF_GZ sed -i 's/rpmlint-mini\ rpmlint-tizen/!rpmlint-mini\ !rpmlint-tizen/g' $BUILD_CONF_DIR/$BUILD_CONF + if [ "$DEFAULT_TIZEN_VERSION" == "6.0" ]; then + sed -i 's/tizen_version_major 5/tizen_version_major 6/g' $BUILD_CONF_DIR/$BUILD_CONF + sed -i 's/tizen_version_minor 5/tizen_version_minor 0/g' $BUILD_CONF_DIR/$BUILD_CONF + fi BUILD_CONF_OPTS="-D $BUILD_CONF_DIR/$BUILD_CONF" if [ "$PREVIOUS_RPMLINT" == "rpmlint" ]; then echo "** Once built with rpmlint" diff --git a/tizen_src/build/config/compiler/BUILD.gn b/tizen_src/build/config/compiler/BUILD.gn index 5b420e5..c2e3af3 100644 --- a/tizen_src/build/config/compiler/BUILD.gn +++ b/tizen_src/build/config/compiler/BUILD.gn @@ -130,8 +130,8 @@ config("tizen_default_include_dirs") { if (is_clang) { include_dirs += [ "$tizen_clang_base_path/lib/clang/7.0.0/include", - "$deps_lib_path/gcc/armv7l-tizen-linux-gnueabi/6.2.1/include/c++", - "$deps_lib_path/gcc/armv7l-tizen-linux-gnueabi/6.2.1/include/c++/armv7l-tizen-linux-gnueabi", + "$deps_lib_path/gcc/armv7l-tizen-linux-gnueabi/$gcc_ver/include/c++", + "$deps_lib_path/gcc/armv7l-tizen-linux-gnueabi/$gcc_ver/include/c++/armv7l-tizen-linux-gnueabi", ] } } diff --git a/tizen_src/build/config/tizen_features.gni b/tizen_src/build/config/tizen_features.gni index 07aa92d..d54a605 100644 --- a/tizen_src/build/config/tizen_features.gni +++ b/tizen_src/build/config/tizen_features.gni @@ -9,6 +9,7 @@ declare_args() { use_wayland = false + gcc_ver = "" python_ver = "2.5" # no use of this variable, if removing then revome from gn_chromiumefl.sh also depth = "" # no use of this variable, if removing then revome from gn_chromiumefl.sh also diff --git a/tizen_src/build/gbs.conf b/tizen_src/build/gbs.conf deleted file mode 100755 index 200629c..0000000 --- a/tizen_src/build/gbs.conf +++ /dev/null @@ -1,1044 +0,0 @@ -############################################### -# -# Tizen v5.0 public unified -# -[obs.tizen] -url = https://api.tizen.org - -[repo.tz_standard] -url = http://download.tizen.org/snapshots/tizen/unified/latest/repos/standard/packages/ - -[repo.tz_standard_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/unified/latest/repos/standard/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tz_emulator] -url = http://download.tizen.org/snapshots/tizen/unified/latest/repos/emulator/packages/ - -[repo.tz_emulator_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/unified/latest/repos/emulator/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.public_5.0_base_standard] -url = http://download.tizen.org/snapshots/tizen/base/latest/repos/standard/packages/ - -[repo.public_5.0_base_standard_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/base/latest/repos/standard/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v5.0 spin -# -[obs.spin] -url = http://10.113.136.204:81 - -[repo.tz_standard_armv7hl] -url = http://10.113.136.32/download/newlive/devel:/Toolchains:/Unified:/ref:/hardfp/standard -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.spin_5.0_base_armv7hl] -url = http://10.113.136.32/download/newlive/devel:/Toolchains:/Base:/ref:/hardfp/standard -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v5.0 spin (armv7hl) -# -[profile.tz_standard_armv7hl] -obs = obs.spin -repos = repo.spin_5.0_base_armv7hl, repo.tz_standard_armv7hl -buildroot = ~/GBS-ROOT-5.0-STANDARD-ARMV7HL - -############################################### -# -# Tizen v5.0 public standard -# -[profile.tz_standard] -obs = obs.tizen -repos = repo.public_5.0_base_standard, repo.tz_standard -buildroot = ~/GBS-ROOT-5.0-STANDARD - -############################################### -# -# Tizen v5.0 public standard, Mirroring Server for HQ developers -# -[profile.tz_standard_mirror] -obs = obs.tizen -repos = repo.public_5.0_base_standard_mirror, repo.tz_standard_mirror -buildroot = ~/GBS-ROOT-5.0-STANDARD - -############################################### -# -# Tizen v5.0 public emulator -# -[profile.tz_emulator] -obs = obs.tizen -repos = repo.public_5.0_base_standard, repo.tz_emulator -buildroot = ~/GBS-ROOT-5.0-EMULATOR - -############################################### -# -# Tizen v5.0 public emulator, Mirroring Server for HQ developers -# -[profile.tz_emulator_mirror] -obs = obs.tizen -repos = repo.public_5.0_base_standard, repo.tz_emulator_mirror -buildroot = ~/GBS-ROOT-5.0-EMULATOR - -############################################### -# -# Tizen v4.0 unified -# -[obs.tizen_4.0] -url = https://api.tizen.org - -[repo.tz_4.0_standard] -url = http://download.tizen.org/snapshots/tizen/4.0-unified/latest/repos/standard/packages/ - -[repo.tz_4.0_standard_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-unified/latest/repos/standard/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tz_4.0_emulator] -url = http://download.tizen.org/snapshots/tizen/4.0-unified/latest/repos/emulator/packages/ - -[repo.tz_4.0_emulator_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-unified/latest/repos/emulator/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.public_4.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/4.0-base/latest/repos/arm/packages/ - -[repo.public_4.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.public_4.0_base_arm64] -url = http://download.tizen.org/snapshots/tizen/4.0-base/latest/repos/arm64/packages/ - -[repo.public_4.0_base_arm64_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/arm64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.public_4.0_base_ia32] -url = http://download.tizen.org/snapshots/tizen/4.0-base/latest/repos/ia32/packages/ - -[repo.public_4.0_base_ia32_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/ia32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.public_4.0_base_x86_64] -url = http://download.tizen.org/snapshots/tizen/4.0-base/latest/repos/x86_64/packages/ - -[repo.public_4.0_base_x86_64_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/x86_64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v4.0 spin -# -[obs.spin] -url = http://10.113.136.204:81 - -[repo.tz_4.0_standard_armv7hl] -url = http://10.113.136.32/download/newlive/devel:/Toolchains:/Unified:/ref:/hardfp/standard -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.spin_4.0_base_armv7hl] -url = http://10.113.136.32/download/newlive/devel:/Toolchains:/Base:/ref:/hardfp/standard -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v4.0 for spin (armv7hl) -# -[profile.tz_4.0_standard_armv7hl] -obs = obs.spin -repos = repo.spin_4.0_base_armv7hl, repo.tz_4.0_standard_armv7hl -buildroot = ~/GBS-ROOT-4.0-STANDARD-ARMV7HL - -############################################### -# -# Tizen v4.0 for standard (armv7l) -# -[profile.tz_4.0_standard_armv7l] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_arm, repo.tz_4.0_standard -buildroot = ~/GBS-ROOT-4.0-STANDARD-ARMV7L - -############################################### -# -# Tizen v4.0 for standard (armv7l), Mirroring Server for HQ developers -# -[profile.tz_4.0_standard_armv7l_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_arm_mirror, repo.tz_4.0_standard_mirror -buildroot = ~/GBS-ROOT-4.0-STANDARD-ARMV7L - -############################################### -# -# Tizen v4.0 for standard (aarch64) -# -[profile.tz_4.0_standard_aarch64] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_arm64, repo.tz_4.0_standard -buildroot = ~/GBS-ROOT-4.0-STANDARD-AARCH64 - -############################################### -# -# Tizen v4.0 for standard (aarch64), Mirroring Server for HQ developers -# -[profile.tz_4.0_standard_aarch64_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_arm64_mirror, repo.tz_4.0_standard_mirror -buildroot = ~/GBS-ROOT-4.0-STANDARD-AARCH64 - -############################################### -# -# Tizen v4.0 for standard (ix86) -# -[profile.tz_4.0_standard_ia32] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_ia32, repo.tz_4.0_standard -buildroot = ~/GBS-ROOT-4.0-STANDARD-IX86 - -############################################### -# -# Tizen v4.0 for standard (ix86), Mirroring Server for HQ developers -# -[profile.tz_4.0_standard_ia32_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_ia32_mirror, repo.tz_4.0_standard_mirror -buildroot = ~/GBS-ROOT-4.0-STANDARD-IX86 - -############################################### -# -# Tizen v4.0 for standard (x86_64) -# -[profile.tz_4.0_standard_x86_64] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_x86_64, repo.tz_4.0_standard -buildroot = ~/GBS-ROOT-4.0-STANDARD-X86_64 - -############################################### -# -# Tizen v4.0 for standard (x86_64), Mirroring Server for HQ developers -# -[profile.tz_4.0_standard_x86_64_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_x86_64_mirror, repo.tz_4.0_standard_mirror -buildroot = ~/GBS-ROOT-4.0-STANDARD-X86_64 - -############################################### -# -# Tizen v4.0 for emulator (ix86) -# -[profile.tz_4.0_emulator_ia32] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_ia32, repo.tz_4.0_emulator -buildroot = ~/GBS-ROOT-4.0-EMULATOR-IX86 - -############################################### -# -# Tizen v4.0 for emulator (ix86), Mirroring Server for HQ developers -# -[profile.tz_4.0_emulator_ia32_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_ia32_mirror, repo.tz_4.0_emulator_mirror -buildroot = ~/GBS-ROOT-4.0-EMULATOR-IX86 - -############################################### -# -# Tizen v4.0 for emulator (x86_64) -# -[profile.tz_4.0_emulator_x86_64] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_x86_64, repo.tz_4.0_emulator -buildroot = ~/GBS-ROOT-4.0-EMULATOR-X86_64 - -############################################### -# -# Tizen v4.0 for emulator (x86_64), Mirroring Server for HQ developers -# -[profile.tz_4.0_emulator_x86_64_mirror] -obs = obs.tizen_4.0 -repos = repo.public_4.0_base_x86_64_mirror, repo.tz_4.0_emulator_mirror -buildroot = ~/GBS-ROOT-4.0-EMULATOR-X86_64 - -############################################### -# -# Tizen product tv -# -[obs.tizen_product_tv] -url = https://168.219.243.64/api -user = obs_iewer -passwdx = obs_iewer_64 - -############################################ -# -# Tizen v5.5 for product tv (MuseM armv7l) -# -[profile.tztv_5.5_arm-musem] -obs = obs.tizen_product_tv -repos = repo.tv_product_5.5_base, repo.tv_product_5.5_musem -buildroot = ~/GBS-ROOT-5.5-TV-PRODUCT-MUSEM - -[repo.tv_product_5.5_base] -url = http://168.219.244.109/base/tizen-5.5-base-main/standard/latest/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tv_product_5.5_musem] -url = http://168.219.244.109/products/tv/archive/2020/ONEMAIN/MuseM/latest/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################ -# -# Tizen v5.0 for product tv (MuseM armv7l) -# -[profile.tztv_5.0_arm-musem] -obs = obs.tizen_product_tv -repos = repo.tv_product_5.0_musem, repo.tv_product_5.0_base -buildroot = ~/GBS-ROOT-5.0-TV-PRODUCT-MUSEM - -[repo.tv_product_5.0_base] -url = http://168.219.244.109/base/tizen-5.0-base-main2019/standard/latest/ - -[repo.tv_product_5.0_musem] -url = http://168.219.244.109/products/tv/archive/2019/MAIN2019/MuseM/latest/ - -############################################# -# -# Tizen v5.0 for product tv (KantM2 armv7l) -# -[profile.tztv_arm-kantm2] -obs = obs.tizen_product_tv -repos = repo.tv_product_5.0_kantm2, repo.tv_product_5.0_base -buildroot = ~/GBS-ROOT-5.0-TV-PRODUCT-KANTM2 - -[repo.tv_product_5.0_base] -url = http://168.219.244.109/base/tizen-5.0-base-main2019/standard/latest/ - -[repo.tv_product_5.0_kantm2] -url = http://168.219.244.109/products/tv/archive/2019/MAIN2019/KantM2_ATSC/latest/ - -############################################# -# -# Tizen v5.0 for product tv (KantM armv7l) -# -[profile.tztv_arm-kantm] -obs = obs.tizen_product_tv -repos = repo.tv_product_5.0_kantm, repo.tv_product_5.0_base -buildroot = ~/GBS-ROOT-5.0-TV-PRODUCT-KANTM - -[repo.tv_product_5.0_base] -url = http://168.219.244.109/base/tizen-5.0-base-main2019/standard/latest - -[repo.tv_product_5.0_kantm] -url = http://168.219.244.109/hijacks/PRECEDENCE/PRE_5.0MIGRATION-KantM/latest/ - -############################################# -# -# Tizen v4.0 for product tv (KantM armv7l) -# -[profile.tztv_4.0_arm-kantm] -obs = obs.tizen_product_tv -repos = repo.tv_product_4.0_kantm, repo.tv_product_4.0_base -buildroot = ~/GBS-ROOT-4.0-TV-PRODUCT-KANTM - -[repo.tv_product_4.0_base] -url=http://168.219.244.109/tizen-rsa/tizen-4.0-base-main2018/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_4.0_kantm] -url=http://168.219.244.109/products/tv/archive/2018/MAIN2018/KantM/latest/repos/product/armv7l/packages/ - -############################################# -# -# Tizen v4.0 for product tv (KantM2 armv7l) -# -[profile.tztv_4.0_arm-kantm2] -obs = obs.tizen_product_tv -repos = repo.tv_product_4.0_kantm2, repo.tv_product_4.0_base -buildroot = ~/GBS-ROOT-4.0-TV-PRODUCT-KANTM2 - -[repo.tv_product_4.0_kantm2] -url=http://168.219.244.109/products/tv/archive/2018/MAIN2018/KantM2/latest/repos/product/armv7l/packages/ - -############################################### -# -# Tizen product da -# -[profile.tzda_4.0_arm-kantm] -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -repos = repo.base_arm, repo.fhub3.0_kantm_ad -buildroot = ~/GBS-ROOT-4.0-DA-PRODUCT-KANTM - -[profile.tzda_4.0_arm-kantm2] -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -repos = repo.base_arm, repo.fhub3.0_kantm2_ad -buildroot = ~/GBS-ROOT-4.0-DA-PRODUCT-KANTM2 - -[profile.tzda_4.0_emulator32] -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -repos = repo.base_emulator32, repo.fhub3.0_emulator32_ad -buildroot = ~/GBS-ROOT-4.0-DA-PRODUCT-EMUL - -#Family Hub 3.0 KANT-M AD -[repo.fhub3.0_kantm_ad] -# FIXME : The rpm package capi-media-player has not been released -# to gbs rpm repository after 20171227.2. -# Please recover the repository with the latest one -# once the platform issue is fixed. -#url = http://165.213.149.200/download/snapshots/tizen/4.0-da-fhub3.0/latest/repos/KANTM/packages/ -url = http://165.213.149.200/download/snapshots/tizen/4.0-da-fhub3.0/tizen-4.0-da-fhub3.0_20171227.2/repos/KANTM/packages - -#Family Hub 3.0 KANT-M2 AD -[repo.fhub3.0_kantm2_ad] -url = http://165.213.149.200/download/snapshots/tizen/4.0-da-fhub3.0/latest/repos/KANTM2/packages/ - -#Family Hub 3.0 Emulator AD -[repo.fhub3.0_emulator32_ad] -url=http://165.213.149.200/download/snapshots/tizen/4.0-da-fhub3.0/latest/repos/emulator32/packages/ - -#Tizen 4.0 Base ARM -[repo.base_arm] -url=http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/arm/packages/ - -#Tizen 4.0 Base Emulator -[repo.base_emulator32] -url=http://165.213.149.200/download/public_mirror/tizen/4.0-base/latest/repos/emulator32/packages/ - -############################################### -# -# Tizen v3.0 -# -[obs.tizen_3.0] -url = https://api.tizen.org - -############################################### -# -# Tizen v3.0 for tv (arm-wayland) -# -[profile.tztv_3.0_arm-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tztv_3.0_arm-wayland -buildroot = ~/GBS-ROOT-3.0-TV-ARM-WAYLAND - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tztv_3.0_arm-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-tv/latest/repos/arm-wayland/packages/ - -############################################### -# -# Tizen v3.0 for tv (arm-wayland), Mirroring Server for HQ developers -# -[profile.tztv_3.0_arm-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm_mirror, repo.tztv_3.0_arm-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-TV-ARM-WAYLAND - -[repo.public_3.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tztv_3.0_arm-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-tv/latest/repos/arm-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for tv (emulator32-wayland) -# -[profile.tztv_3.0_emulator32-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator32, repo.tztv_3.0_emul-wayland -buildroot = ~/GBS-ROOT-3.0-TV-EMUL-WAYLAND - -[repo.public_3.0_base_emulator32] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tztv_3.0_emul-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-tv/latest/repos/emulator32-wayland/packages/ - -############################################### -# -# Tizen v3.0 for tv (emulator32-wayland), Mirroring Server for HQ developers -# -[profile.tztv_3.0_emulator32-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator32_mirror, repo.tztv_3.0_emul-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-TV-EMUL-WAYLAND - -[repo.public_3.0_base_emulator32_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/base/latest/repos/emulator32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tztv_3.0_emul-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-tv/latest/repos/emulator32-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for mobile (arm-wayland) -# -[profile.tzmb_3.0_arm-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tzmb_3.0_arm-wayland -buildroot = ~/GBS-ROOT-3.0-MOBILE-ARM-WAYLAND - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tzmb_3.0_arm-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-mobile/latest/repos/arm-wayland/packages/ - -############################################### -# -# Tizen v3.0 for mobile (arm-wayland), Mirroring Server for HQ developers -# -[profile.tzmb_3.0_arm-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm_mirror, repo.tzmb_3.0_arm-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-MOBILE-ARM-WAYLAND - -[repo.public_3.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzmb_3.0_arm-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-mobile/latest/repos/arm-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for mobile (arm64-wayland) -# -[profile.tzmb_3.0_arm64-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm64, repo.tzmb_3.0_arm64-wayland -buildroot = ~/GBS-ROOT-3.0-MOBILE-ARM64-WAYLAND - -[repo.public_3.0_base_arm64] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm64/packages/ - -[repo.tzmb_3.0_arm64-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-mobile/latest/repos/arm64-wayland/packages/ - -############################################### -# -# Tizen v3.0 for mobile (arm64-wayland), Mirroring Server for HQ developers -# -[profile.tzmb_3.0_arm64-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm64_mirror, repo.tzmb_3.0_arm64-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-MOBILE-ARM64-WAYLAND - -[repo.public_3.0_base_arm64_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzmb_3.0_arm64-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-mobile/latest/repos/arm64-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for mobile (emulator-wayland) -# -[profile.tzmb_3.0_emulator32-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator32, repo.tzmb_3.0_emul-wayland -buildroot = ~/GBS-ROOT-3.0-MOBILE-EMUL-WAYLAND - -[repo.public_3.0_base_emulator32] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tzmb_3.0_emul-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-mobile/latest/repos/emulator32-wayland/packages/ - -############################################### -# -# Tizen v3.0 for mobile (emulator-wayland), Mirroring Server for HQ developers -# -[profile.tzmb_3.0_emulator32-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator32_mirror, repo.tzmb_3.0_emul-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-MOBILE-EMUL-WAYLAND - -[repo.public_3.0_base_emulator32_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/emulator32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzmb_3.0_emul-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-mobile/latest/repos/emulator32-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for mobile (emulator64-wayland) -# -[profile.tzmb_3.0_emulator64-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator64, repo.tzmb_3.0_emul64-wayland -buildroot = ~/GBS-ROOT-3.0-MOBILE-EMUL64-WAYLAND - -[repo.public_3.0_base_emulator64] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator64/packages/ - -[repo.tzmb_3.0_emul64-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-mobile/latest/repos/emulator64-wayland/packages/ - -############################################### -# -# Tizen v3.0 for mobile (emulator64-wayland), Mirroring Server for HQ developers -# -[profile.tzmb_3.0_emulator64-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator64_mirror, repo.tzmb_3.0_emul64-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-MOBILE-EMUL64-WAYLAND - -[repo.public_3.0_base_emulator64_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/emulator64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzmb_3.0_emul64-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-mobile/latest/repos/emulator64-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for mobile (armv7l-wayland TM1) -# -[profile.tzmb_3.0_target-TM1] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tzmb_3.0_TM1 -buildroot = ~/GBS-ROOT-3.0-MOBILE-TM1 - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tzmb_3.0_TM1] -url = http://download.tizen.org/snapshots/tizen/3.0-mobile/latest/repos/target-TM1/packages/ - -############################################### -# -# Tizen v3.0 for mobile (armv7l-wayland TM1), Mirroring Server for HQ developers -# -[profile.tzmb_3.0_target-TM1_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm_mirror, repo.tzmb_3.0_TM1_mirror -buildroot = ~/GBS-ROOT-3.0-MOBILE-TM1 - -[repo.public_3.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzmb_3.0_TM1_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-mobile/latest/repos/target-TM1/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for wearable (emulator32-wayland) -# -[profile.tzwr_3.0_emulator32-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator, repo.tzwr_3.0_emulator -buildroot = ~/GBS-ROOT-3.0-WEARABLE-EMUL - -[repo.public_3.0_base_emulator] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tzwr_3.0_emulator] -url = http://download.tizen.org/snapshots/tizen/3.0-wearable/latest/repos/emulator32-wayland/packages/ - -############################################### -# -# Tizen v3.0 for wearable (emulator32-wayland), Mirroring Server for HQ developers -# -[profile.tzwr_3.0_emulator32-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator_mirror, repo.tzwr_3.0_emulator_mirror -buildroot = ~/GBS-ROOT-3.0-WEARABLE-EMUL - -[repo.public_3.0_base_emulator_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/emulator32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzwr_3.0_emulator_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-wearable/latest/repos/emulator32-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################## -# -# Tizen v3.0 for wearable (target-circle) -# -[profile.tzwr_3.0_target-circle] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tzwr_3.0_target-circle -buildroot = ~/GBS-ROOT-3.0-WEARABLE-TARGET-CIRCLE - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tzwr_3.0_target-circle] -url = http://download.tizen.org/snapshots/tizen/3.0-wearable/latest/repos/target-circle/packages/ - -############################################### -# -# Tizen v3.0 for wearable (target-circle), Mirroring Server for HQ developers -# -[profile.tzwr_3.0_target-circle_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm_mirror, repo.tzwr_3.0_arm-target-circle_mirror -buildroot = ~/GBS-ROOT-3.0-WEARABLE-TARGET-CIRCLE - -[repo.public_3.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzwr_3.0_arm-target-circle_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-wearable/latest/repos/target-circle/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for wearable (emulator-circle) -# -[profile.tzwr_3.0_emulator-circle] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator, repo.tzwr_3.0_emulator-circle -buildroot = ~/GBS-ROOT-3.0-WEARABLE-EMUL-CIRCLE - -[repo.public_3.0_base_emulator] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tzwr_3.0_emulator-circle] -url = http://download.tizen.org/snapshots/tizen/3.0-wearable/latest/repos/emulator-circle/packages/ - -############################################### -# -# Tizen v3.0 for wearable (emulator-circle), Mirroring Server for HQ developers -# -[profile.tzwr_3.0_emulator-circle_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emulator_mirror, repo.tzwr_3.0_emulator-circle_mirror -buildroot = ~/GBS-ROOT-3.0-WEARABLE-EMUL-CIRCLE - -[repo.public_3.0_base_emulator_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/emulator32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzwr_3.0_emulator-circle_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-wearable/latest/repos/emulator-circle/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for common (armv7l) -# -[profile.tzcommon_3.0_arm-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tzcommon_3.0_arm-wayland -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tzcommon_3.0_arm-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-common/latest/repos/arm-wayland/packages/ - -############################################### -# -# Tizen v3.0 for common (armv7l), Mirroring Server for HQ developers -# -[profile.tzcommon_3.0_arm-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm_mirror, repo.tzcommon_3.0_arm-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_arm_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzcommon_3.0_arm-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-common/latest/repos/arm-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for common (arm64-wayland) -# -[profile.tzcommon_3.0_arm64-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm64, repo.tzcommon_3.0_arm64-wayland -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_arm64] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm64/packages/ - -[repo.tzcommon_3.0_arm64-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-common/latest/repos/arm64-wayland/packages/ - -############################################### -# -# Tizen v3.0 for common (arm64-wayland), Mirroring Server for HQ developers -# -[profile.tzcommon_3.0_arm64-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm64_mirror, repo.tzcommon_3.0_arm64-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_arm64_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/arm64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzcommon_3.0_arm64-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-common/latest/repos/arm64-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for common (emulator32-wayalnd) -# -[profile.tzcommon_3.0_emulator32-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emul, repo.tzcommon_3.0_emul-wayland -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_emul] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tzcommon_3.0_emul-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-common/latest/repos/emulator32-wayland/packages/ - -############################################### -# -# Tizen v3.0 for common (emulator32-wayland), Mirroring Server for HQ developers -# -[profile.tzcommon_3.0_emulator32-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emul_mirror, repo.tzcommon_3.0_emul-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_emul_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/emulator32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzcommon_3.0_emul-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-common/latest/repos/emulator32-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for common (ia32) -# -[profile.tzcommon_3.0_ia32-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_ia32, repo.tzcommon_3.0_ia32-wayland -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_ia32] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/ia32/packages/ - -[repo.tzcommon_3.0_ia32-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-common/latest/repos/ia32-wayland/packages/ - -############################################### -# -# Tizen v3.0 for common (ia32), Mirroring Server for HQ developers -# -[profile.tzcommon_3.0_ia32-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_ia32_mirror, repo.tzcommon_3.0_ia32-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_ia32_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/ia32/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzcommon_3.0_ia32-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-common/latest/repos/ia32-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for common (x86_64) -# -[profile.tzcommon_3.0_x86-wayland] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_x86, repo.tzcommon_3.0_x86-wayland -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_x86] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/x86_64/packages/ - -[repo.tzcommon_3.0_x86-wayland] -url = http://download.tizen.org/snapshots/tizen/3.0-common/latest/repos/x86_64-wayland/packages/ - -############################################### -# -# Tizen v3.0 for common (x86_64), Mirroring Server for HQ developers -# -[profile.tzcommon_3.0_x86-wayland_mirror] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_x86_mirror, repo.tzcommon_3.0_x86-wayland_mirror -buildroot = ~/GBS-ROOT-3.0-COMMON - -[repo.public_3.0_base_x86_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-base/latest/repos/x86_64/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -[repo.tzcommon_3.0_x86-wayland_mirror] -url = http://165.213.149.200/download/public_mirror/tizen/3.0-common/latest/repos/x86_64-wayland/packages/ -user = blinkbot -passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== - -############################################### -# -# Tizen v3.0 for ivi (armv7l) -# -[profile.tzivi_3.0_arm] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_arm, repo.tzivi_3.0_arm -buildroot = ~/GBS-ROOT-3.0-IVI - -[repo.public_3.0_base_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/arm/packages/ - -[repo.tzivi_3.0_arm] -url = http://download.tizen.org/snapshots/tizen/3.0-ivi/latest/repos/arm/packages/ - -############################################### -# -# Tizen v3.0 for ivi (emulator) -# -[profile.tzivi_3.0_emulator] -obs = obs.tizen_3.0 -repos = repo.public_3.0_base_emul, repo.tzivi_3.0_emul -buildroot = ~/GBS-ROOT-3.0-IVI - -[repo.public_3.0_base_emul] -url = http://download.tizen.org/snapshots/tizen/3.0-base/latest/repos/emulator32/packages/ - -[repo.tzivi_3.0_emul] -url = http://download.tizen.org/snapshots/tizen/3.0-ivi/latest/repos/emulator/packages/ - -############################################# -# -# Tizen v3.0 for product tv (JazzM armv7l) -# -[profile.tztv_3.0_arm-jazzm] -obs = obs.tizen_product_tv -repos = repo.tv_product_3.0_jazzm, repo.tv_product_3.0_base, repo.tv_product_3.0_toolchain -buildroot = ~/GBS-ROOT-3.0-TV-PRODUCT-JAZZM - -[repo.tv_product_3.0_base] -url=http://168.219.244.109/tizen-rsa/tizen-3.0-base-main2017/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_toolchain] -url=http://168.219.244.109/tizen-rsa/tizen-3.0-base-toolchain/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_jazzm] -url=http://168.219.244.109/releases/tizen-3.0-product-main2017/product/JazzM/latest/repos/product/armv7l/packages/ - -############################################# -# -# Tizen v3.0 for product tv overseas (JazzM armv7l) -# -[profile.tztv_3.0_arm-jazzm_overseas] -obs = obs.tizen_product_tv -repos = repo.tv_product_3.0_jazzm_overseas, repo.tv_product_3.0_base_jazzm_overseas -buildroot = ~/GBS-ROOT-3.0-TV-PRODUCT-JAZZM - -[repo.tv_product_3.0_base_overseas] -url=http://10.103.211.119/tizen-rsa/tizen-3.0-base-main2017/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_toolchain_overseas] -url=http://10.103.211.119/tizen-rsa/tizen-3.0-base-toolchain/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_jazzm_overseas] -url=http://10.103.211.119/releases/tizen-3.0-product-main2017/product/JazzM/latest/repos/product/armv7l/packages/ - -############################################# -# -# Tizen v3.0 for product tv (emulator) -# -[profile.tztv_3.0_emulator32_product] -obs = obs.tizen_product_tv -repos = repo.tv_product_3.0_emulator32_product, repo.tv_product_3.0_base_emulator32_product -buildroot = ~/GBS-ROOT-3.0-TV-PRODUCT-EMULATOR32 - -[repo.tv_product_3.0_base_emulator32_product] -url=http://168.219.244.109/tizen-rsa/tizen-3.0-base-main2017/emulator32/latest/repos/base/ia32/packages/ - -[repo.tv_product_3.0_emulator32_product] -url=http://168.219.244.109/releases/tizen-3.0-product-main2017/product/emulator32/latest/repos/product/ia32/packages/ - -############################################# -# -# Tizen v3.0 for product tv (KantM armv7l) -# -[profile.tztv_3.0_arm-kantm] -obs = obs.tizen_product_tv -repos = repo.tv_product_3.0_kantm, repo.tv_product_3.0_base, repo.tv_product_3.0_toolchain -buildroot = ~/GBS-ROOT-3.0-TV-PRODUCT-KANTM_XWALK - -[repo.tv_product_3.0_base] -url=http://168.219.244.109/tizen-rsa/tizen-3.0-base-main2017/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_toolchain] -url=http://168.219.244.109/tizen-rsa/tizen-3.0-base-toolchain/standard/latest/repos/base/armv7l/packages/ - -[repo.tv_product_3.0_kantm] -url=http://168.219.244.109/releases/tizen-3.0-product-main2017/product/KantM/latest/repos/product/armv7l/packages/ diff --git a/tizen_src/build/gbs.conf.in b/tizen_src/build/gbs.conf.in new file mode 100755 index 0000000..c69c7ef --- /dev/null +++ b/tizen_src/build/gbs.conf.in @@ -0,0 +1,202 @@ +############################################### +# +# The Tizen public unified (upper than 4.0) +# +[obs.tizen] +url = https://api.tizen.org + +[repo.tz_standard] +url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@unified/latest/repos/standard/packages/ + +[repo.tz_emulator] +url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@unified/latest/repos/emulator/packages/ + +[repo.public_base_standard] +url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@base/latest/repos/standard/packages/ + +############################################### +# +# The Tizen public unified (mirror) +# +[repo.tz_standard_mirror] +url = http://165.213.149.200/download/public_mirror/tizen/unified/latest/repos/standard/packages/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +[repo.tz_emulator_mirror] +url = http://165.213.149.200/download/public_mirror/tizen/unified/latest/repos/emulator/packages/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +[repo.public_base_standard_mirror] +url = http://165.213.149.200/download/public_mirror/tizen/base/latest/repos/standard/packages/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +############################################### +# +# The latest Tizen public standard +# +[profile.tz_standard] +obs = obs.tizen +repos = repo.public_base_standard, repo.tz_standard +buildroot = ~/GBS-ROOT-TZ_@TIZEN_VERSION@_STANDARD + +############################################### +# +# The latest Tizen public emulator +# +[profile.tz_emulator] +obs = obs.tizen +repos = repo.public_base_standard, repo.tz_emulator +buildroot = ~/GBS-ROOT-TZ_@TIZEN_VERSION@_EMULATOR + +############################################### +# +# The latest Tizen public standard, Mirroring Server for HQ developers +# +[profile.tz_standard_mirror] +obs = obs.tizen +repos = repo.public_base_standard_mirror, repo.tz_standard_mirror +buildroot = ~/GBS-ROOT-TZ_@TIZEN_VERSION@_STANDARD + +############################################### +# +# The latset Tizen public emulator, Mirroring Server for HQ developers +# +[profile.tz_emulator_mirror] +obs = obs.tizen +repos = repo.public_base_standard, repo.tz_emulator_mirror +buildroot = ~/GBS-ROOT-TZ_@TIZEN_VERSION@_EMULATOR + +############################################### +# +# Tizen product wearable (spin) +# +[obs.spin] +url = http://10.113.136.201 + +############################################### +# +# Tizen v5.5 spin Wearable +# +[repo.wearable_product_5.5] +url = http://165.213.149.200/download/snapshots/tizen/tizen-wearable-R800/latest/repos/standard/packages/ + +[repo.wearable_product_5.5_base] +url = http://165.213.149.200/download/snapshots/tizen/base-wearable/latest/repos/standard/packages/ + +############################################### +# +# Tizen v5.5 spin Wearable (armv7l) +# +[profile.tzwr_5.5_arm-spin] +obs = obs.spin +repos = repo.wearable_product_5.5_base, repo.wearable_product_5.5 +buildroot = ~/GBS-ROOT-TZWR_@TIZEN_VERSION@_ARM-SPIN +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +############################################### +# +# Tizen product tv +# +[obs.tizen_product_tv] +url = https://168.219.243.64/api + +############################################ +# +# Tizen v6.0 for product tv (NikeM armv7l) +# +[profile.tztv_6.0_arm-nikem] +obs = obs.tizen_product_tv +repos = repo.tv_product_6.0_nikem, repo.tv_product_6.0_base +buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_ARM-NIKEM + +[repo.tv_product_6.0_base] +url = http://168.219.244.109/tizen-rsa/tizen-6.0-base/standard/latest/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +[repo.tv_product_6.0_nikem] +url = http://168.219.244.109/products/tv/archive/2021/ONEMAIN/NikeM/latest +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +############################################ +# +# Tizen v5.5 for product tv (NikeM armv7l) +# +[profile.tztv_5.5_arm-nikem] +obs = obs.tizen_product_tv +repos = repo.tv_product_5.5_nikem, repo.tv_product_5.5_base +buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_ARM-NIKEM + +[repo.tv_product_5.5_base] +url = http://168.219.244.109/base/tizen-5.5-base-main/standard/latest/repos/base/armv7l/packages/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +[repo.tv_product_5.5_nikem] +url = http://168.219.244.109/products/tv/archive/2020/ONEMAIN/NikeM/latest/repos/product/armv7l/packages/ +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +############################################################################################ +# +# Tizen v5.5 for product tv (Emulator) +# +[profile.tztv_5.5_emulator] +obs = obs.tizen_product_tv +repos = repo.product_2018_Emulator, repo.base_2018 +buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_EMULATOR + +[repo.base_2018] +url=http://168.219.245.245/base/tizen-5.5-base-main/emulator32/latest/repos/base/ia32/packages/ + +[repo.product_2018_Emulator] +url=http://168.219.245.245/products/tv/archive/2020/ONEMAIN/emulator32/latest/repos/product/ia32/packages/ + +############################################### +# +# Tizen v6.0 product DA +# +#DA Family Hub 6.0 kantm +[repo.da_product_6.0_fhub_kantm] +url = http://10.113.136.26/snapshots/DA/Tizen-6.0/Tizen-6.0-DA-FHUB/reference/repos/KANTM/packages/ + +#Tizen 6.0 Base +[repo.da_product_6.0_base] +url = http://download.tizen.org/snapshots/tizen/base/latest/repos/standard/packages/ + +############################################### +# +# Tizen v6.0 product DA (armv7l) +# +[profile.tzda_6.0_arm-kantm] +repos = repo.da_product_6.0_base, repo.da_product_6.0_fhub_kantm +buildroot = ~/GBS-ROOT-TZDA_@TIZEN_VERSION@_ARM-KANTM +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== + +############################################### +# +# Tizen v5.5 product DA +# +#DA Family Hub 5.5 kantm +[repo.da_product_5.5_fhub_kantm] +url = http://10.113.136.26/snapshots/DA/Tizen-5.5/Tizen-5.5-DA-FHUB5/latest/repos/KANTM/packages/ + +#Tizen 5.5 Base +[repo.da_product_5.5_base] +url = http://download.tizen.org/snapshots/tizen/5.5-base/latest/repos/standard/packages/ + +############################################### +# +# Tizen v5.5 product DA (armv7l) +# +[profile.tzda_5.5_arm-kantm] +repos = repo.da_product_5.5_base, repo.da_product_5.5_fhub_kantm +buildroot = ~/GBS-ROOT-TZDA_@TIZEN_VERSION@_ARM-KANTM +user = blinkbot +passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== diff --git a/tizen_src/build/gn_chromiumefl.sh b/tizen_src/build/gn_chromiumefl.sh index bd0d725..ce713d4 100755 --- a/tizen_src/build/gn_chromiumefl.sh +++ b/tizen_src/build/gn_chromiumefl.sh @@ -1,8 +1,34 @@ #!/bin/bash -source $(dirname $0)/common.sh +tizen_build_conf="/etc/tizen-build.conf" +get_profile() { + local profile= + # TV has something different. + if [ ! -f "$tizen_build_conf" ]; then + profile=desktop + elif [ "$(grep "TZ_BUILD_PROJECT" "$tizen_build_conf" | grep "Unified")" != "" ]; then + profile=unified + elif [ "$(grep "TZ_BUILD_RELEASE_NAME" "$tizen_build_conf" | grep "TV")" != "" ]; then + profile=tv + elif [ "$(grep "TZ_BUILD_PROJECT" "$tizen_build_conf" | grep "Wearable")" != "" ]; then + profile=wearable + elif [ "$(grep "TZ_BUILD_PROJECT" "$tizen_build_conf" | grep "DA")" != "" ]; then + profile=da + else + echo "There isn't proper profile." + return 1; + fi + echo $profile +} + +get_tizen_version() { + echo $(grep "TZ_BUILD_VERSION" "$tizen_build_conf" | sed -e "s/TZ_BUILD_VERSION=//g") +} + +source $(dirname $0)/common.sh --tizen_$(get_tizen_version) trap 'error_report $0 $LINENO' ERR SIGINT SIGTERM SIGQUIT host_arch=$(getHostArch) +system_deps=$(getSystemDeps $(get_profile)) export HOST_ARCH=$host_arch supported_targets=("tizen" "desktop") @@ -35,17 +61,25 @@ while [[ $# > 0 ]]; do tizen_version=*) tizen_version=$(echo $1 | sed -e 's#tizen_version\=\([0-9.]*\)#\1#') ;; - tizen_emulator_support=1) - tizen_emulator_support=1 + tizen_emulator_support=true) + tizen_emulator_support=true ;; tizen_product_tv=true) tizen_product_tv=true ;; + tizen_product_da=true) + tizen_product_da=true + ;; + use_system_icu=true) + system_deps=("${system_deps[@]/icu/}") + system_deps+=" icu" + ;; + use_system_icu=false) + system_deps=("${system_deps[@]/icu/}") + ;; is_clang=true) is_clang=true - #use_wayland=true) - # use_wayland=true - # ;; + ;; esac shift; done @@ -88,43 +122,52 @@ COMMON_GN_PARAMETERS="use_libjpeg_turbo=true use_libpci=false " -SYSTEM_DEPS="--system-libraries - libevent - libpng - libxml - libxslt - zlib - " - add_desktop_flags() { local is_clang=false if [ $USE_CLANG == 1 ]; then is_clang=true fi - ADDITIONAL_GN_PARAMETERS+="is_tizen=false + ADDITIONAL_GN_PARAMETERS+="gcc_ver=\"$(getGccVersion)\" is_clang=${is_clang} - werror=false + is_tizen=false + target_cpu=\"${host_arch}\" + target_os="\"linux\"" use_sysroot=false use_wayland=false - target_os="\"linux\"" - target_cpu=\"${host_arch}\" + werror=false " } add_arm_flags() { ADDITIONAL_GN_PARAMETERS+="arm_use_neon=true " + if [ "$host_arch" == "arm64" ]; then + ADDITIONAL_GN_PARAMETERS+="system_libdir=\"lib64\" + deps_lib_path=\"/usr/lib64\" + " + fi +} + +add_emulator_flags() { + if [ "$host_arch" == "x64" ]; then + ADDITIONAL_GN_PARAMETERS+="system_libdir=\"lib64\" + deps_lib_path=\"/usr/lib64\" + " + fi } add_tizen_flags() { ADDITIONAL_GN_PARAMETERS+="is_tizen=true + gcc_ver=\"$(getGccVersion)\" python_ver=\"$(getPythonVersion)\" - enable_basic_printing=true is_official_build=true linux_use_bundled_binutils=false enable_nacl=false + enable_basic_printing=false + enable_print_preview=false tizen_multimedia_eme_support=false target_os="\"tizen\"" + target_sysroot=\"/\" current_cpu=\"${host_arch}\" host_cpu=\"${host_arch}\" target_cpu=\"${host_arch}\" @@ -151,6 +194,16 @@ add_tizen_flags() { " fi + if [[ "${system_deps[@]}" =~ "icu" ]]; then + ADDITIONAL_GN_PARAMETERS+="icu_use_data_file=false + use_system_icu=true + " + processICU replace_icu + else + ADDITIONAL_GN_PARAMETERS+="icu_use_data_file=true + " + fi + # [M49_2623] Temporary disabling the flag. # FIXME: http://165.213.149.170/jira/browse/TWF-610 ADDITIONAL_GN_PARAMETERS+="tizen_multimedia_support=false @@ -187,7 +240,9 @@ add_gbs_flags() { # The symbol level is set to 1 by default. # Once the issue is fixed, set it to the level from platform. local symbol_level=$(echo " $CFLAGS" | sed -e 's#.* -g\([0-9]\).*#\1#') - if [ "$symbol_level" != "0" ]; then + if [ "$host_arch" == "x86" ]; then + symbol_level="0" + elif [ "$symbol_level" != "0" ]; then symbol_level="1" fi @@ -224,6 +279,8 @@ else add_tizen_flags if [ "$host_arch" == "arm" -o "$host_arch" == "arm64" ]; then add_arm_flags + elif [ "$host_arch" == "x86" -o "$host_arch" == "x64" ]; then + add_emulator_flags fi if [ "$buildType" == "gbs" ]; then add_gbs_flags @@ -232,10 +289,10 @@ else fi fi -if [ "$SYSTEM_DEPS" != "" ]; then +if [ "$system_deps" != "" ]; then echo "** use system lib : replace **" - #replacing original files with correct ones according to $SYSTEM_DEPS - $TOPDIR/build/linux/unbundle/replace_gn_files.py $SYSTEM_DEPS + #replacing original files with correct ones according to $system_deps + $TOPDIR/build/linux/unbundle/replace_gn_files.py $system_deps fi _GN_ARGS=" @@ -252,7 +309,7 @@ printf "GN_ARGUMENTS:\n" for arg in $_GN_ARGS; do printf " * ${arg##-D}\n" done -for arg in $SYSTEM_DEPS; do +for arg in $system_deps; do printf " * ${arg##-D}\n" done @@ -261,10 +318,4 @@ ${TOPDIR}/tizen_src/build/gn_chromiumefl \ ret=$? -if [ "$SYSTEM_DEPS" != "" ]; then - echo "** use system lib : undo **" - # Restore gn files to their original states not to mess up the tree permanently. - $TOPDIR/build/linux/unbundle/replace_gn_files.py --undo $SYSTEM_DEPS -fi - exit $ret -- 2.7.4 From 0ca87d90ef99cc814c0fd36ba7e4151da5a0791e Mon Sep 17 00:00:00 2001 From: Youngsoo Choi Date: Wed, 10 Jun 2020 17:04:51 +0900 Subject: [PATCH 15/16] [Product TV] Update gbs.conf with the official repos The product gbs repo has been changed with the official repos. The gbs root folders having regular pattern are using version macros and the others are using specific tizen version numbers. Change-Id: I309d06d1e41659d25e01e882714a4c60b7cb2259 Signed-off-by: Youngsoo Choi --- tizen_src/build/common.sh | 7 ++++--- tizen_src/build/gbs.conf.in | 40 ++++++++++++++++++++-------------------- 2 files changed, 24 insertions(+), 23 deletions(-) diff --git a/tizen_src/build/common.sh b/tizen_src/build/common.sh index 5b214a8..58c431b 100755 --- a/tizen_src/build/common.sh +++ b/tizen_src/build/common.sh @@ -12,11 +12,12 @@ if [ "$(echo "$@" | grep -e "--tizen")" != "" ]; then fi # Generate gbs.conf -export REPO_VERSION= +export PUBLIC_REPO_VERSION= if [ "$DEFAULT_TIZEN_VERSION" != "${LATEST_TIZEN_VERSION}" ]; then - REPO_VERSION=$DEFAULT_TIZEN_VERSION- + PUBLIC_REPO_VERSION=$DEFAULT_TIZEN_VERSION- fi -sed -e "s/@TIZEN_VERSION@/$REPO_VERSION/g" \ +sed -e "s/@PUBLIC_REPO_VERSION@/$PUBLIC_REPO_VERSION/g" \ + -e "s/@TIZEN_VERSION@/$DEFAULT_TIZEN_VERSION/g" \ tizen_src/build/gbs.conf.in > tizen_src/build/gbs.conf function getSystemDeps() { diff --git a/tizen_src/build/gbs.conf.in b/tizen_src/build/gbs.conf.in index c69c7ef..3f721ca 100755 --- a/tizen_src/build/gbs.conf.in +++ b/tizen_src/build/gbs.conf.in @@ -6,13 +6,13 @@ url = https://api.tizen.org [repo.tz_standard] -url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@unified/latest/repos/standard/packages/ +url = http://download.tizen.org/snapshots/tizen/@PUBLIC_REPO_VERSION@unified/latest/repos/standard/packages/ [repo.tz_emulator] -url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@unified/latest/repos/emulator/packages/ +url = http://download.tizen.org/snapshots/tizen/@PUBLIC_REPO_VERSION@unified/latest/repos/emulator/packages/ [repo.public_base_standard] -url = http://download.tizen.org/snapshots/tizen/@TIZEN_VERSION@base/latest/repos/standard/packages/ +url = http://download.tizen.org/snapshots/tizen/@PUBLIC_REPO_VERSION@base/latest/repos/standard/packages/ ############################################### # @@ -93,7 +93,7 @@ url = http://165.213.149.200/download/snapshots/tizen/base-wearable/latest/repos [profile.tzwr_5.5_arm-spin] obs = obs.spin repos = repo.wearable_product_5.5_base, repo.wearable_product_5.5 -buildroot = ~/GBS-ROOT-TZWR_@TIZEN_VERSION@_ARM-SPIN +buildroot = ~/GBS-ROOT-TZWR_5.5_ARM-SPIN user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== @@ -104,14 +104,14 @@ passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== [obs.tizen_product_tv] url = https://168.219.243.64/api -############################################ +############################################### # # Tizen v6.0 for product tv (NikeM armv7l) # [profile.tztv_6.0_arm-nikem] obs = obs.tizen_product_tv repos = repo.tv_product_6.0_nikem, repo.tv_product_6.0_base -buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_ARM-NIKEM +buildroot = ~/GBS-ROOT-TZTV_6.0_ARM-NIKEM [repo.tv_product_6.0_base] url = http://168.219.244.109/tizen-rsa/tizen-6.0-base/standard/latest/ @@ -119,43 +119,43 @@ user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== [repo.tv_product_6.0_nikem] -url = http://168.219.244.109/products/tv/archive/2021/ONEMAIN/NikeM/latest +url = http://168.219.244.109/products/tv/official/2021/ONEMAIN/NikeM/latest/ user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -############################################ +############################################### # # Tizen v5.5 for product tv (NikeM armv7l) # [profile.tztv_5.5_arm-nikem] obs = obs.tizen_product_tv repos = repo.tv_product_5.5_nikem, repo.tv_product_5.5_base -buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_ARM-NIKEM +buildroot = ~/GBS-ROOT-TZTV_5.5_ARM-NIKEM [repo.tv_product_5.5_base] -url = http://168.219.244.109/base/tizen-5.5-base-main/standard/latest/repos/base/armv7l/packages/ +url = http://168.219.244.109/base/tizen-5.5-base-main/standard/latest/ user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== [repo.tv_product_5.5_nikem] -url = http://168.219.244.109/products/tv/archive/2020/ONEMAIN/NikeM/latest/repos/product/armv7l/packages/ +url = http://168.219.244.109/products/tv/official/2020/ONEMAIN/NikeM/latest/ user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -############################################################################################ +############################################### # # Tizen v5.5 for product tv (Emulator) # [profile.tztv_5.5_emulator] obs = obs.tizen_product_tv -repos = repo.product_2018_Emulator, repo.base_2018 -buildroot = ~/GBS-ROOT-TZTV_@TIZEN_VERSION@_EMULATOR +repos = repo.tv_emulator_product, repo.tv_emulator_base +buildroot = ~/GBS-ROOT-TZTV_5.5_EMULATOR -[repo.base_2018] -url=http://168.219.245.245/base/tizen-5.5-base-main/emulator32/latest/repos/base/ia32/packages/ +[repo.tv_emulator_base] +url = http://168.219.244.109/base/tizen-5.5-base-main/emulator32/latest/ -[repo.product_2018_Emulator] -url=http://168.219.245.245/products/tv/archive/2020/ONEMAIN/emulator32/latest/repos/product/ia32/packages/ +[repo.tv_emulator_product] +url = http://168.219.244.109/products/tv/official/2020/ONEMAIN/emulator32/latest/ ############################################### # @@ -175,7 +175,7 @@ url = http://download.tizen.org/snapshots/tizen/base/latest/repos/standard/packa # [profile.tzda_6.0_arm-kantm] repos = repo.da_product_6.0_base, repo.da_product_6.0_fhub_kantm -buildroot = ~/GBS-ROOT-TZDA_@TIZEN_VERSION@_ARM-KANTM +buildroot = ~/GBS-ROOT-TZDA_6.0_ARM-KANTM user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== @@ -197,6 +197,6 @@ url = http://download.tizen.org/snapshots/tizen/5.5-base/latest/repos/standard/p # [profile.tzda_5.5_arm-kantm] repos = repo.da_product_5.5_base, repo.da_product_5.5_fhub_kantm -buildroot = ~/GBS-ROOT-TZDA_@TIZEN_VERSION@_ARM-KANTM +buildroot = ~/GBS-ROOT-TZDA_5.5_ARM-KANTM user = blinkbot passwdx = QlpoOTFBWSZTWd0JOhUAAACBAABgIAAhAIIjF3JFOFCQ3Qk6FQ== -- 2.7.4 From d8e25663cec7def3fc24a5fe843a9593f6b11ea9 Mon Sep 17 00:00:00 2001 From: "yh106.jung" Date: Sun, 24 May 2020 22:43:27 -0700 Subject: [PATCH 16/16] Sync EWK API headers with Tizen 6.0 This patch syncronizes EWK API headers with Tizen 6.0(M1 release). Change-Id: Ic9aa91c714bc62f5302735ad1eb5a22f25b16b44 Signed-off-by: yh106.jung --- tizen_src/ewk/efl_integration/BUILD.gn | 9 + .../ewk/efl_integration/private/ewk_private.h | 13 +- tizen_src/ewk/efl_integration/public/EWebKit.h | 1 + .../ewk/efl_integration/public/EWebKit_internal.h | 1 + .../ewk/efl_integration/public/EWebKit_product.h | 3 + .../public/ewk_autofill_credit_card.cc | 55 ++++ .../public/ewk_autofill_credit_card_internal.h | 182 ++++++++++ .../efl_integration/public/ewk_autofill_profile.cc | 44 ++- .../efl_integration/public/ewk_autofill_profile.h | 4 +- .../public/ewk_autofill_profile_product.h | 179 ++++++++++ .../ewk_content_screening_detection_internal.h | 23 +- .../ewk/efl_integration/public/ewk_context.cc | 93 +++++- tizen_src/ewk/efl_integration/public/ewk_context.h | 131 +++++++- .../efl_integration/public/ewk_context_internal.h | 87 ++++- .../ewk/efl_integration/public/ewk_context_menu.h | 2 +- .../efl_integration/public/ewk_context_product.h | 62 +--- .../efl_integration/public/ewk_cookie_manager.h | 6 +- .../efl_integration/public/ewk_cookie_parser.cc | 59 ++++ .../ewk/efl_integration/public/ewk_cookie_parser.h | 77 +++++ tizen_src/ewk/efl_integration/public/ewk_error.cc | 2 +- .../ewk/efl_integration/public/ewk_geolocation.h | 7 +- .../public/ewk_highcontrast_product.h | 6 +- .../efl_integration/public/ewk_intercept_request.h | 58 ++-- tizen_src/ewk/efl_integration/public/ewk_main.cc | 10 + .../ewk/efl_integration/public/ewk_main_internal.h | 53 ++- .../public/ewk_media_downloadable_font_info.h | 62 ++++ .../ewk_media_downloadable_font_info_product.h | 47 +++ .../public/ewk_media_parental_rating_info.h | 62 ++++ .../ewk_media_parental_rating_info_product.h | 50 +++ .../public/ewk_media_playback_info.cc | 29 +- .../public/ewk_media_playback_info.h | 114 ------- .../public/ewk_media_playback_info_product.h | 21 +- .../public/ewk_media_subtitle_info.cc | 24 ++ .../public/ewk_media_subtitle_info.h | 100 ------ .../public/ewk_media_subtitle_info_product.h | 12 + .../efl_integration/public/ewk_policy_decision.cc | 5 +- .../public/ewk_policy_decision_internal.h | 2 +- .../ewk/efl_integration/public/ewk_settings.cc | 66 +++- .../ewk/efl_integration/public/ewk_settings.h | 23 +- .../efl_integration/public/ewk_settings_internal.h | 104 ++---- .../efl_integration/public/ewk_settings_product.h | 98 +++++- .../ewk/efl_integration/public/ewk_user_media.cc | 13 + .../public/ewk_user_media_internal.h | 37 +++ tizen_src/ewk/efl_integration/public/ewk_view.cc | 126 ++++++- tizen_src/ewk/efl_integration/public/ewk_view.h | 84 +++-- .../ewk/efl_integration/public/ewk_view_internal.h | 62 ++-- .../ewk/efl_integration/public/ewk_view_product.h | 366 +++++++++++++++------ 47 files changed, 2021 insertions(+), 653 deletions(-) create mode 100644 tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card.cc create mode 100644 tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card_internal.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_autofill_profile_product.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_cookie_parser.cc create mode 100644 tizen_src/ewk/efl_integration/public/ewk_cookie_parser.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info_product.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info.h create mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info_product.h delete mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_playback_info.h delete mode 100644 tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.h diff --git a/tizen_src/ewk/efl_integration/BUILD.gn b/tizen_src/ewk/efl_integration/BUILD.gn index 7740682..69ae5a4 100644 --- a/tizen_src/ewk/efl_integration/BUILD.gn +++ b/tizen_src/ewk/efl_integration/BUILD.gn @@ -406,8 +406,11 @@ shared_library("chromium-ewk") { "public/ewk_auth_challenge_internal.h", "public/ewk_auth_request.cc", "public/ewk_auth_request_internal.h", + "public/ewk_autofill_credit_card.cc", + "public/ewk_autofill_credit_card_internal.h", "public/ewk_autofill_profile.cc", "public/ewk_autofill_profile.h", + "public/ewk_autofill_profile_product.h", "public/ewk_back_forward_list.cc", "public/ewk_back_forward_list.h", "public/ewk_back_forward_list_item.cc", @@ -432,6 +435,8 @@ shared_library("chromium-ewk") { "public/ewk_cookie_manager.h", "public/ewk_cookie_manager_internal.h", "public/ewk_cookie_manager_product.h", + "public/ewk_cookie_parser.cc", + "public/ewk_cookie_parser.h", "public/ewk_custom_handlers.cc", "public/ewk_custom_handlers_internal.h", "public/ewk_dispatcher.cc", @@ -465,6 +470,10 @@ shared_library("chromium-ewk") { "public/ewk_main.h", "public/ewk_main_internal.h", "public/ewk_manifest_internal.h", + "public/ewk_media_downloadable_font_info.h", + "public/ewk_media_downloadable_font_info_product.h", + "public/ewk_media_parental_rating_info.h", + "public/ewk_media_parental_rating_info_product.h", "public/ewk_media_playback_info.cc", "public/ewk_media_playback_info_product.h", "public/ewk_media_subtitle_info.cc", diff --git a/tizen_src/ewk/efl_integration/private/ewk_private.h b/tizen_src/ewk/efl_integration/private/ewk_private.h index 6447045..abf2702 100644 --- a/tizen_src/ewk/efl_integration/private/ewk_private.h +++ b/tizen_src/ewk/efl_integration/private/ewk_private.h @@ -8,10 +8,17 @@ #include +#include "base/logging.h" + #define COMPILE_ASSERT_MATCHING_ENUM(ewkName, webcoreName) \ COMPILE_ASSERT(int(ewkName) == int(webcoreName), mismatchingEnums) -// Temporarily added in order to track not-yet-implemented ewk api calls. -#include -#define LOG_EWK_API_MOCKUP(msg, ...) printf("[EWK_API_MOCKUP] %s:%d %s ", __FILE__, __LINE__, __PRETTY_FUNCTION__); printf(msg "\n", ##__VA_ARGS__) +#define LOG_EWK_API_MOCKUP(msg) \ + LOG(INFO) << "[EWK_API_MOCKUP] " \ + << " " << __FUNCTION__ << std::string(msg); + +#define LOG_EWK_API_DEPRECATED(msg) \ + LOG(WARNING) << "DEPRECATION WARNING: " << __FUNCTION__ \ + << " is deprecated and will be removed from next release." \ + << std::string(msg); #endif diff --git a/tizen_src/ewk/efl_integration/public/EWebKit.h b/tizen_src/ewk/efl_integration/public/EWebKit.h index 389bcb8..d110210 100644 --- a/tizen_src/ewk/efl_integration/public/EWebKit.h +++ b/tizen_src/ewk/efl_integration/public/EWebKit.h @@ -37,6 +37,7 @@ #include "ewk_geolocation.h" #include "ewk_intercept_request.h" #include "ewk_main.h" +#include "ewk_manifest.h" #include "ewk_policy_decision.h" #include "ewk_security_origin.h" #include "ewk_settings.h" diff --git a/tizen_src/ewk/efl_integration/public/EWebKit_internal.h b/tizen_src/ewk/efl_integration/public/EWebKit_internal.h index 4ac0c4b..6b2b0a1 100644 --- a/tizen_src/ewk/efl_integration/public/EWebKit_internal.h +++ b/tizen_src/ewk/efl_integration/public/EWebKit_internal.h @@ -36,6 +36,7 @@ #include "ewk_application_cache_manager_internal.h" #include "ewk_auth_challenge_internal.h" #include "ewk_auth_request_internal.h" +#include "ewk_autofill_credit_card_internal.h" #include "ewk_certificate_internal.h" #include "ewk_console_message_internal.h" #include "ewk_content_screening_detection_internal.h" diff --git a/tizen_src/ewk/efl_integration/public/EWebKit_product.h b/tizen_src/ewk/efl_integration/public/EWebKit_product.h index 471ec38..83ffcdc 100644 --- a/tizen_src/ewk/efl_integration/public/EWebKit_product.h +++ b/tizen_src/ewk/efl_integration/public/EWebKit_product.h @@ -33,11 +33,14 @@ #ifndef EWebKit_product_h #define EWebKit_product_h +#include "ewk_autofill_profile_product.h" #include "ewk_context_menu_product.h" #include "ewk_context_product.h" #include "ewk_cookie_manager_product.h" #include "ewk_form_repost_decision_product.h" #include "ewk_highcontrast_product.h" +#include "ewk_media_downloadable_font_info_product.h" +#include "ewk_media_parental_rating_info_product.h" #include "ewk_media_playback_info_product.h" #include "ewk_media_subtitle_info_product.h" #include "ewk_settings_product.h" diff --git a/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card.cc b/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card.cc new file mode 100644 index 0000000..86c7ef5 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card.cc @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2019 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "ewk_autofill_credit_card_internal.h" +#include "private/ewk_private.h" + +Ewk_Autofill_CreditCard* ewk_autofill_credit_card_new() +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +void ewk_autofill_credit_card_delete(Ewk_Autofill_CreditCard* credit_card) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_autofill_credit_card_data_set(Ewk_Autofill_CreditCard* credit_card, + Ewk_Autofill_Credit_Card_Data_Type type, const char* value) +{ + LOG_EWK_API_MOCKUP(); +} + +unsigned ewk_autofill_credit_card_id_get(Ewk_Autofill_CreditCard* credit_card) +{ + return 0; +} + +Eina_Stringshare* ewk_autofill_credit_card_data_get(Ewk_Autofill_CreditCard* credit_card, + Ewk_Autofill_Credit_Card_Data_Type type) +{ + return NULL; +} diff --git a/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card_internal.h b/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card_internal.h new file mode 100644 index 0000000..9aa25bb --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_autofill_credit_card_internal.h @@ -0,0 +1,182 @@ +/* + * Copyright (C) 2019 Samsung Electronics. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/** + * @file ewk_autofill_credit_card_internal.h + * @brief This file describes the Ewk Autofill CreditCard API. + */ + +#ifndef ewk_autofill_credit_card_internal_h +#define ewk_autofill_credit_card_internal_h + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @addtogroup WEBVIEW + * @{ + */ + +/** + * @if MOBILE + * \enum _Ewk_Autofill_Credit_Card_Data_Type + * @brief Enumeration that provides an option to autofill credit_card data types. + * + * @since_tizen 4.0 + * @endif + */ + +enum _Ewk_Autofill_Credit_Card_Data_Type { + EWK_CREDIT_CARD_ID = 0, + EWK_CREDIT_CARD_NAME_FULL, + EWK_CREDIT_CARD_NUMBER, + EWK_CREDIT_CARD_EXP_MONTH, + EWK_CREDIT_CARD_EXP_4_DIGIT_YEAR, + EWK_MAX_CREDIT_CARD +}; + +/** + * @if MOBILE + * @brief Enumeration that creates a type name for the Ewk_Autofill_Credit_Card_Data_Type. + * + * @since_tizen 4.0 + * @endif + */ +typedef enum _Ewk_Autofill_Credit_Card_Data_Type Ewk_Autofill_Credit_Card_Data_Type; + +/** + * @if MOBILE + * @brief The structure type that creates a type name for #Ewk_Autofill_CreditCard. + * + * @since_tizen 4.0 + * @endif + */ +typedef struct _Ewk_Autofill_CreditCard Ewk_Autofill_CreditCard; + +/** + * @if MOBILE + * @brief Creates a new credit_card + * + * The created credit_card must be deleted by ewk_autofill_credit_card_delete + * + * @since_tizen 4.0 + * + * @return @c Ewk_Autofill_CreditCard if new credit_card is successfully created, + @c NULL otherwise + * + * @see ewk_autofill_credit_card_data_set + * @see ewk_autofill_credit_card_delete + * @endif + */ +EXPORT_API Ewk_Autofill_CreditCard* ewk_autofill_credit_card_new(void); + +/** + * @if MOBILE + * @brief Deletes a given credit_card + * + * The API will delete the a particular credit_card only from the memory. + * To remove the credit_card permenantly use + * ewk_context_form_autofill_credit_card_remove + * + * @since_tizen 4.0 + * + * @param[in] credit_card name + * + * @see ewk_autofill_credit_card_new + * @see ewk_context_form_autofill_credit_card_get + * @see ewk_context_form_autofill_credit_card_remove + * @endif + */ +EXPORT_API void ewk_autofill_credit_card_delete(Ewk_Autofill_CreditCard* card); + +/** + * @if MOBILE + * @brief Sets the data in the credit_card created by ewk_autofill_credit_card_new + * + * The data set by this function is set locally. To save it to database use + * ewk_context_form_autofill_credit_card_add + * + * @since_tizen 4.0 + * + * @param[in] credit_card contains the credit_card data + * @param[in] type type of attribute to be set + * @param[in] value value of the attribute + * + * @see ewk_autofill_credit_card_data_get + * @see Ewk_Autofill_Credit_Card_Data_Type + * @see ewk_context_form_autofill_credit_card_add + * @endif + */ +EXPORT_API void ewk_autofill_credit_card_data_set(Ewk_Autofill_CreditCard* card, Ewk_Autofill_Credit_Card_Data_Type type, const char* value); + +/** + * @if MOBILE + * @brief Gets the id attribute value from a given credit_card + * + * The credit_card obtained from ewk_context_form_autofill_credit_card_get will be used + * to get the credit_cardid + * + * @param[in] credit_card name of credit_card + * + * @since_tizen 4.0 + * + * @return @c Value of attribute (unsigned), @c 0 otherwise + * + * @see ewk_autofill_credit_card_new + * @see ewk_context_form_autofill_credit_card_get + * @see ewk_context_form_autofill_credit_card_get_all + * @endif + */ +EXPORT_API unsigned ewk_autofill_credit_card_id_get(Ewk_Autofill_CreditCard* card); + +/** + * @if MOBILE + * @brief Gets the attribute value from a given credit_card + * + * The credit_card obtained from ewk_context_form_autofill_credit_card_get will be used + * to get the data + * + * @since_tizen 4.0 + * + * @param[in] credit_card name of credit_card + * @param[in] type name of attribute + * + * @return @c Value of attribute (Eina_Stringshare*), @c NULL otherwise + * The string should be released with eina_stringshare_del() + * + * @see ewk_autofill_credit_card_new + * @see ewk_context_form_autofill_credit_card_get + * @see ewk_context_form_autofill_credit_card_get_all + * @endif + */ +EXPORT_API Eina_Stringshare* ewk_autofill_credit_card_data_get(Ewk_Autofill_CreditCard* credit_card, Ewk_Autofill_Credit_Card_Data_Type type); + +/** +* @} +*/ + +#ifdef __cplusplus +} +#endif + +#endif // ewk_autofill_credit_card_internal_h + diff --git a/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.cc b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.cc index 8931ca2..2a223f1 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.cc @@ -24,7 +24,7 @@ */ #include "ewk_autofill_profile.h" - +#include "ewk_autofill_profile_product.h" #include "private/ewk_autofill_profile_private.h" #include "private/ewk_private.h" @@ -61,3 +61,45 @@ const char* ewk_autofill_profile_data_get(Ewk_Autofill_Profile* profile, return (retVal.empty()) ? NULL : strdup(retVal.c_str()); } + +Ewk_Form_Type ewk_autofill_profile_form_type_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return EWK_FORM_NONE; +} + +const char* ewk_autofill_profile_form_user_name_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} + +const char* ewk_autofill_profile_form_password_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} + +const char* ewk_autofill_profile_form_username_element_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} + +const char* ewk_autofill_profile_form_password_element_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} + +const char* ewk_autofill_profile_form_action_url_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} + +const char* ewk_autofill_profile_form_domain_get(Ewk_Form_Info* info) +{ + LOG_EWK_API_MOCKUP("This API is not supported"); + return NULL; +} diff --git a/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.h b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.h index 46a6e2c..f043b47 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.h +++ b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile.h @@ -99,7 +99,7 @@ EXPORT_API Ewk_Autofill_Profile* ewk_autofill_profile_new(void); * @brief Deletes a given profile * * The API will delete the a particular profile only from the memory. - * To remove the profile permenantly use + * To remove the profile permanently use * ewk_context_form_autofill_profile_remove * * @since_tizen 2.4 @@ -138,7 +138,7 @@ EXPORT_API void ewk_autofill_profile_data_set(Ewk_Autofill_Profile* profile, Ewk * @brief Gets the id attribute value from a given profile * * The profile obtained from ewk_context_form_autofill_profile_get will be used - * to get the profileid + * to get the profile id * * @param[in] profile name of profile * diff --git a/tizen_src/ewk/efl_integration/public/ewk_autofill_profile_product.h b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile_product.h new file mode 100644 index 0000000..d4a5d75 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_autofill_profile_product.h @@ -0,0 +1,179 @@ +/* + * Copyright (C) 2018-2019 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef ewk_autofill_profile_product_h +#define ewk_autofill_profile_product_h + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @addtogroup WEBVIEW + * @{ + */ + +/** + * @if TV + * @brief The structure type that creates a type name for #Ewk_Form_Info. + * + * @since_tizen 5.0 + * @endif + */ +typedef struct _Ewk_Form_Info Ewk_Form_Info; + +/** + * @if TV + * \enum _Ewk_Form_Type + * @brief Enumeration that provides an option to form types. + * + * @since_tizen 5.0 + * @endif + */ +enum _Ewk_Form_Type { + EWK_FORM_NONE = 0, + EWK_FORM_USERNAME, + EWK_FORM_PASSWORD, + EWK_FORM_BOTH +}; + +/** + * @if TV + * @brief Enumeration that creates a type name for the Ewk_Form_Type. + * + * @since_tizen 5.0 + * @endif + */ +typedef enum _Ewk_Form_Type Ewk_Form_Type; + +/** + * @if TV + * @brief Gets the form type from a given form information + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c Type of form + * + * @endif + */ +EXPORT_API Ewk_Form_Type ewk_autofill_profile_form_type_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the user name from a given form information + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c user name + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_user_name_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the password from a given form info + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c password + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_password_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the user name element from a given form info + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c user name element + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_username_element_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the password element from a given form info + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c password element + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_password_element_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the action url from a given form info + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c action url + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_action_url_get(Ewk_Form_Info* info); + +/** + * @if TV + * @brief Gets the domain from a given form info + * + * @since_tizen 5.0 + * + * @param[in] form information + * + * @return @c domain + * + * @endif + */ +EXPORT_API const char* ewk_autofill_profile_form_domain_get(Ewk_Form_Info* info); +/** +* @} +*/ + +#ifdef __cplusplus +} +#endif + +#endif // ewk_autofill_profile_product_h diff --git a/tizen_src/ewk/efl_integration/public/ewk_content_screening_detection_internal.h b/tizen_src/ewk/efl_integration/public/ewk_content_screening_detection_internal.h index 9e85273..e643ef9 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_content_screening_detection_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_content_screening_detection_internal.h @@ -37,28 +37,7 @@ extern "C" { typedef struct _Ewk_Content_Screening_Detection Ewk_Content_Screening_Detection; /** - * Set the variable to allow the release confirm about malware error. - * - * @param content_screening_detection malware information data - * - * @param confirmed decided permission value from user - */ -EXPORT_API void ewk_content_screening_detection_confirmed_set(Ewk_Content_Screening_Detection* content_screening_detection, Eina_Bool confirmed); - -/** - * Suspend the operation for content screening detection. - * - * This suspends the operation for content screening detection when the signal is emitted. - * This is very usefull to decide the policy from the additional UI operation like the popup. - * - * @param content_screening_detection malware information data - * - * @return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API void ewk_content_screening_detection_suspend(Ewk_Content_Screening_Detection* content_screening_detection); - -/** - * Get the variable errro structure to check the error cause about malware error. + * Get the variable error structure to check the error cause about malware error. * * @param content_screening_detection malware information data * diff --git a/tizen_src/ewk/efl_integration/public/ewk_context.cc b/tizen_src/ewk/efl_integration/public/ewk_context.cc index dcfb218..9765cddf 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_context.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_context.cc @@ -365,10 +365,8 @@ void ewk_context_memory_sampler_stop(Ewk_Context* context) Eina_Bool ewk_context_additional_plugin_path_set(Ewk_Context *context, const char *path) { - EINA_SAFETY_ON_NULL_RETURN_VAL(context, EINA_FALSE); - EINA_SAFETY_ON_NULL_RETURN_VAL(path, EINA_FALSE); - context->AddExtraPluginDir(path); - return true; + LOG_EWK_API_MOCKUP("Not Supported by chromium. Currently Deprecated"); + return EINA_FALSE; } void ewk_context_memory_saving_mode_set(Ewk_Context* context, Eina_Bool mode) @@ -803,12 +801,6 @@ void ewk_context_form_password_data_update(Ewk_Context* context, const char* url LOG_EWK_API_MOCKUP(); } -Eina_Bool ewk_context_background_music_set(Ewk_Context *ewkContext, Eina_Bool enable) -{ - LOG_EWK_API_MOCKUP(); - return false; -} - void ewk_context_application_type_set(Ewk_Context* ewkContext, const Ewk_Application_Type applicationType) { LOG_EWK_API_MOCKUP(); } @@ -825,3 +817,84 @@ void ewk_context_url_maxchars_set(Ewk_Context* context, size_t max_chars) { void ewk_context_service_worker_register(Ewk_Context* context, const char* scope_url, const char* script_url, Ewk_Context_Service_Worker_Registration_Result_Callback result_callback, void* user_data) { LOG_EWK_API_MOCKUP(); } + +void ewk_context_intercept_request_cancel_callback_set(Ewk_Context* ewk_context, Ewk_Context_Intercept_Request_Cancel_Callback callback, void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} + +Eina_Bool ewk_context_background_music_get(Ewk_Context* context) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_background_music_set(Ewk_Context* context, Eina_Bool enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_block_multimedia_on_call_get(Ewk_Context* context) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_block_multimedia_on_call_set(Ewk_Context* context, Eina_Bool enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_rotation_lock_get(Ewk_Context* context) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_rotation_lock_set(Ewk_Context* context, Eina_Bool enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_sound_overlap_get(Ewk_Context* context) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_sound_overlap_set(Ewk_Context* context, Eina_Bool enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_context_app_control_set(const Ewk_Context* context, void* app_control) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_context_max_refresh_rate_set(Ewk_Context* context, int max_refresh_rate) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_context_service_worker_unregister(Ewk_Context *context, const char* scope_url, Ewk_Context_Service_Worker_Unregistration_Result_Callback result_callback, void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_context_enable_app_control(Ewk_Context *context, Eina_Bool enabled) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_context_form_autofill_credit_card_changed_callback_set( + Ewk_Context_Form_Autofill_CreditCard_Changed_Callback callback, + void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} diff --git a/tizen_src/ewk/efl_integration/public/ewk_context.h b/tizen_src/ewk/efl_integration/public/ewk_context.h index b58b80b..3bd5db5 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_context.h +++ b/tizen_src/ewk/efl_integration/public/ewk_context.h @@ -60,15 +60,14 @@ extern "C" { typedef struct Ewk_Context Ewk_Context; /** - * \enum _Ewk_Cache_Model * @brief Contains option for cache model * * @since_tizen 2.4 */ enum _Ewk_Cache_Model { - EWK_CACHE_MODEL_DOCUMENT_VIEWER, /* Use the smallest cache capacity. */ - EWK_CACHE_MODEL_DOCUMENT_BROWSER, /* Use bigger cache capacity than EWK_CACHE_MODEL_DOCUMENT_VIEWER. */ - EWK_CACHE_MODEL_PRIMARY_WEBBROWSER /* Use the biggest cache capacity. */ + EWK_CACHE_MODEL_DOCUMENT_VIEWER, /**< Use the smallest cache capacity. */ + EWK_CACHE_MODEL_DOCUMENT_BROWSER, /**< Use bigger cache capacity than EWK_CACHE_MODEL_DOCUMENT_VIEWER. */ + EWK_CACHE_MODEL_PRIMARY_WEBBROWSER /**< Use the biggest cache capacity. */ }; /** @@ -105,7 +104,7 @@ EXPORT_API Eina_Bool ewk_context_application_cache_delete_all(Ewk_Context* conte /** * @brief Requests to set the cache model. * - * The default cache option is EWK_CACHE_MODEL_DOCUMENT_VIEWER. + * The default cache option is #EWK_CACHE_MODEL_DOCUMENT_VIEWER. * * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif * @@ -130,7 +129,7 @@ EXPORT_API Ewk_Cache_Model ewk_context_cache_model_get(const Ewk_Context* contex /** * @if MOBILE - * @brief Saves the created profile into permenant storage + * @brief Saves the created profile into permanent storage * * The profile used to save must be created by ewk_autofill_profile_new. * Data can be added to the created profile by ewk_autofill_profile_data_set. @@ -369,6 +368,126 @@ typedef void (*Ewk_Context_Intercept_Request_Callback)(Ewk_Context* ewk_context, EXPORT_API void ewk_context_intercept_request_callback_set(Ewk_Context* ewk_context, Ewk_Context_Intercept_Request_Callback callback, void* user_data); /** + * @brief Sets Ewk_Context_Intercept_Request_Cancel_Callback + * + * @details Sets Ewk_Context_Intercept_Request_Cancel_Callback to give a chance to + * notify intercept resource request to client when url request is cancelled. + * + * @remarks Pass NULL pointer as @a callback to reset current callback. + * + * + * @param[in] ewk_context Ewk_Context object to intercept requests + * @param[in] callback New callback, NULL resets current callback + * @param[in] user_data User data passed to @a callback + * + * @see Ewk_Context_Intercept_Request_Callback + */ + +typedef Ewk_Context_Intercept_Request_Callback Ewk_Context_Intercept_Request_Cancel_Callback; + +EXPORT_API void ewk_context_intercept_request_cancel_callback_set(Ewk_Context* ewk_context, Ewk_Context_Intercept_Request_Cancel_Callback callback, void* user_data); + +/** + * @brief Gets the enabled state of background music. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * + * @return @c EINA_TRUE if background music is enabled, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_background_music_get(Ewk_Context* context); + +/** + * @brief Sets the enabled state of background music. + * + * @details This function allows the application to continue playing instead of pausing when it moves to the background. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * @param[in] enable Enable or disable background music + * + * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_background_music_set(Ewk_Context* context, Eina_Bool enable); + +/** + * @brief Gets the enabled state of blocking multimedia on call. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * + * @return @c EINA_TRUE if blocking multimedia on call is enabled, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_block_multimedia_on_call_get(Ewk_Context* context); + +/** + * @brief Sets the enabled state of blocking multimedia on call. + * + * @details The application can set the flag to allow or disallow media playback during active call. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * @param[in] enable Enable or disable blocking multimedia on call + * + * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_block_multimedia_on_call_set(Ewk_Context* context, Eina_Bool enable); + +/** + * @brief Gets the enabled state of rotation lock. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * + * @return @c EINA_TRUE if rotation lock is enabled, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_rotation_lock_get(Ewk_Context* context); + +/** + * @brief Sets the enabled state of rotation lock. + * + * @details The application can use this function to lock the auto screen rotation feature. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * @param[in] enable Enable or disable rotation lock + * + * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_rotation_lock_set(Ewk_Context* context, Eina_Bool enable); + +/** + * @brief Gets the enabled state of sound overlap. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * + * @return @c EINA_TRUE if sound overlap is enabled, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_sound_overlap_get(Ewk_Context* context); + +/** + * @brief Sets the enabled state of sound overlap. + * + * @details The application can set the flag to allow or disallow the sound overlap with other apps. + * + * @since_tizen 4.0 + * + * @param[in] context The context object + * @param[in] enable Enable or disable sound overlap + * + * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise + */ +EXPORT_API Eina_Bool ewk_context_sound_overlap_set(Ewk_Context* context, Eina_Bool enable); + +/** * @} */ diff --git a/tizen_src/ewk/efl_integration/public/ewk_context_internal.h b/tizen_src/ewk/efl_integration/public/ewk_context_internal.h index 50df975..a087de0 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_context_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_context_internal.h @@ -167,14 +167,6 @@ typedef void (*Ewk_Web_Database_Quota_Get_Callback)(uint64_t quota, void* user_d //typedef void (*Ewk_Web_Database_Path_Get_Callback)(const char* path, void* user_data); /** - * Callback for ewk_context_web_storage_origins_get. - * - * @param origins web storage origins - * @param user_data user_data will be passsed when ewk_context_web_storage_origins_get is called - */ -typedef void (*Ewk_Web_Storage_Origins_Get_Callback)(Eina_List* origins, void* user_data); - -/** * Callback for didStartDownload * * @param download_url url to download @@ -199,10 +191,28 @@ typedef Eina_Bool (*Ewk_Context_Override_Mime_For_Url_Callback)(const char* url, /* * Callback for changed profiles. * - * @param user_data user_data will be passsed when download is started + * @param data user data will be passed when autofill profile is changed */ typedef void (*Ewk_Context_Form_Autofill_Profile_Changed_Callback)(void *data); +/* + * Callback for changed credit_cards. + * + * @param data user data will be passed when credit card is changed + */ +typedef void (*Ewk_Context_Form_Autofill_CreditCard_Changed_Callback)(void *data); + +/** + * Sets callback for credit_cards change notification. + * + * @param callback pointer to callback function + * @param user_data user data returned on callback + * + */ +EXPORT_API void ewk_context_form_autofill_credit_card_changed_callback_set( + Ewk_Context_Form_Autofill_CreditCard_Changed_Callback callback, + void* user_data); + /** * Requests for freeing origins. * @@ -497,7 +507,7 @@ EXPORT_API Ewk_Context *ewk_context_new_with_injected_bundle_path_in_incognito_m * * @return @c EINA_TRUE if the directory was set, @c EINA_FALSE otherwise */ -EXPORT_API Eina_Bool ewk_context_additional_plugin_path_set(Ewk_Context *context, const char *path); +EINA_DEPRECATED EXPORT_API Eina_Bool ewk_context_additional_plugin_path_set(Ewk_Context *context, const char *path); /** * Sets vibration client callbacks to handle the tactile feedback in the form of @@ -532,13 +542,14 @@ EXPORT_API void ewk_context_form_autofill_profile_changed_callback_set( * The obtained profile must be deleted by ewk_autofill_profile_delete. * * @param context context object - * @param profile id + * @param id profile id * * @return @c Ewk_Autofill_Profile if profile exists, @c NULL otherwise * @see ewk_autofill_profile_delete */ EXPORT_API Ewk_Autofill_Profile* ewk_context_form_autofill_profile_get(Ewk_Context* context, unsigned id); + /** * Get tizen extensible api enable state * @@ -712,6 +723,17 @@ EXPORT_API Ewk_Storage_Manager *ewk_context_storage_manager_get(const Ewk_Contex */ EXPORT_API Eina_Bool ewk_context_web_database_delete_all(Ewk_Context* context); +/** + * Sets app_control. + * + * @param context context object + * @param app_control app_control handle. + * + * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise + * + */ +EXPORT_API Eina_Bool ewk_context_app_control_set(const Ewk_Context* context, void* app_control); + EXPORT_API Eina_Bool ewk_context_notification_callbacks_set(Ewk_Context* context, Ewk_Context_Notification_Show_Callback show_callback, Ewk_Context_Notification_Cancel_Callback cancel_callback, void* user_data); @@ -742,6 +764,16 @@ EXPORT_API void ewk_context_timezone_offset_set(Ewk_Context* context, double time_zone_offset, double daylight_saving_time); +/** + * Sets max refresh rate for @a context. + * + * @param context context object + * @param max_refresh_rate screen FPS will not exceed max_refresh_rate. It can + * be from @c 1 to @c 60 + */ +EXPORT_API void ewk_context_max_refresh_rate_set(Ewk_Context* context, + int max_refresh_rate); + enum _Ewk_Audio_Latency_Mode { EWK_AUDIO_LATENCY_MODE_LOW = 0, /**< Low audio latency mode */ EWK_AUDIO_LATENCY_MODE_MID, /**< Middle audio latency mode */ @@ -788,7 +820,7 @@ typedef void (*Ewk_Push_Message_Cb)(const char *sender_id, const char *push_data * NULL for the callbacks. * * @param context context object to set vibration client callbacks. - * @param push call funstion when the send the web push message from the + * @param push call function when the send the web push message from the * controller (may be @c NULL). * @param user_data User data (may be @c NULL). * @@ -829,6 +861,37 @@ typedef void (*Ewk_Context_Service_Worker_Registration_Result_Callback)(Ewk_Cont */ EXPORT_API void ewk_context_service_worker_register(Ewk_Context* context, const char* scope_url, const char* script_url, Ewk_Context_Service_Worker_Registration_Result_Callback result_callback, void* user_data); +/** + * Result callback for @a ewk_context_service_worker_unregister api. + * + * @param context context object + * @param scope_url scope url for which service worker unregistration was called + * @param result @c EINA_TRUE on success or @c EINA_FALSE on failure + * @param user_data user data passed to @a ewk_context_service_worker_unregister api + */ +typedef void (*Ewk_Context_Service_Worker_Unregistration_Result_Callback)(Ewk_Context *context, const char* scope_url, Eina_Bool result, void* user_data); + +/** + * Unregister service worker for scope. + * + * @param context context object + * @param scope_url scope url for which service worker should be registered + * @param result_callback result callback + * @param user_data user data to be passed to @a result_callback + */ +EXPORT_API void ewk_context_service_worker_unregister(Ewk_Context *context, const char* scope_url, Ewk_Context_Service_Worker_Unregistration_Result_Callback result_callback, void* user_data); + +/** + * Sets whether to allow app control scheme(appcontrol://) or not. + * + * @since_tizen 5.0 + * + * @param[in] context context object to enable/disable app control scheme + * @param[in] enabled a state to set + * + */ +EXPORT_API void ewk_context_enable_app_control(Ewk_Context *context, Eina_Bool enabled); + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_context_menu.h b/tizen_src/ewk/efl_integration/public/ewk_context_menu.h index b41c786..bf01ce4 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_context_menu.h +++ b/tizen_src/ewk/efl_integration/public/ewk_context_menu.h @@ -134,7 +134,7 @@ enum _Ewk_Context_Menu_Item_Tag{ EWK_CONTEXT_MENU_ITEM_TAG_CLIPBOARD, /**< Clipboard */ EWK_CONTEXT_MENU_ITEM_TAG_DRAG, /**< Drag */ EWK_CONTEXT_MENU_ITEM_TAG_TRANSLATE, /**< Translate */ - EWK_CONTEXT_MENU_ITEM_TAG_COPY_LINK_DATA, /**< Copy lnk data */ + EWK_CONTEXT_MENU_ITEM_TAG_COPY_LINK_DATA, /**< Copy link data */ EWK_CONTEXT_MENU_ITEM_BASE_APPLICATION_TAG = 10000 /**< If app want to add customized item, use enum value after #EWK_CONTEXT_MENU_ITEM_BASE_APPLICATION_TAG */ }; diff --git a/tizen_src/ewk/efl_integration/public/ewk_context_product.h b/tizen_src/ewk/efl_integration/public/ewk_context_product.h index 2ab4676..79370a3 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_context_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_context_product.h @@ -106,17 +106,6 @@ EXPORT_API void ewk_context_proxy_set(Ewk_Context* context, const char* bypass_rule); /** - * @brief Sets the given proxy URI to network backend of specific context. - * - * @since_tizen 2.3 - * - * @param[in] context object to set proxy URI - * @param[in] proxy URI to set - */ -EXPORT_API void ewk_context_proxy_uri_set(Ewk_Context* context, - const char* proxy); - -/** * @brief Gets the proxy URI from the network backend of specific context. * * @details It returns an internal string and should not\n @@ -830,7 +819,7 @@ EXPORT_API void ewk_context_disable_nosniff_set(Ewk_Context* context, Eina_Bool * @param empCAPath Path to certificate files downloaded via EMP * @param defaultCAPath Path to certificate files have been used */ -EXPORT_API void ewk_context_emp_certificate_file_set(Ewk_Context *context, const char* empCAPath, const char* defaultCAPath); +EXPORT_API void ewk_context_emp_certificate_file_set(Ewk_Context *context, const char* emp_ca_path, const char* default_ca_path); /** * @brief Requests for getting web database usage for origin. @@ -865,18 +854,6 @@ EXPORT_API Eina_Bool ewk_context_web_database_usage_for_origin_get(Ewk_Context* EXPORT_API void ewk_context_form_password_data_update(Ewk_Context* context, const char* url, Eina_Bool useFingerprint); /** - * @brief Toggles tizen background music property enable and disable - * - * @since_tizen 2.3.2 - * - * @param[in] context context object - * @param[in] enable enable or disable tizen background music property - * - * @return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API Eina_Bool ewk_context_background_music_set(Ewk_Context *ewkContext, Eina_Bool enable); - -/** * @brief Sets the list of preferred languages. * * @details This function sets the list of preferred langages.\n @@ -895,47 +872,18 @@ EXPORT_API Eina_Bool ewk_context_background_music_set(Ewk_Context *ewkContext, E EXPORT_API void ewk_context_preferred_languages_set(Eina_List* languages); /** - * @brief Set WebSDI. - * To use WebSDI for client authentication, - * 'web-sdi' metadata need to be added in config.xml of each app. - * In that case, XWalk will call ewk_context_websdi_set API with true - * value. - * - * @param enable true means app wants to get a Client Certificate as WebSDI, - * otherwise, false - */ -EXPORT_API void ewk_context_websdi_set(Eina_Bool enable); - -/** * Sets PWA storage path @a context. * * @param context context object * @param pwa_storage_path PWA storage path * - * @return @c EINA_TRUE if the pwa_storage_path set successfully, @c EINA_FALSE - * otherwise - */ -EXPORT_API Eina_Bool -ewk_context_pwa_storage_path_set(Ewk_Context* context, - const char* pwa_storage_path); - -/** - * @brief Sets callback for checking file request accessibility. When requested - * to load a file, need to invoke the callback to check whether the file - * path is accessible - * - * @param context context object - * @param callback The callback of Ewk_Context_Check_Accessible_Path_Callback - * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise + * @return @c EINA_TRUE if the pwa_storage_path set successfully, @c EINA_FALSE otherwise */ -EXPORT_API Eina_Bool ewk_context_check_accessible_path_callback_set( - Ewk_Context* context, - Ewk_Context_Check_Accessible_Path_Callback callback, - void* user_data); +EXPORT_API Eina_Bool ewk_context_pwa_storage_path_set(Ewk_Context *context, const char *pwa_storage_path); /** - * @} - */ +* @} +*/ #ifdef __cplusplus } diff --git a/tizen_src/ewk/efl_integration/public/ewk_cookie_manager.h b/tizen_src/ewk/efl_integration/public/ewk_cookie_manager.h index aa5f361..f4a0eaa 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_cookie_manager.h +++ b/tizen_src/ewk/efl_integration/public/ewk_cookie_manager.h @@ -80,7 +80,7 @@ EXPORT_API void ewk_cookie_manager_accept_policy_set(Ewk_Cookie_Manager* manager * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif * * @param[in] policy A #Ewk_Cookie_Accept_Policy - * @param[in] event_info The user data that will be passsed when + * @param[in] event_info The user data that will be passed when * ewk_cookie_manager_accept_policy_async_get() is called */ typedef void (*Ewk_Cookie_Manager_Policy_Async_Get_Cb)(Ewk_Cookie_Accept_Policy policy, void* event_info); @@ -135,7 +135,7 @@ EXPORT_API void ewk_cookie_manager_file_scheme_cookies_allow_set(Ewk_Cookie_Mana * @since_tizen 3.0 */ enum Ewk_Cookie_Persistent_Storage { - EWK_COOKIE_PERSISTENT_STORAGE_TEXT, /**< Cookies are stored in a text file in the Mozilla "cookies.txt" format. */ + EWK_COOKIE_PERSISTENT_STORAGE_TEXT, /**< @deprecated Cookies are stored in a text file in the Mozilla "cookies.txt" format. (Deprecated since 6.0) */ EWK_COOKIE_PERSISTENT_STORAGE_SQLITE /**< Cookies are stored in a SQLite file in the current Mozilla format. */ }; @@ -151,7 +151,7 @@ typedef enum Ewk_Cookie_Persistent_Storage Ewk_Cookie_Persistent_Storage; * * @details Cookies are initially read from @a path/Cookies to create an initial * set of cookies. Then, non-session cookies will be written to @a path/Cookies. - * By default, @a manager doesn't store the cookies persistenly, so you need to + * By default, @a manager doesn't store the cookies persistently, so you need to * call this method to keep cookies saved across sessions. * If @a path does not exist it will be created. * diff --git a/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.cc b/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.cc new file mode 100644 index 0000000..b4e41b2 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.cc @@ -0,0 +1,59 @@ +/** + * @file ewk_cookie_parser + * @brief EWK Cookie Parser + * + * This class exposes the Chromium cookie parser. It allows + * for ewk components to handle cookie-alike structures without + * re-inventing the wheel. + * + * Copyright 2020 by Samsung Electronics, Inc., + * + * This software is the confidential and proprietary information + * of Samsung Electronics, Inc. ("Confidential Information"). You + * shall not disclose such Confidential Information and shall use + * it only in accordance with the terms of the license agreement + * you entered into with Samsung. + */ + +#include "ewk_cookie_parser.h" + +#include +#include +#include "net/cookies/cookie_util.h" +#include "net/cookies/parsed_cookie.h" +#include "private/ewk_private.h" + +#ifdef __cplusplus +extern "C" { +#endif + +EXPORT_API Eina_Bool ewk_parse_cookie(const std::string& cookie_str, + EWKCookieContents& cookie) { + net::ParsedCookie new_cookie(cookie_str); + if (!new_cookie.IsValid() || new_cookie.IsHttpOnly() || new_cookie.IsSecure()) + return EINA_FALSE; + + cookie.name = new_cookie.Name(); + cookie.value = new_cookie.Value(); + cookie.domain = new_cookie.Domain(); + cookie.path = new_cookie.Path(); + + // Take "max-age" over "Expires" as expires is depreciated, so only supported + // for backwards compatibility. With the assumption that if you are using both + // then "Expires" is there to support old browsers. (see HTTP - spec). + if (new_cookie.HasMaxAge()) { + cookie.expiry_date_utc = time(nullptr) + stoi(new_cookie.MaxAge()); + } else if (new_cookie.HasExpires()) { + base::Time expiration_time = + net::cookie_util::ParseCookieExpirationTime(new_cookie.Expires()); + cookie.expiry_date_utc = expiration_time.ToTimeT(); + } else { + // This is a session cookie. Set expiry time to 0 + cookie.expiry_date_utc = 0; + } + return EINA_TRUE; +} + +#ifdef __cplusplus +} +#endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.h b/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.h new file mode 100644 index 0000000..3ed298a --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_cookie_parser.h @@ -0,0 +1,77 @@ +/** + * @file ewk_cookie_parser + * @brief EWK Cookie Parser + * + * This class exposes the Chromium cookie parser. It allows + * for ewk components to handle cookie-alike structures without + * re-inventing the wheel. + * + * Copyright 2020 by Samsung Electronics, Inc., + * + * This software is the confidential and proprietary information + * of Samsung Electronics, Inc. ("Confidential Information"). You + * shall not disclose such Confidential Information and shall use + * it only in accordance with the terms of the license agreement + * you entered into with Samsung. + */ + +#ifndef __EWK_COOKIE_PARSER_H__ +#define __EWK_COOKIE_PARSER_H__ + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @addtogroup WEBVIEW + */ + +/** + * @brief This structure is used to return the contents of the parsed cookie. + * This structure is used a bridge between the Chromium cookie handling code + * and the calling application. + */ +struct EWKCookieContents { + time_t expiry_date_utc; + std::string domain; + std::string name; + std::string path; + std::string value; +}; + +/** + * @brief Parses a Cookie String and Returns the Contents. + * + * @details The application can use this function use the internal Cookie + * parsing code to decode cookie strings. This allows the calling + * application to manage non-standard cookies without effecting the + * security policies that have been set up in Chromium. These can be + * used for non-standard schemes the may want to use cookies. + * + * The cookie is only treated as valid if it should be readably by a + * javascript function. I.e. if the HttpOnly and Secure flags are not + * set. It is the responsibility of the calling application to check to + * see if the cookies expiry_date has expired. + * + * NOTE: if the cookie has an expiry_date == 0 then the cookie should + * be treated as a session cookie. + * + * @since_tizen 4.0 + * + * @param[in] cookie_str The cookie string to be decoded. + * @param[out] cookie The decoded cookie data. + * + * @return @c true if the cookie string is value, else false. + */ +EXPORT_API Eina_Bool ewk_parse_cookie(const std::string& cookie_str, + EWKCookieContents& cookie); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_error.cc b/tizen_src/ewk/efl_integration/public/ewk_error.cc index 4d9b715..0ca98e2 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_error.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_error.cc @@ -44,7 +44,7 @@ Ewk_Error_Type ewk_error_type_get(const Ewk_Error* error) return EWK_ERROR_TYPE_NETWORK; } - LOG_EWK_API_MOCKUP("Unknown error domain: %s", error->domain); + LOG(ERROR) << "Unknown error domain: " << error->domain; return EWK_ERROR_TYPE_NONE; } diff --git a/tizen_src/ewk/efl_integration/public/ewk_geolocation.h b/tizen_src/ewk/efl_integration/public/ewk_geolocation.h index 8227c697d..aa8f3cf 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_geolocation.h +++ b/tizen_src/ewk/efl_integration/public/ewk_geolocation.h @@ -18,7 +18,7 @@ /** * @file ewk_geolocation.h - * @brief This file describes the Ewk Geolacation API. + * @brief This file describes the Ewk Geolocation API. */ #ifndef ewk_geolocation_h @@ -33,6 +33,11 @@ extern "C" { #endif /** + * @addtogroup WEBVIEW + * @{ + */ + +/** * @brief The structure type that creates a type name for #Ewk_Geolocation_Permission_Request. * * @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_highcontrast_product.h b/tizen_src/ewk/efl_integration/public/ewk_highcontrast_product.h index 7f084f5..9bddee6 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_highcontrast_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_highcontrast_product.h @@ -56,7 +56,8 @@ EXPORT_API Eina_Bool ewk_highcontrast_enabled_get(); * If the current page's url contains this url, it should not use highcontrast filter * * @param url URL that should not apply hightcontrast filter - * @return EINA_TRUE if successfully added + * @return @c EINA_TRUE if successfully added or @c EINA_FALSE otherwise + Note that add a reduplicative url will return EINA_FALSE */ EXPORT_API Eina_Bool ewk_highcontrast_forbidden_url_add(const char* url); @@ -64,7 +65,8 @@ EXPORT_API Eina_Bool ewk_highcontrast_forbidden_url_add(const char* url); * Remove the specific highcontrast forbidden URL. * * @param url URL that already in the forbidden url list - * @return EINA_TRUE if successfully removed + * @return @c EINA_TRUE if successfully removed or @c EINA_FALSE otherwise + Note that if the url is not exist in the list it will return EINA_FALSE */ EXPORT_API Eina_Bool ewk_highcontrast_forbidden_url_remove(const char* url); diff --git a/tizen_src/ewk/efl_integration/public/ewk_intercept_request.h b/tizen_src/ewk/efl_integration/public/ewk_intercept_request.h index f2845805..967558c 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_intercept_request.h +++ b/tizen_src/ewk/efl_integration/public/ewk_intercept_request.h @@ -55,7 +55,7 @@ typedef struct _Ewk_Intercept_Request Ewk_Intercept_Request; * @since_tizen 3.0 * * @param[in] intercept_request intercept request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * * @return @c url string on success or NULL on failure */ @@ -71,7 +71,7 @@ EXPORT_API const char* ewk_intercept_request_url_get( * @since_tizen 3.0 * * @param[in] intercept_request intercept request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * * @return @c method string on success or NULL on failure */ @@ -87,7 +87,7 @@ EXPORT_API const char* ewk_intercept_request_http_method_get( * @since_tizen 3.0 * * @param[in] intercept_request intercept request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * * @return @c Eina_Hash mapping from header name string to header value string * on success or NULL on failure @@ -106,12 +106,12 @@ EXPORT_API const Eina_Hash* ewk_intercept_request_headers_get( * the Ewk_Intercept_Request instance result in undefined behavior. * * Only use this function from inside the - * Ewk_Context_Intercept_Request_Callback. + * #Ewk_Context_Intercept_Request_Callback. * * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received in - * Ewk_Context_Intercept_Request_Callback + * #Ewk_Context_Intercept_Request_Callback * * @return @c EINA_TRUE on success or @c EINA_FALSE on failure */ @@ -126,7 +126,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_ignore( * for the intercepted request. * * @remarks It is allowed to use this function both inside and outside - * the Ewk_Context_Intercept_Request_Callback. + * the #Ewk_Context_Intercept_Request_Callback. * * After this call, handling the request is done. Any further calls on * the Ewk_Intercept_Request instance result in undefined behavior. @@ -136,11 +136,11 @@ EXPORT_API Eina_Bool ewk_intercept_request_ignore( * * Alternatively you can use following functions which are more * convenient: - * - ewk_intercept_request_response_status_set - * - ewk_intercept_request_response_header_add - * - ewk_intercept_request_response_header_map_add - * - ewk_intercept_request_response_body_set - * - ewk_intercept_request_response_write_chunk + * - ewk_intercept_request_response_status_set() + * - ewk_intercept_request_response_header_add() + * - ewk_intercept_request_response_header_map_add() + * - ewk_intercept_request_response_body_set() + * - ewk_intercept_request_response_write_chunk() * * Using this function overrides status and headers set with functions * listed above. @@ -148,7 +148,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_ignore( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * @param[in] headers Null-terminated string representing response's headers * for the intercept request. * By HTTP spec, lines should end with a newline ('\\r\\n') and @@ -166,7 +166,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_set( * @brief Sets status code and status text of response for intercepted request. * * @remarks It is allowed to use this function both inside and outside the - * Ewk_Context_Intercept_Request_Callback. + * #Ewk_Context_Intercept_Request_Callback. * * In case of failure of this function finish writing for this * intercept request. @@ -174,7 +174,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_set( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * @param[in] status_code HTTP response status code * @param[in] custom_status_text HTTP response reason phrase, pass NULL to use * recommended reason phrase (example: "OK" for code 200) @@ -189,7 +189,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_status_set( * @brief Adds HTTP header to response for intercepted request. * * @remarks It is allowed to use this function both inside and outside - * the Ewk_Context_Intercept_Request_Callback. + * the #Ewk_Context_Intercept_Request_Callback. * * In case of failure of this function finish writing for this * intercept request. @@ -197,7 +197,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_status_set( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * @param[in] field_name HTTP header field name * @param[in] field_value HTTP header field value * @@ -211,7 +211,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_header_add( * @brief Adds HTTP headers to response for intercepted request. * * @remarks It is allowed to use this function both inside and outside - * the Ewk_Context_Intercept_Request_Callback. + * the #Ewk_Context_Intercept_Request_Callback. * * In case of failure of this function finish writing for this * intercept request. @@ -219,7 +219,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_header_add( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback. + * #Ewk_Context_Intercept_Request_Callback ewk_context callback. * @param[in] headers Map from HTTP header field names to field values, both * represented as null terminated strings * @@ -236,7 +236,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_header_map_add( * intercepted request. * * @remarks It is allowed to use this function both inside and outside - * the Ewk_Context_Intercept_Request_Callback. + * the #Ewk_Context_Intercept_Request_Callback. * * After this call, handling the request is done. Any further calls on * the Ewk_Intercept_Request instance result in undefined behavior. @@ -247,7 +247,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_header_map_add( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * @param[in] body Response body for the intercept request * @param[in] length Length of response body * @@ -255,9 +255,9 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_header_map_add( * * @pre Before writing response body, you should set response status and * headers using the following functions: - * - ewk_intercept_request_response_status_set - * - ewk_intercept_request_response_header_add - * - ewk_intercept_request_response_header_map_add + * - ewk_intercept_request_response_status_set() + * - ewk_intercept_request_response_header_add() + * - ewk_intercept_request_response_header_map_add() * */ EXPORT_API Eina_Bool ewk_intercept_request_response_body_set( @@ -275,10 +275,10 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_body_set( * Any further calls on the Ewk_Intercept_Request instance result in * undefined behavior. User should always check return value, because * response to this request might not be needed anymore, and function - * can retrun EINA_FALSE even though user still has data to write. + * can return EINA_FALSE even though user still has data to write. * * It is only allowed to use this function *outside* of the - * Ewk_Context_Intercept_Request_Callback. + * #Ewk_Context_Intercept_Request_Callback. * * If a part of response body has been written with this function, you * can't use the following functions anymore: @@ -293,7 +293,7 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_body_set( * @since_tizen 3.0 * * @param[in] intercept_request Intercept Request instance received from - * Ewk_Context_Intercept_Request_Callback ewk_context callback + * #Ewk_Context_Intercept_Request_Callback ewk_context callback * @param[in] chunk Part of response body for intercepted request * @param[in] length Length of response body part * @@ -301,9 +301,9 @@ EXPORT_API Eina_Bool ewk_intercept_request_response_body_set( * * @pre Before writing response body, you should set response status * and headers using the following functions: - * - ewk_intercept_request_response_status_set - * - ewk_intercept_request_response_header_add - * - ewk_intercept_request_response_header_map_add + * - ewk_intercept_request_response_status_set() + * - ewk_intercept_request_response_header_add() + * - ewk_intercept_request_response_header_map_add() * * @post After writing full response body in chunks using this function, call * it again with NULL as @a chunk and 0 as @a length, to signal that diff --git a/tizen_src/ewk/efl_integration/public/ewk_main.cc b/tizen_src/ewk/efl_integration/public/ewk_main.cc index 13b61fb..e20617b 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_main.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_main.cc @@ -190,6 +190,16 @@ void ewk_set_arguments(int argc, char** argv) CommandLineEfl::Init(argc, argv); } +void ewk_process_model_set(Ewk_Process_Model process_model) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_memory_optimization_mode_enable(void) +{ + LOG_EWK_API_MOCKUP(); +} + void ewk_home_directory_set(const char* path) { if (!path) diff --git a/tizen_src/ewk/efl_integration/public/ewk_main_internal.h b/tizen_src/ewk/efl_integration/public/ewk_main_internal.h index 68ff729..a787025 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_main_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_main_internal.h @@ -38,6 +38,56 @@ extern "C" { #endif +enum Ewk_Process_Model { + EWK_PROCESS_MODEL_MULTI, + EWK_PROCESS_MODEL_MULTI_WITH_SINGLE_RENDERER, + EWK_PROCESS_MODEL_SINGLE, +}; + +/** + * @brief Enumeration that creates a type name for the #Ewk_Process_Model. + * @since_tizen 6.0 + */ +typedef enum Ewk_Process_Model Ewk_Process_Model; + +/** + * @brief Decide which process model to use to launch Chromium + * + * Must be called before the following APIs:\n + * ewk_view_add\n + * ewk_view_add_in_incognito_mode\n + * ewk_view_add_with_context\n + * ewk_view_add_with_session_data\n + * ewk_context_default_get\n + * ewk_context_new\n + * ewk_context_new_with_injected_bundle_path + * + * @details Choose process model from single process model, + * multi process model and multi process model with single renderer process. + * + * @since_tizen 6.0 + */ +EXPORT_API void ewk_process_model_set(Ewk_Process_Model process_model); + +/** + * @brief Enable memory optimization mode. + * + * Must be called before the following APIs:\n + * ewk_view_add\n + * ewk_view_add_in_incognito_mode\n + * ewk_view_add_with_context\n + * ewk_view_add_with_session_data\n + * ewk_context_default_get\n + * ewk_context_new\n + * ewk_context_new_with_injected_bundle_path + * + * @details Memory optimization mode decreases memory usage especially graphic related. + * But, it could cause performance degradations. + * + * @since_tizen 6.0 + */ +EXPORT_API void ewk_memory_optimization_mode_enable(void); + /** * Set argument count and argument vector. * @@ -81,12 +131,13 @@ extern "C" { EXPORT_API void ewk_set_arguments(int argc, char** argv); /** +* Deprecated. * Set home directory. * * If new path is NULL or empty string, home directory is considered as not set. * */ -EXPORT_API void ewk_home_directory_set(const char* path); +EINA_DEPRECATED EXPORT_API void ewk_home_directory_set(const char* path); #ifdef __cplusplus } diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info.h b/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info.h new file mode 100644 index 0000000..9f7f099 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info.h @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2018 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef ewk_media_downloadable_font_info_h +#define ewk_media_downloadable_font_info_h + +#include "ewk_media_downloadable_font_info_product.h" +#include "private/ewk_private.h" + +#ifdef __cplusplus +extern "C" { +#endif + +Ewk_Media_Downloadable_Font_Info* ewkMediaDownloadableFontInfoCreate( + const char* schemeIdUri, + const char* value, + const char* data, + int type) { + Ewk_Media_Downloadable_Font_Info* font_info = new Ewk_Media_Downloadable_Font_Info; + font_info->schemeIdUri = eina_stringshare_add(schemeIdUri ? schemeIdUri : ""); + font_info->value = eina_stringshare_add(value ? value : ""); + font_info->data = eina_stringshare_add(data ? data : ""); + font_info->type = type; + return font_info; +} + +void ewkMediaDownloadableFontInfoDelete(Ewk_Media_Downloadable_Font_Info* font_info) { + if (font_info->schemeIdUri) + eina_stringshare_del(font_info->schemeIdUri); + if (font_info->value) + eina_stringshare_del(font_info->value); + if (font_info->data) + eina_stringshare_del(font_info->data); + delete font_info; +} + +#ifdef __cplusplus +} +#endif +#endif // ewk_media_downloadable_font_info_h \ No newline at end of file diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info_product.h b/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info_product.h new file mode 100644 index 0000000..27ab600 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_media_downloadable_font_info_product.h @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2018 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef ewk_media_downloadable_font_info_product_h +#define ewk_media_downloadable_font_info_product_h + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +typedef struct _Ewk_Media_Downloadable_Font_Info { + const char* schemeIdUri; + const char* value; + const char* data; + int type; +}Ewk_Media_Downloadable_Font_Info; + +#ifdef __cplusplus +} +#endif +#endif // ewk_media_downloadable_font_info_product_h \ No newline at end of file diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info.h b/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info.h new file mode 100644 index 0000000..988c65d --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info.h @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2018 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/** + * @file ewk_media_parental_rating_info.h + * @brief This file describes the ewk media parental rating info API. + */ + +#ifndef ewk_media_parental_rating_info_h +#define ewk_media_parental_rating_info_h + + +#include "ewk_media_parental_rating_info_product.h" +#include "private/ewk_private.h" + + +#ifdef __cplusplus +extern "C" { +#endif + +Ewk_Media_Parental_Rating_Info* ewkMediaParentalRatingInfoCreate(const char* info, + const char* url) { + Ewk_Media_Parental_Rating_Info* data = new Ewk_Media_Parental_Rating_Info; + data->parentalInfoStr = eina_stringshare_add(info ? info : ""); + data->url = eina_stringshare_add(url ? url : ""); + return data; +} + +void ewkMediaParentalRatingInfoDelete(Ewk_Media_Parental_Rating_Info* data) { + if (data->parentalInfoStr) + eina_stringshare_del(data->parentalInfoStr); + if (data->url) + eina_stringshare_del(data->url); + delete data; +} + +#ifdef __cplusplus +} +#endif +#endif // ewk_media_parental_rating_info_h diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info_product.h b/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info_product.h new file mode 100644 index 0000000..529b648 --- /dev/null +++ b/tizen_src/ewk/efl_integration/public/ewk_media_parental_rating_info_product.h @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2018 Samsung Electronics. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/** + * @file ewk_media_playback_info_product.h + * @brief This file describes the ewk media playback info API. + */ + +#ifndef ewk_media_parental_rating_info_product_h +#define ewk_media_parental_rating_info_product_h + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +typedef struct _Ewk_Media_Parental_Rating_Info { + const char* parentalInfoStr; + const char* url; +}Ewk_Media_Parental_Rating_Info; + +#ifdef __cplusplus +} +#endif +#endif // ewk_media_playback_info_product_h diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.cc b/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.cc index d5b4991..91a50f8 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.cc @@ -52,7 +52,7 @@ const char* ewk_media_playback_info_drm_info_get( void ewk_media_playback_info_media_resource_acquired_set( Ewk_Media_Playback_Info* data, - unsigned char media_resource_acquired) { + Eina_Bool media_resource_acquired) { LOG_EWK_API_MOCKUP(); } @@ -65,3 +65,30 @@ void ewk_media_playback_info_drm_info_set(Ewk_Media_Playback_Info* data, const char* drm_info) { LOG_EWK_API_MOCKUP(); } + +const int ewk_media_playback_info_video_id_get(Ewk_Media_Playback_Info* data) +{ + LOG_EWK_API_MOCKUP(); +} + +#if defined(OS_TIZEN_TV_PRODUCT) +Ewk_Media_Playback_Info* ewkMediaPlaybackInfoCreate(const int player_id, + const char* url, + const char* mime_type) +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +Eina_Bool ewk_media_playback_info_media_resource_acquired_get( + Ewk_Media_Playback_Info* data) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewkMediaPlaybackInfoDelete(Ewk_Media_Playback_Info* data) +{ + LOG_EWK_API_MOCKUP(); +} +#endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.h b/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.h deleted file mode 100644 index ca49616..0000000 --- a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info.h +++ /dev/null @@ -1,114 +0,0 @@ -/* - * Copyright (C) 2016 Samsung Electronics. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY SAMSUNG ELECTRONICS. AND ITS CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, - * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SAMSUNG ELECTRONICS. OR ITS - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, - * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; - * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, - * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -/** - * @file ewk_media_playback_info.h - * @brief This file describes the ewk media playback info API. - */ - -#ifndef ewk_media_playback_info_h -#define ewk_media_playback_info_h - -#include -#include -#include - -#ifdef __cplusplus -extern "C" { -#endif - -typedef struct _Ewk_Media_Playback_Info Ewk_Media_Playback_Info; - -/** - * Get url of media. - * - * @param meia playback info's structure - * - * @return @c media url - */ -EXPORT_API const char* ewk_media_playback_info_media_url_get( - Ewk_Media_Playback_Info* data); - -/** - * Get mime type of media. - * - * @param meia playback info's structure - * - * @return @c mime type - */ -EXPORT_API const char* ewk_media_playback_info_mime_type_get( - Ewk_Media_Playback_Info* data); - -/** - * Get translated url of media. - * - * @param media playback info's structure - * - * @return @c translated url - */ -EXPORT_API const char* ewk_media_playback_info_translated_url_get( - Ewk_Media_Playback_Info* data); - -/** - * Get drm info of media. - * - * @param media playback info's structure - * - * @return @c drm info - */ -EXPORT_API const char* ewk_media_playback_info_drm_info_get( - Ewk_Media_Playback_Info* data); - -/** - * Set media resource acquired of media. - * - * @param media playback info's structure - */ -EXPORT_API void ewk_media_playback_info_media_resource_acquired_set( - Ewk_Media_Playback_Info* data, - unsigned char media_resource_acquired); - -/** - * Set translated url of media. - * - * @param media playback info's structure - */ -EXPORT_API void ewk_media_playback_info_translated_url_set( - Ewk_Media_Playback_Info* data, - const char* translated_url); - -/** - * Set drm info of media. - * - * @param media playback info's structure - */ -EXPORT_API void ewk_media_playback_info_drm_info_set( - Ewk_Media_Playback_Info* data, - const char* drm_info); - -#ifdef __cplusplus -} -#endif -#endif // ewk_media_playback_info_h diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info_product.h b/tizen_src/ewk/efl_integration/public/ewk_media_playback_info_product.h index 5061f9e..a2fe3af 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_media_playback_info_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_media_playback_info_product.h @@ -42,6 +42,16 @@ extern "C" { typedef struct _Ewk_Media_Playback_Info Ewk_Media_Playback_Info; /** + * Get video id of media. + * + * @param meia playback info's structure + * + * @return @c video id + */ +EXPORT_API const int ewk_media_playback_info_video_id_get( + Ewk_Media_Playback_Info* data); + +/** * Get url of media. * * @param meia playback info's structure @@ -88,7 +98,7 @@ EXPORT_API const char* ewk_media_playback_info_drm_info_get( */ EXPORT_API void ewk_media_playback_info_media_resource_acquired_set( Ewk_Media_Playback_Info* data, - unsigned char media_resource_acquired); + Eina_Bool media_resource_acquired); /** * Set translated url of media. @@ -108,6 +118,15 @@ EXPORT_API void ewk_media_playback_info_drm_info_set( Ewk_Media_Playback_Info* data, const char* drm_info); +#if defined(OS_TIZEN_TV_PRODUCT) +Ewk_Media_Playback_Info* ewkMediaPlaybackInfoCreate(const int player_id, + const char* url, + const char* mime_type); +Eina_Bool ewk_media_playback_info_media_resource_acquired_get( + Ewk_Media_Playback_Info* data); +void ewkMediaPlaybackInfoDelete(Ewk_Media_Playback_Info* data); +#endif + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.cc b/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.cc index c4e071e..14278e3 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.cc @@ -52,3 +52,27 @@ const void* ewk_media_subtitle_data_get(Ewk_Media_Subtitle_Data *data) LOG_EWK_API_MOCKUP(); return NULL; } + +#if defined(OS_TIZEN_TV_PRODUCT) +Ewk_Media_Subtitle_Info* ewkMediaSubtitleInfoCreate(int id, const char* url, const char* lang, const char* label) +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +void ewkMediaSubtitleInfoDelete(Ewk_Media_Subtitle_Info* data) +{ + LOG_EWK_API_MOCKUP(); +} + +Ewk_Media_Subtitle_Data* ewkMediaSubtitleDataCreate(int id, double timestamp, const void* data, unsigned size) +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +void ewkMediaSubtitleDataDelete(Ewk_Media_Subtitle_Data* data) +{ + LOG_EWK_API_MOCKUP(); +} +#endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.h b/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.h deleted file mode 100644 index 708c4e0..0000000 --- a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info.h +++ /dev/null @@ -1,100 +0,0 @@ -// Copyright 2016 Samsung Electronics. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -/** -* @file ewk_media_subtitle_info.h -* @brief . -*/ - -#ifndef ewk_media_subtitle_info_h -#define ewk_media_subtitle_info_h - -#include -#include -#include - -#ifdef __cplusplus -extern "C" { -#endif - -typedef struct _Ewk_Media_Subtitle_Info Ewk_Media_Subtitle_Info; - -/** -* Get id of subtitle. -* -* @param meia subtitle info's structure -* -* @return @c subtitle id -*/ -EXPORT_API int ewk_media_subtitle_info_id_get(Ewk_Media_Subtitle_Info *data); - -/** -* Get url of subtitle. -* -* @param meia subtitle info's structure -* -* @return @c subtitle url -*/ -EXPORT_API const char *ewk_media_subtitle_info_url_get(Ewk_Media_Subtitle_Info *data); - -/** -* Get srcLang of subtitle. -* -* @param meia subtitle info's structure -* -* @return @c subtitle srcLang -*/ -EXPORT_API const char *ewk_media_subtitle_info_lang_get(Ewk_Media_Subtitle_Info *data); - -/** -* Get label of subtitle. -* -* @param meia subtitle info's structure -* -* @return @c subtitle label -*/ -EXPORT_API const char *ewk_media_subtitle_info_label_get(Ewk_Media_Subtitle_Info *data); - -typedef struct _Ewk_Media_Subtitle_Data Ewk_Media_Subtitle_Data; - -/** -* Get id of subtitle. -* -* @param meia subtitle data's structure -* -* @return @c subtitle id -*/ -EXPORT_API int ewk_media_subtitle_data_id_get(Ewk_Media_Subtitle_Data *data); - -/** -* Get timestamp of subtitle. -* -* @param meia subtitle data's structure -* -* @return @c subtitle timestamp -*/ -EXPORT_API double ewk_media_subtitle_data_timestamp_get(Ewk_Media_Subtitle_Data *data); - -/** -* Get data size of subtitle. -* -* @param meia subtitle data's structure -* -* @return @c subtitle data size -*/ -EXPORT_API unsigned ewk_media_subtitle_data_size_get(Ewk_Media_Subtitle_Data *data); - -/** -* Get data of subtitle. -* -* @param meia subtitle data's structure -* -* @return @c subtitle data -*/ -EXPORT_API const void* ewk_media_subtitle_data_get(Ewk_Media_Subtitle_Data *data); - -#ifdef __cplusplus -} -#endif -#endif // ewk_media_subtitle_info_h diff --git a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info_product.h b/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info_product.h index 9c2b088..e9b1619 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_media_subtitle_info_product.h @@ -115,6 +115,18 @@ EXPORT_API unsigned ewk_media_subtitle_data_size_get(Ewk_Media_Subtitle_Data *da */ EXPORT_API const void* ewk_media_subtitle_data_get(Ewk_Media_Subtitle_Data *data); +#if defined(OS_TIZEN_TV_PRODUCT) +Ewk_Media_Subtitle_Info* ewkMediaSubtitleInfoCreate(int id, const char* url, +const char* lang, const char* label); + +void ewkMediaSubtitleInfoDelete(Ewk_Media_Subtitle_Info* data); + +Ewk_Media_Subtitle_Data* ewkMediaSubtitleDataCreate(int id, double timestamp, +const void* data, unsigned size); + +void ewkMediaSubtitleDataDelete(Ewk_Media_Subtitle_Data* data); +#endif + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_policy_decision.cc b/tizen_src/ewk/efl_integration/public/ewk_policy_decision.cc index 54c8e38..50b8a9a0 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_policy_decision.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_policy_decision.cc @@ -119,9 +119,8 @@ Eina_Bool ewk_policy_decision_ignore(Ewk_Policy_Decision* policyDecision) Eina_Bool ewk_policy_decision_download(Ewk_Policy_Decision* policyDecision) { - EINA_SAFETY_ON_NULL_RETURN_VAL(policyDecision, EINA_FALSE); - policyDecision->Download(); - return EINA_TRUE; + LOG_EWK_API_MOCKUP("This API is deprecated"); + return EINA_FALSE; } Ewk_Policy_Navigation_Type ewk_policy_decision_navigation_type_get(Ewk_Policy_Decision* policyDecision) diff --git a/tizen_src/ewk/efl_integration/public/ewk_policy_decision_internal.h b/tizen_src/ewk/efl_integration/public/ewk_policy_decision_internal.h index 602fcf9..0931dd9 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_policy_decision_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_policy_decision_internal.h @@ -70,7 +70,7 @@ EXPORT_API Eina_Bool ewk_policy_decision_suspend(Ewk_Policy_Decision* policy_dec * * @return @c EINA_TRUE on success or @c EINA_FALSE on failure */ -EXPORT_API Eina_Bool ewk_policy_decision_download(Ewk_Policy_Decision* policy_decision); +EINA_DEPRECATED EXPORT_API Eina_Bool ewk_policy_decision_download(Ewk_Policy_Decision* policy_decision); /** * Gets the frame reference from Policy Decision object. diff --git a/tizen_src/ewk/efl_integration/public/ewk_settings.cc b/tizen_src/ewk/efl_integration/public/ewk_settings.cc index ae024bb..84b815c 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_settings.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_settings.cc @@ -266,16 +266,14 @@ Eina_Bool ewk_settings_scan_malware_enabled_set(Ewk_Settings* settings, Eina_Boo Eina_Bool ewk_settings_spdy_enabled_set(Ewk_Settings* settings, Eina_Bool spdyEnabled) { - EINA_SAFETY_ON_NULL_RETURN_VAL(settings, EINA_FALSE); - settings->setSpdyEnabled(spdyEnabled); - - return EINA_TRUE; + LOG_EWK_API_DEPRECATED("This API is deprecated, not Supported by chromium. spdy is deprecated in m50 and replace with HTTP2 handling."); + return EINA_FALSE; } Eina_Bool ewk_settings_spdy_enabled_get(Ewk_Settings *settings) { - LOG_EWK_API_MOCKUP(); - return false; + LOG_EWK_API_DEPRECATED("This API is deprecated, not Supported by chromium. spdy is deprecated in m50 and replace with HTTP2 handling."); + return EINA_FALSE; } Eina_Bool ewk_settings_performance_features_enabled_set(Ewk_Settings* settings, Eina_Bool spdyEnabled) @@ -893,17 +891,32 @@ void ewk_settings_disclose_set_cookie_headers_enabled(Ewk_Settings* settings, Ei LOG_EWK_API_MOCKUP(); } -Eina_Bool ewk_settings_viewport_meta_tag_set(Ewk_Settings* settings, Eina_Bool enable) { +Eina_Bool ewk_settings_viewport_meta_tag_set(Ewk_Settings* settings, Eina_Bool enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_settings_viewport_meta_tag_get(const Ewk_Settings *settings) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_settings_spatial_navigation_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled) +{ LOG_EWK_API_MOCKUP(); - return false; } -void ewk_settings_spatial_navigation_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled) { +void ewk_settings_ime_panel_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled) +{ LOG_EWK_API_MOCKUP(); } -void ewk_settings_ime_panel_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled) { +Eina_Bool ewk_settings_ime_panel_enabled_get(const Ewk_Settings *settings) +{ LOG_EWK_API_MOCKUP(); + return EINA_FALSE; } Eina_Bool ewk_settings_allow_file_access_from_external_url_set(Ewk_Settings* settings, Eina_Bool allow) { @@ -911,7 +924,36 @@ Eina_Bool ewk_settings_allow_file_access_from_external_url_set(Ewk_Settings* set return false; } -Eina_Bool ewk_settings_swipe_to_refresh_enabled_set(Ewk_Settings* settings, Eina_Bool enable) { +Eina_Bool ewk_settings_swipe_to_refresh_enabled_set(Ewk_Settings* settings, Eina_Bool enable) +{ LOG_EWK_API_MOCKUP(); - return false; + return EINA_FALSE; +} + +Eina_Bool ewk_settings_swipe_to_refresh_enabled_get(const Ewk_Settings *settings) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_settings_drag_drop_enabled_set(Ewk_Settings* settings, Eina_Bool enabled) +{ + LOG_EWK_API_MOCKUP(); +} + +Eina_Bool ewk_settings_drag_drop_enabled_get(const Ewk_Settings* settings) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_settings_clipboard_enabled_set(Ewk_Settings* settings, Eina_Bool enabled) +{ + LOG_EWK_API_MOCKUP(); +} + +Eina_Bool ewk_settings_clipboard_enabled_get(const Ewk_Settings* settings) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; } diff --git a/tizen_src/ewk/efl_integration/public/ewk_settings.h b/tizen_src/ewk/efl_integration/public/ewk_settings.h index 868fd3c..ffea564 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_settings.h +++ b/tizen_src/ewk/efl_integration/public/ewk_settings.h @@ -52,7 +52,7 @@ typedef struct Ewk_Settings Ewk_Settings; * * @since_tizen 2.4 * - * @param[in] setting Setting object to set password form autofill + * @param[in] settings Settings object to set password form autofill * @param[in] enable @c EINA_TRUE to enable password form autofill * @c EINA_FALSE to disable * @@ -67,7 +67,7 @@ EXPORT_API Eina_Bool ewk_settings_autofill_password_form_enabled_set(Ewk_Setting * * @since_tizen 2.4 * - * @param[in] setting Setting object to set form candidate data for autofill + * @param[in] settings Settings object to set form candidate data for autofill * @param[in] enable @c EINA_TRUE to enable form candidate data for autofill * @c EINA_FALSE to disable * @@ -259,23 +259,8 @@ EXPORT_API Eina_Bool ewk_settings_scripts_can_open_windows_set(Ewk_Settings* set EXPORT_API Eina_Bool ewk_settings_scripts_can_open_windows_get(const Ewk_Settings* settings); /** - * Enables/disables the viewport meta tag. - * - * By default, the viewport meta tag is enabled on mobile and wearable, - * but it is disabled on TV. - * - * @param settings settings object - * @param enable @c EINA_TRUE to enable the viewport meta tag - * @c EINA_FALSE to disable - * - * @return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API Eina_Bool ewk_settings_viewport_meta_tag_set(Ewk_Settings* settings, - Eina_Bool enable); - -/** - * @} - */ +* @} +*/ #ifdef __cplusplus } diff --git a/tizen_src/ewk/efl_integration/public/ewk_settings_internal.h b/tizen_src/ewk/efl_integration/public/ewk_settings_internal.h index 4abe353..38437cf 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_settings_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_settings_internal.h @@ -101,6 +101,30 @@ EXPORT_API Eina_Bool ewk_settings_fullscreen_enabled_set(Ewk_Settings *settings, */ EXPORT_API Eina_Bool ewk_settings_fullscreen_enabled_get(const Ewk_Settings *settings); +/* + * Enables/disables swipe to refresh feature. Swipe to refresh allows + * us to refresh page using swipe gesture. + * + * Default value for swipe to refresh setting is @c EINA_FALSE. + * + * @param settings settings object to enable swipe to refresh feature + * @param enable @c EINA_TRUE to enable swipe to refresh feature or + * @c EINA_FALSE to disable + * + * @return @c EINA_TRUE on success or @c EINA_FALSE on failure + */ +EXPORT_API Eina_Bool ewk_settings_swipe_to_refresh_enabled_set(Ewk_Settings *settings, Eina_Bool enable); + +/** + * Returns whether swipe to refresh feature is enabled or not. + * + * @param settings settings object to query whether swipe to refresh feature is enabled + * + * @return @c EINA_TRUE if the swipe to refresh feature is enabled + * @c EINA_FALSE if not or on failure + */ +EXPORT_API Eina_Bool ewk_settings_swipe_to_refresh_enabled_get(const Ewk_Settings *settings); + /** * Requests enables/disables the plug-ins. * @@ -122,24 +146,14 @@ EXPORT_API Eina_Bool ewk_settings_plugins_enabled_set(Ewk_Settings *settings, Ei EXPORT_API Eina_Bool ewk_settings_plugins_enabled_get(const Ewk_Settings *settings); /** - * Checks whether WebKit supports the @a encoding. - * - * @param encoding the encoding string to check whether WebKit supports it - * - * @return @c EINA_TRUE if WebKit supports @a encoding or @c EINA_FALSE if not or - * on failure - */ -EXPORT_API Eina_Bool ewk_settings_is_encoding_valid(const char* encoding); - -/** - * Requests to set default text encoding name. - * - * @param settings settings object to set default text encoding name - * @param encoding default text encoding name - * - * @return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API Eina_Bool ewk_settings_default_encoding_set(Ewk_Settings *settings, const char* encoding); + * Checks whether WebKit supports the @a encoding. + * + * @param encoding the encoding string to check whether WebKit supports it + * + * @return @c EINA_TRUE if WebKit supports @a encoding + * @c EINA_FALSE if not or on failure + */ + EXPORT_API Eina_Bool ewk_settings_is_encoding_valid(const char* encoding); /** * Sets link magnifier enabled. @@ -298,27 +312,6 @@ EXPORT_API Eina_Bool ewk_settings_text_autosizing_enabled_set(Ewk_Settings *sett */ EXPORT_API Eina_Bool ewk_settings_text_autosizing_enabled_get(const Ewk_Settings *settings); - -/** - * Sets the scale factor for text autosizing. - * - * Default value is 1.0. - * - * @param settings settings object to set the text autosizing - * @param factor font scale factor for text autosizing - */ -EXPORT_API Eina_Bool ewk_settings_text_autosizing_font_scale_factor_set(Ewk_Settings *settings, double factor); - -/** - * Gets the current scale factor for text autosizing. - * - * @param settings settings object to set scale factor for text autosizing - * - * @return the current font scale factor for text autosizing. - * In case of error, it returns non-positive value. - */ -EXPORT_API double ewk_settings_text_autosizing_font_scale_factor_get(const Ewk_Settings *settings); - /** * Requests to enable/disable edge effect * @@ -341,23 +334,6 @@ EXPORT_API Eina_Bool ewk_settings_edge_effect_enabled_set(Ewk_Settings* settings EXPORT_API Eina_Bool ewk_settings_edge_effect_enabled_get(const Ewk_Settings* settings); /** - * Sets text style for selection mode enabled. - * - * @param settings settings object - * @param enabled text style for selection mode - */ - -EXPORT_API void ewk_settings_text_style_state_enabled_set(Ewk_Settings *settings, Eina_Bool enabled); -/** - * Gets text style for selection mode enabled. - * - * @param settings settings object - * - * @return @c EINA_TRUE if text style for selection mode enabled, @c EINA_FALSE otherwise - */ -EXPORT_API Eina_Bool ewk_settings_text_style_state_enabled_get(const Ewk_Settings *settings); - -/** * Requests to enable/disable to select word by double tap * * @param settings settings object to enable/disable to select word by double tap @@ -585,22 +561,6 @@ ewk_settings_tizen_compatibility_mode_set(Ewk_Settings* settings, unsigned minor, unsigned release); -/* - * Enables/disables swipe to refresh feature. Swipe to refresh allows - * us to refresh page using swipe gesture. - * - * Default value for swipe to refresh setting is @c EINA_FALSE. - * - * @param settings settings object to enable swipe to refresh feature - * @param enable @c EINA_TRUE to enable swipe to refresh feature or - * @c EINA_FALSE to disable - * - * @return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API Eina_Bool -ewk_settings_swipe_to_refresh_enabled_set(Ewk_Settings* settings, - Eina_Bool enable); - #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_settings_product.h b/tizen_src/ewk/efl_integration/public/ewk_settings_product.h index 568e437..7f6bdfa 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_settings_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_settings_product.h @@ -238,22 +238,26 @@ EXPORT_API Eina_Bool ewk_settings_scan_malware_enabled_get(const Ewk_Settings* s /** * Requests to enable/disable spdy. * + * @deprecated Deprecated since Tizen 4.0. + * * @param settings param not needed, only present for API compatibility * * @param spdy_enabled @c EINA_TRUE to enable the spdy @c EINA_FALSE to disable * * @return always @c EINA_TRUE, only present for API compatibility */ -EXPORT_API Eina_Bool ewk_settings_spdy_enabled_set(Ewk_Settings *settings, Eina_Bool spdy_enabled); +EINA_DEPRECATED EXPORT_API Eina_Bool ewk_settings_spdy_enabled_set(Ewk_Settings *settings, Eina_Bool spdy_enabled); /** * Get spdy enabled/disabled state. * + * @deprecated Deprecated since Tizen 4.0. + * * @param settings param not needed, only present for API compatibility * * @return @c EINA_TRUE if enabled or @c EINA_FALSE if disabled */ -EXPORT_API Eina_Bool ewk_settings_spdy_enabled_get(Ewk_Settings *settings); +EINA_DEPRECATED EXPORT_API Eina_Bool ewk_settings_spdy_enabled_get(Ewk_Settings *settings); /** * Requests to set the performance features of soup enable/disable. @@ -396,6 +400,16 @@ EINA_DEPRECATED EXPORT_API void ewk_settings_focus_ring_enabled_set(Ewk_Settings EXPORT_API Eina_Bool ewk_settings_viewport_meta_tag_set(Ewk_Settings *settings, Eina_Bool enable); /** + * Returns whether the viewport meta tag is enabled. + * + * @param settings settings object + * + * @return @c EINA_TRUE if the viewport meta tag is enabled + * @c EINA_FALSE if not or on failure + */ +EXPORT_API Eina_Bool ewk_settings_viewport_meta_tag_get(const Ewk_Settings *settings); + +/** * Allow/disallow to run and display mixed contents. * * By default, WebCore don't allow run and display mixed contents. @@ -424,16 +438,6 @@ EXPORT_API void ewk_settings_default_mixed_contents_policy_set(Ewk_Settings* set EXPORT_API void ewk_settings_disable_webgl_set(Ewk_Settings* settings, Eina_Bool disable); /** - * Returns whether the viewport meta tag is enabled. - * - * @param settings settings object - * - * @return @c EINA_TRUE if the viewport meta tag is enabled - * @c EINA_FALSE if not or on failure - */ -EXPORT_API Eina_Bool ewk_settings_viewport_meta_tag_get(const Ewk_Settings *settings); - -/** * Enables/disables web security. * * By default, the web security is enabled. @@ -790,17 +794,81 @@ EXPORT_API Eina_Bool ewk_settings_selection_handle_enabled_get(const Ewk_Setting EXPORT_API void ewk_settings_disclose_set_cookie_headers_enabled(Ewk_Settings* settings, Eina_Bool Enabled); /** +* @brief Request to set the spatial navigation usage set by hbbtv +* +* @since_tizen 3.0 +* +* @param[in] settings setting object +* @param[in] enable @c EINA_TRUE enable to use spatial navigation +* @c EINA_FALSE to disable +*/ +EXPORT_API void ewk_settings_spatial_navigation_enabled_set(Ewk_Settings* settings, Eina_Bool enable); + +/** * Request to set enable/disable the ime panel * - * By default, the ime panel is Enabled + * By default, the ime panel is enabled * Some Apps want to disable ime panel * * @param settings setting object - * @param Enabled @c EINA_TRUE to enable ime panel + * @param enabled @c EINA_TRUE to enable ime panel * @c EINA_FALSE to disable ime panel * */ -EXPORT_API void ewk_settings_ime_panel_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled); +EXPORT_API void ewk_settings_ime_panel_enabled_set(Ewk_Settings* settings, Eina_Bool enabled); + +/** + * Returns whether the ime panel is enabled or disabled + * + * @param settings setting object + * + * @return @c EINA_TRUE enable ime panel or @c EINA_FALSE disable ime panel + */ +EXPORT_API Eina_Bool ewk_settings_ime_panel_enabled_get(const Ewk_Settings *settings); + + +/** + * Request to set enable/disable drag and drop + * + * By default, the drag and drop is Disabled + * + * @param settings settings object + * @param enabled @c EINA_TRUE to enable drag and drop + * @c EINA_FALSE to disable drag and drop + * + */ +EXPORT_API void ewk_settings_drag_drop_enabled_set(Ewk_Settings* settings, Eina_Bool enabled); + +/** + * Returns whether drag and drop is enabled or disabled + * + * @param settings settings object + * + * @return @c EINA_TRUE drag and drop is enabled, @c EINA_FALSE drag and drop is disabled +*/ +EXPORT_API Eina_Bool ewk_settings_drag_drop_enabled_get(const Ewk_Settings* settings); + +/** + * Request to set enable/disable clipboard + * + * By default, the clipboard is Disabled + * + * @param settings settings object + * @param enabled @c EINA_TRUE to enable clipboard + * @c EINA_FALSE to disable clipboard + * + */ +EXPORT_API void ewk_settings_clipboard_enabled_set(Ewk_Settings* settings, Eina_Bool enabled); + +/** + * Returns whether clipboard is enabled + * + * @param settings settings object + * + * @return @c EINA_TRUE clipboard is enabled, @c EINA_FALSE clipboard is disabled +*/ +EXPORT_API Eina_Bool ewk_settings_clipboard_enabled_get(const Ewk_Settings* settings); + #ifdef __cplusplus } diff --git a/tizen_src/ewk/efl_integration/public/ewk_user_media.cc b/tizen_src/ewk/efl_integration/public/ewk_user_media.cc index 43aa4d4..226090a 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_user_media.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_user_media.cc @@ -25,6 +25,7 @@ #include "ewk_user_media_internal.h" +#include "private/ewk_private.h" #include "private/ewk_security_origin_private.h" #include "private/ewk_user_media_private.h" @@ -61,3 +62,15 @@ const Ewk_Security_Origin* ewk_user_media_permission_request_origin_get( return nullptr; #endif } + +const char* ewk_user_media_permission_request_message_get(const Ewk_User_Media_Permission_Request* request) +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +Ewk_User_Media_Device_Type ewk_user_media_permission_request_device_type_get(const Ewk_User_Media_Permission_Request* request) +{ + LOG_EWK_API_MOCKUP(); + return EWK_USER_MEDIA_DEVICE_TYPE_NONE; +} diff --git a/tizen_src/ewk/efl_integration/public/ewk_user_media_internal.h b/tizen_src/ewk/efl_integration/public/ewk_user_media_internal.h index b7cc216..20ad24d 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_user_media_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_user_media_internal.h @@ -37,6 +37,23 @@ extern "C" { typedef struct _Ewk_User_Media_Permission_Request Ewk_User_Media_Permission_Request; /** + * enum _Ewk_User_Media_Device_Type + * @brief Contains device type option for media permission request + * + */ +enum _Ewk_User_Media_Device_Type { + EWK_USER_MEDIA_DEVICE_TYPE_NONE = 0, + EWK_USER_MEDIA_DEVICE_TYPE_MICROPHONE = 1, /* MicroPhone type */ + EWK_USER_MEDIA_DEVICE_TYPE_CAMERA = 2, /* Camera type */ + EWK_USER_MEDIA_DEVICE_TYPE_MICROPHONE_AND_CAMERA = 3 /* Both MicroPhone and Camera. */ +}; + +/** + * @brief The enum type that creates a type name for _Ewk_User_Media_Device_Type. + */ +typedef enum _Ewk_User_Media_Device_Type Ewk_User_Media_Device_Type; + +/** * Requests for getting origin of local media permission request. * * @param request Ewk_User_Media_Permission_Request object to get origin for @@ -73,6 +90,26 @@ EXPORT_API Eina_Bool ewk_user_media_permission_request_suspend(Ewk_User_Media_Pe */ EXPORT_API void ewk_user_media_permission_reply(Ewk_User_Media_Permission_Request* request, Eina_Bool allow); +/** + * Requests for getting message of local media permission request. + * + * @param request Ewk_User_Media_Permission_Request object to get message for + * userMedia permission request + * + * @return message of userMedia permission request + */ +EXPORT_API const char* ewk_user_media_permission_request_message_get(const Ewk_User_Media_Permission_Request* request); + +/** + * Get the type of device type for media permission request message. + * + * @param request Ewk_User_Media_Permission_Request object to get message for + * userMedia permission request + * + * @return The type of device type, MicroPhone, Camera, or both of them. + */ +EXPORT_API Ewk_User_Media_Device_Type ewk_user_media_permission_request_device_type_get(const Ewk_User_Media_Permission_Request* request); + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_view.cc b/tizen_src/ewk/efl_integration/public/ewk_view.cc index 9ab82e1..f0033ba 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_view.cc +++ b/tizen_src/ewk/efl_integration/public/ewk_view.cc @@ -707,8 +707,8 @@ void ewk_view_orientation_send(Evas_Object* ewkView, int orientation) void ewk_view_encoding_custom_set(Evas_Object* ewkView, const char* encoding) { - EWK_VIEW_IMPL_GET_OR_RETURN(ewkView, impl); - impl->SetOverrideEncoding(std::string(encoding)); + // Chromium does not support this feature hence the comment + LOG_EWK_API_MOCKUP("Not Supported by chromium"); } Eina_Bool ewk_view_text_selection_range_get(const Evas_Object* view, Eina_Rectangle* left_rect, Eina_Rectangle* right_rect) @@ -897,11 +897,6 @@ void ewk_view_exceeded_local_file_system_quota_reply(Evas_Object* ewkView, Eina_ LOG_EWK_API_MOCKUP(); } -void ewk_view_intercept_request_callback_set (Evas_Object* ewkView, Ewk_View_Intercept_Request_Callback callback, void* user_data) -{ - LOG_EWK_API_MOCKUP(); -} - void ewk_view_unfocus_allow_callback_set(Evas_Object* ewkView, Ewk_View_Unfocus_Allow_Callback callback, void* user_data) { EWK_VIEW_IMPL_GET_OR_RETURN(ewkView, impl); @@ -1336,11 +1331,6 @@ void ewk_view_force_layout(const Evas_Object* o) LOG_EWK_API_MOCKUP(); } -void ewk_media_current_time_get(const Evas_Object* o, Ewk_View_Video_Current_Time_Get_Callback callback, void *user_data) -{ - LOG_EWK_API_MOCKUP(); -} - Eina_Bool ewk_view_send_key_event(Evas_Object* ewk_view, void* key_event, Eina_Bool is_press) { LOG_EWK_API_MOCKUP(); return false; @@ -1392,3 +1382,115 @@ Eina_Bool ewk_view_app_preload_set(Evas_Object* ewkView, Eina_Bool is_preload) { LOG_EWK_API_MOCKUP(); return false; } + +const char* ewk_view_original_url_get(const Evas_Object* o) +{ + LOG_EWK_API_MOCKUP(); + return NULL; +} + +void ewk_view_offscreen_rendering_enabled_set(Evas_Object* o, Eina_Bool enabled) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_ime_window_set(Evas_Object* o, void* window) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_smartrc_show_mic_notification_callback_set(Evas_Object* o, Ewk_View_SmartRC_Mic_Notification_Callback callback, void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} + +Eina_Bool ewk_view_set_support_canvas_hole(Evas_Object* ewkView, const char* url) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_view_marlin_enable_set(Evas_Object* ewkView, Eina_Bool is_enable) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_view_key_system_whitelist_set(Evas_Object* ewkView, const char** list, unsigned list_size) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +Eina_Bool ewk_view_active_drm_set(Evas_Object* view, const char* drm_system_id) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_media_set_subtitle_lang(Evas_Object* ewkView, const char* lang_list) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_media_set_parental_rating_result(Evas_Object* ewkView, const char* url, Eina_Bool is_pass) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_media_start_with_high_bit_rate(Evas_Object* ewkView, Eina_Bool is_high_bitrate) +{ + LOG_EWK_API_MOCKUP(); +} + +double ewk_view_media_current_time_get(const Evas_Object *o) +{ + LOG_EWK_API_MOCKUP(); + return 0; +} + +void ewk_view_request_canvas_fullscreen(Evas_Object* ewkView) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_360video_play(Evas_Object* ewkView) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_360video_pause(Evas_Object* ewkView) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_360video_duration(Evas_Object* ewkView, Ewk_360_Video_Duration_Callback callback, void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_360video_current_time(Evas_Object* ewkView, Ewk_360_Video_CurrentTime_Callback callback, void* user_data) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_360video_set_current_time(Evas_Object* ewkView, double current_time) +{ + LOG_EWK_API_MOCKUP(); +} + +Eina_Bool ewk_view_script_execute_all_frames(Evas_Object *o, const char *script, Ewk_View_Script_Execute_Cb callback, void *user_data) +{ + LOG_EWK_API_MOCKUP(); + return EINA_FALSE; +} + +void ewk_view_floating_window_state_changed(const Evas_Object *o, Eina_Bool status) +{ + LOG_EWK_API_MOCKUP(); +} + +void ewk_view_auto_login(Evas_Object *view, const char* user_name, const char* password) +{ + LOG_EWK_API_MOCKUP(); +} diff --git a/tizen_src/ewk/efl_integration/public/ewk_view.h b/tizen_src/ewk/efl_integration/public/ewk_view.h index db2177f..d637a51 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_view.h +++ b/tizen_src/ewk/efl_integration/public/ewk_view.h @@ -55,7 +55,7 @@ extern "C" { * @param[in] enable EINA_TRUE to set on the visibility of the page, * EINA_FALSE otherwise. * - * @return @c EINA_TRUE on success, othetwise @c EINA_FALSE + * @return @c EINA_TRUE on success, otherwise @c EINA_FALSE */ EXPORT_API Eina_Bool ewk_view_visibility_set(Evas_Object* o, Eina_Bool enable); @@ -173,6 +173,21 @@ EXPORT_API Eina_Bool ewk_view_url_set(Evas_Object* o, const char* url); EXPORT_API const char* ewk_view_url_get(const Evas_Object* o); /** + * @brief Returns the original URL string of the view object. + * + * @details It returns an internal string that should not be modified.\n + * The string is guaranteed to be stringshared. + * + * @since_tizen 4.0 + * + * @param[in] o The view object to get the original URL + * + * @return The original URL on success,\n + * otherwise @c NULL on failure + */ +EXPORT_API const char* ewk_view_original_url_get(const Evas_Object* o); + +/** * @brief Asks the main frame to reload the current document. * * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif @@ -231,6 +246,7 @@ EXPORT_API Eina_Bool ewk_view_back(Evas_Object* o); * otherwise @c EINA_FALSE */ EXPORT_API Eina_Bool ewk_view_forward(Evas_Object* o); + /** * @brief Checks whether it is possible to navigate backwards one item in * history. @@ -365,7 +381,7 @@ EXPORT_API Eina_Bool ewk_view_contents_size_get(const Evas_Object* o, Evas_Coord * @param[in] result_value The value returned by the script\n * If executed script returns a value, it would be @a result_value,\n * otherwise @c NULL if there is no value returned by the script - * @param[in] user_data The user_data will be passsed when + * @param[in] user_data The user_data will be passed when * ewk_view_script_execute() is called */ typedef void (*Ewk_View_Script_Execute_Cb)(Evas_Object* o, const char* result_value, void* user_data); @@ -640,7 +656,7 @@ typedef struct _Ewk_Script_Message Ewk_Script_Message; * * @param[in] o The view object * @param[in] message The ScriptMessage returned by the script. \n - * It will be passsed when ewk_view_javascript_message_handler_add() is called. + * It will be passed when ewk_view_javascript_message_handler_add() is called. */ typedef void (*Ewk_View_Script_Message_Cb)(Evas_Object* o, Ewk_Script_Message message); @@ -649,7 +665,10 @@ typedef void (*Ewk_View_Script_Message_Cb)(Evas_Object* o, Ewk_Script_Message me * * @since_tizen 3.0 * - * @remarks Certainly, specify privileges of using native API to users, + * @remarks Note that injected objects will not appear in JavaScript + * until the page is next (re)loaded. + * + * Certainly, specify privileges of using native API to users, * if using native API affects system settings, stability or security. * Privilege display name & description which will be noticed to user. * @@ -677,6 +696,30 @@ EXPORT_API Eina_Bool ewk_view_javascript_message_handler_add(Evas_Object* o, Ewk EXPORT_API Eina_Bool ewk_view_evaluate_javascript(Evas_Object* o, const char* name, const char* result); /** + * @brief Requests to set or unset a web view as the currently focused one. + * + * @since_tizen 3.0 + * + * @param[in] o The view object. + * @param[in] focused @c EINA_TRUE to set the focus on the web view, + * @c EINA_FALSE to remove the focus from the web view. + * + * @return @c EINA_TRUE on success, otherwise @c EINA_FALSE + */ +EXPORT_API Eina_Bool ewk_view_focus_set(const Evas_Object* o, Eina_Bool focused); + +/** + * @brief Checks whether a web view has the focus. + * + * @since_tizen 3.0 + * + * @param[in] o The view object. + * + * @return @c EINA_TRUE if the web view has the focus, otherwise @c EINA_FALSE + */ +EXPORT_API Eina_Bool ewk_view_focus_get(const Evas_Object* o); + +/** * @brief Callback invoked when requested manifest inform is responded. * * @since_tizen 3.0 @@ -706,40 +749,9 @@ typedef void (*Ewk_View_Request_Manifest_Callback)(Evas_Object* o, Ewk_View_Requ EXPORT_API void ewk_view_request_manifest(Evas_Object* o, Ewk_View_Request_Manifest_Callback callback, void* user_data); /** - * @brief Requests to set or unset a web view as the currently focused one. - * - * @since_tizen 3.0 - * - * @param[in] o The view object. - * @param[in] focused @c EINA_TRUE to set the focus on the web view, - * @c EINA_FALSE to remove the focus from the web view. - * - * @return @c EINA_TRUE on success, otherwise @c EINA_FALSE - */ -EXPORT_API Eina_Bool ewk_view_focus_set(const Evas_Object* o, Eina_Bool focused); - -#if defined(TIZEN_VIDEO_HOLE) -/** - * @brief Sets the support of video hole and video window, Use H/W overlay for - * performance of video output - * - * @since_tizen 3.0 - * - * @param[in] o the view object - * @param[in] o the top-level window object - * @param[in] enable EINA_TRUE to set on support the video hole, - * EINA_FALSE otherwise - * @param[in] enable EINA_TRUE to set on the video window of video hole, - * EINA_FALSE to set on the video windowless of video hole - * - * @return return @c EINA_TRUE on success or @c EINA_FALSE on failure - */ -EXPORT_API Eina_Bool ewk_view_set_support_video_hole(Evas_Object* ewkView, Evas_Object* window, Eina_Bool enable, Eina_Bool isVideoWindow); -#endif - -/** * @} */ + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_view_internal.h b/tizen_src/ewk/efl_integration/public/ewk_view_internal.h index 41d52ee..05d81a1 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_view_internal.h +++ b/tizen_src/ewk/efl_integration/public/ewk_view_internal.h @@ -39,8 +39,8 @@ #include "ewk_enums_internal.h" #include "ewk_frame_internal.h" #include "ewk_geolocation_internal.h" -#include "ewk_hit_test_internal.h" #include "ewk_history_internal.h" +#include "ewk_hit_test_internal.h" #include "ewk_page_group_internal.h" #include "ewk_quota_permission_request_internal.h" #include "ewk_touch_internal.h" @@ -268,6 +268,17 @@ typedef Eina_Bool (*Ewk_View_Notification_Permission_Callback)(Evas_Object *o, E typedef void (*Ewk_View_Scale_Changed_Callback)(Evas_Object *o, double scale_factor, void *user_data); /** + * Defines a callback for show or hide the notification to user. + * + * @param o view object to register on scale change + * @param show bool flag to indicate whether to show the mic notification. + * show is true when bluetooth mic is opened or voice key is pressed shortly. + * show is false when voice key is hold for more than 500ms + * @param user_data a pointer to data specified by ewk_view_smartrc_show_mic_notification_callback_set + */ +typedef void (*Ewk_View_SmartRC_Mic_Notification_Callback)(Evas_Object *o, Eina_Bool show, void *user_data); + +/** * The version you have to put into the version field * in the @a Ewk_View_Smart_Class structure. */ @@ -517,25 +528,6 @@ EXPORT_API void ewk_view_vertical_panning_hold_set(Evas_Object* o, Eina_Bool hol */ EXPORT_API void ewk_view_scale_range_get(Evas_Object* o, double* min_scale, double* max_scale); -/** - * Gets the current text zoom level. - * - * @param o view object to get the zoom level - * - * @return current zoom level in use on success or @c -1.0 on failure - */ -EXPORT_API double ewk_view_text_zoom_get(const Evas_Object* o); - -/** - * Sets the current text zoom level. - * - * @param o view object to set the zoom level - * @param textZoomFactor a new level to set - * - * @return @c EINA_TRUE on success or @c EINA_FALSE otherwise - */ -EXPORT_API Eina_Bool ewk_view_text_zoom_set(Evas_Object* o, double text_zoom_factor); - typedef Eina_Bool (*Ewk_View_Password_Confirm_Popup_Callback)(Evas_Object* o, const char* message, void* user_data); EXPORT_API void ewk_view_password_confirm_popup_callback_set(Evas_Object* o, Ewk_View_Password_Confirm_Popup_Callback callback, void* user_data); EXPORT_API void ewk_view_password_confirm_popup_reply(Evas_Object* o, Ewk_Password_Popup_Option result); @@ -572,7 +564,7 @@ EXPORT_API void ewk_view_javascript_prompt_callback_set(Evas_Object* o, Ewk_View typedef Eina_Bool (*Ewk_View_Applicacion_Cache_Permission_Callback)(Evas_Object* o, Ewk_Security_Origin* origin, void* user_data); //#endif -typedef Eina_Bool (*Ewk_View_Exceeded_Indexed_Database_Quota_Callback)(Evas_Object* o, Ewk_Security_Origin* origin, long long currentQuota, void* user_data); +typedef void (*Ewk_View_Exceeded_Indexed_Database_Quota_Callback)(Evas_Object* o, Ewk_Security_Origin* origin, long long currentQuota, void* user_data); EXPORT_API void ewk_view_exceeded_indexed_database_quota_callback_set(Evas_Object* o, Ewk_View_Exceeded_Indexed_Database_Quota_Callback callback, void* user_data); EXPORT_API void ewk_view_exceeded_indexed_database_quota_reply(Evas_Object* o, Eina_Bool allow); @@ -851,12 +843,13 @@ EXPORT_API Eina_Bool ewk_view_hit_test_request(Evas_Object* o, int x, int y, int EINA_DEPRECATED EXPORT_API Eina_Bool ewk_view_notification_closed(Evas_Object* o, Eina_List* notification_list); /** + * @deprecated Deprecated since Tizen 5.0. Manual encoding selection is removed from upstream * Sets the encoding and reloads the page. * * @param ewkView view to set the encoding * @param encoding the new encoding to set or @c 0 to restore the default one */ -EXPORT_API void ewk_view_encoding_custom_set(Evas_Object* ewkView, const char* encoding); +EINA_DEPRECATED EXPORT_API void ewk_view_encoding_custom_set(Evas_Object* ewkView, const char* encoding); // #endif // ENABLE(TIZEN_INPUT_TAG_EXTENSION) @@ -1085,6 +1078,11 @@ EXPORT_API double ewk_view_page_zoom_get(const Evas_Object *o); /** * Sets zoom factor of the current page. * + * @note ewk_view_page_zoom_set internally might use older page than current + * one, if you called it immediately after ewk_view_url_set. To be safe + * from such race, use it from inside 'url,changed' callback, which can + * be registered on ewk_view. + * * @param o view object to set the zoom level * @param zoom_factor a new level to set * @@ -1386,6 +1384,26 @@ EXPORT_API void ewk_view_app_installation_request_callback_set(Evas_Object* o, E */ EXPORT_API void ewk_view_mirrored_blur_set(Evas_Object* o, Eina_Bool state); +/** + * Sets whether the ewk_view renders to offscreen buffer or not. + * + * @since_tizen 5.0 + * + * @param[in] o view object + * @param[in] enabled a state to set + */ +EXPORT_API void ewk_view_offscreen_rendering_enabled_set(Evas_Object* o, Eina_Bool enabled); + +/** + * Sets the window object which is used for IME. + * + * @since_tizen 5.5 + * + * @param[in] o view object + * @param[in] window the top-level window object + */ +EXPORT_API void ewk_view_ime_window_set(Evas_Object* o, void* window); + #ifdef __cplusplus } #endif diff --git a/tizen_src/ewk/efl_integration/public/ewk_view_product.h b/tizen_src/ewk/efl_integration/public/ewk_view_product.h index 382bb89..cd9ceae 100644 --- a/tizen_src/ewk/efl_integration/public/ewk_view_product.h +++ b/tizen_src/ewk/efl_integration/public/ewk_view_product.h @@ -37,10 +37,6 @@ #include "ewk_value_product.h" #include "ewk_view_internal.h" -#if defined(TIZEN_PEPPER_EXTENSIONS) -#include "ewk_value_product.h" -#endif - #ifdef __cplusplus extern "C" { #endif @@ -175,6 +171,18 @@ EXPORT_API void ewk_view_application_cache_permission_reply(Evas_Object* o, Eina EXPORT_API void ewk_view_unfocus_allow_callback_set(Evas_Object* o, Ewk_View_Unfocus_Allow_Callback callback, void* user_data); /** + * @brief Set to callback to show or hide the notification of bluetooth mic to user. + * + * @since_tizen 5.0 + * + * @param[in] o view object + * @param[in] callback to show or hide the notification + * @param[in] user_data user_data will be passed when result_callback is + * called\n -I.e., user data will be kept until callback is called + */ +EXPORT_API void ewk_view_smartrc_show_mic_notification_callback_set(Evas_Object* o, Ewk_View_SmartRC_Mic_Notification_Callback callback, void* user_data); + +/** * @brief Requests loading the given contents. * * @since_tizen 2.3 @@ -503,7 +511,7 @@ EXPORT_API Evas_Object* ewk_view_favicon_get(const Evas_Object* ewkView); * @param item view object to resume new url loading * */ -EXPORT_API void ewk_view_resume_network_loading(Evas_Object* item); +EXPORT_API void ewk_view_resume_network_loading(Evas_Object* ewkView); EXPORT_API void ewk_view_poweroff_suspend(Evas_Object *item); @@ -513,7 +521,7 @@ EXPORT_API void ewk_view_poweroff_suspend(Evas_Object *item); * @param item view object to suspend url loading * */ -EXPORT_API void ewk_view_suspend_network_loading(Evas_Object* item); +EXPORT_API void ewk_view_suspend_network_loading(Evas_Object* ewkView); /** * This function should be use for browser edge scroll. @@ -546,10 +554,10 @@ EXPORT_API void ewk_view_set_cursor_by_client(Evas_Object* ewkView, Eina_Bool en EXPORT_API void ewk_view_run_mixed_content_confirm_reply(Evas_Object* ewkView, Eina_Bool result); /** - * Sets the cover-area (soon rect) multiplier. + * Sets the cover-area (soon rect) multiplier. * * @param ewkView view object - * @param coverAreaMultiplier the multiplier of cover-area. + * @param cover_area_multiplier the multiplier of cover-area. */ EXPORT_API void ewk_view_tile_cover_area_multiplier_set( Evas_Object* ewkView, @@ -623,39 +631,20 @@ EXPORT_API Eina_Bool ewk_view_stop_video(Evas_Object* o, Ewk_Stop_Video_Callback EXPORT_API Eina_Bool ewk_view_set_support_video_hole(Evas_Object* ewkView, Evas_Object* window, Eina_Bool enable, Eina_Bool isVideoWindow); /** - * @brief Sets the support of 4K video, Customize the device pixel ratio for - * video plane. + * @brief Sets the support of canvas hole, Use H/W overlay for video quality of WebGL 360 degree. + * Also, The WebBrowser provisionally want to show plane 360 video through canvas hole. * * @since_tizen 3.0 * * @note Should be used after ewk_view_url_set(). * * @param[in] o the view object - * @param[in] o enabled a state to set + * @param[in] url string (ex. "youtube.com") * * @return return @c EINA_TRUE on success or @c EINA_FALSE on failure */ -EXPORT_API Eina_Bool ewk_view_set_custom_device_pixel_ratio(Evas_Object* ewkView, Eina_Bool enabled); - -/** - * @brief Gets whether vertical panning is holding. - * - * @since_tizen 2.3 - * - * @param[in] o view object to get whether vertical panning is holding - * - * @return @c EINA_TRUE if vertical panning is holding - * @c EINA_FALSE if not or on failure - */ -EXPORT_API Eina_Bool ewk_view_vertical_panning_hold_get(Evas_Object* o); +EXPORT_API Eina_Bool ewk_view_set_support_canvas_hole(Evas_Object* ewkView, const char* url); -/** - * Block/Release the vertical pan - * - * @param o view object on which pan is to be blocked/release - * @param hold status of pan - */ -EXPORT_API void ewk_view_vertical_panning_hold_set(Evas_Object* o, Eina_Bool hold); /** * Callback for the generic sync call. @@ -688,7 +677,64 @@ EXPORT_API void ewk_view_widget_pepper_extension_callback_set(Evas_Object* ewk_v */ EXPORT_API void ewk_view_widget_pepper_extension_info_set(Evas_Object* ewk_view, Ewk_Value widget_pepper_ext_info); -#if defined(OS_TIZEN_TV) +/** + * @brief Sets the support of 4K video, Customize the device pixel ratio for + * video plane. + * + * @since_tizen 3.0 + * + * @note Should be used after ewk_view_url_set(). + * + * @param[in] o the view object + * @param[in] o enabled a state to set + * + * @return return @c EINA_TRUE on success or @c EINA_FALSE on failure + */ +EXPORT_API Eina_Bool ewk_view_set_custom_device_pixel_ratio(Evas_Object* ewkView, Eina_Bool enabled); + +/** + * @brief Gets whether horizontal panning is holding. + * + * @since_tizen 2.3 + * + * @param[in] o view object to get whether horizontal panning is holding + * + * @return @c EINA_TRUE if horizontal panning is holding + * @c EINA_FALSE if not or on failure + */ +EXPORT_API Eina_Bool ewk_view_horizontal_panning_hold_get(Evas_Object* o); + +/** + * @brief Sets to hold horizontal panning. + * + * @since_tizen 2.3 + * + * @param[in] o view object to set to hold horizontal panning + * @param[in] hold @c EINA_TRUE to hold horizontal panning + * @c EINA_FALSE not to hold + */ +EXPORT_API void ewk_view_horizontal_panning_hold_set(Evas_Object* o, Eina_Bool hold); + +/** + * @brief Gets whether vertical panning is holding. + * + * @since_tizen 2.3 + * + * @param[in] o view object to get whether vertical panning is holding + * + * @return @c EINA_TRUE if vertical panning is holding + * @c EINA_FALSE if not or on failure + */ +EXPORT_API Eina_Bool ewk_view_vertical_panning_hold_get(Evas_Object* o); + +/** + * Block/Release the vertical pan + * + * @param o view object on which pan is to be blocked/release + * @param hold status of pan + */ +EXPORT_API void ewk_view_vertical_panning_hold_set(Evas_Object* o, Eina_Bool hold); + /** * Set the translated url to media player. * @@ -698,7 +744,6 @@ EXPORT_API void ewk_view_widget_pepper_extension_info_set(Evas_Object* ewk_view, * @return @c EINA_TRUE on success or @c EINA_FALSE on failure */ EXPORT_API Eina_Bool ewk_media_translated_url_set(Evas_Object* ewkView, const char* url); -#endif /** * Set app is preload type or not. @@ -711,6 +756,69 @@ EXPORT_API Eina_Bool ewk_media_translated_url_set(Evas_Object* ewkView, const ch EXPORT_API Eina_Bool ewk_view_app_preload_set(Evas_Object* ewkView, Eina_Bool is_preload); /** +* Set app enable marlin or not. +* +* @param ewkView view object +* @param is_enable if app enable marlin drm +* +* @return @c EINA_TRUE on success or @c EINA_FALSE on failure +*/ +EXPORT_API Eina_Bool ewk_view_marlin_enable_set(Evas_Object* ewkView, Eina_Bool is_enable); + +/** + * Sets whitelisted DRM key systems. Passed key systems will be available + * through EME. Other systems even if available in the platform will be + * unavailable through EME + * + * @param ewkView View object + * @param list Key system names + * @param list_size Key system count + */ +EXPORT_API Eina_Bool ewk_view_key_system_whitelist_set(Evas_Object* ewkView, + const char** list, + unsigned list_size); + +/** + * Sets the active DRM system identifier as provided by the HbbTV application. + * + * @param ewkView View object + * @param drm_system_id Identifier of requested DRM system + * + * @return @c EINA_TRUE on success or @c EINA_FALSE on failure + */ +EXPORT_API Eina_Bool ewk_view_active_drm_set(Evas_Object* view, const char* drm_system_id); + +/** +* Set the selected text track language to media player. +* +* @param ewkView view object +* @param lang_list comma separated three_digit_language code. (For example "eng,deu") +* +*/ +EXPORT_API void ewk_media_set_subtitle_lang(Evas_Object* ewkView, const char* lang_list); + + +/** +* Set parental rating result to media player. +* +* @param ewkView view object +* @param url media url +* @param is_pass authentication result true/false +* +*/ +EXPORT_API void ewk_media_set_parental_rating_result(Evas_Object* ewkView, const char* url, Eina_Bool is_pass); + +/** +* Set the if use high bit rate to media player. +* +* @param ewkView view object +* @param is_high if app use high bit rate +* +*/ +EXPORT_API void ewk_media_start_with_high_bit_rate(Evas_Object* ewkView, Eina_Bool is_high_bitrate); + + +/** * @brief Sends key event. * * @since_tizen 2.4 @@ -958,47 +1066,64 @@ EXPORT_API void ewk_view_add_dynamic_certificate_path(const Evas_Object *ewkView * @param[in] o View object to set the atk use. * @param[in] enable EINA_TRUE to set on the atk use. * EINA_FALSE makes atk not to use, but app use WebSpeech instead of ATK. - * The default value is EINA_FALSE. */ EXPORT_API void ewk_view_atk_deactivation_by_app(Evas_Object* view, Eina_Bool enable); -/* - * Get cookies associated with an URL. +typedef enum { + EWK_TTS_MODE_DEFAULT = 0, /**< Default mode for normal application */ + EWK_TTS_MODE_NOTIFICATION = 1, /**< Notification mode(it has same behavior with EWK_TTS_MODE_DEFAULT. not supported in vd) */ + EWK_TTS_MODE_SCREEN_READER = 2 /**< Accessibiliity mode(TTS works only for accessibility mode) */ +} ewk_tts_mode; + +/** + * @brief Sets tts mode + * up to tizen 4.0(in VD), default tts mode is EWK_TTS_MODE_SCREEN_READER. + * so TTS api disabled when accessibility mode turn off. + * this api provided to use tts api in none accessibility mode + * (tts mode decided in chromium's init time. so it should be called in init time) + * tts mode affect to below web apis + * speech_syntesis * - * @param o view object in which URL is opened. - * @param url the url for which cookies needs to be obtained. + * @since_tizen 4.0 @if TV @endif * - * @return @c character array containing cookies, @c NULL if no cookies are found. + * @param[in] o View object to set. + * @param[in] ewk_tts_mode. * - * The return character array has to be owned by the application and freed when not required. */ -EXPORT_API char* ewk_view_cookies_get(Evas_Object* o, const char* url); +EXPORT_API Eina_Bool ewk_view_tts_mode_set(Evas_Object* view, ewk_tts_mode tts_mode); /** - * @brief To give a chance to intercept request data before sending it. + * remove custom header * - * @since_tizen 2.3 + * @param o view object to remove custom header * - * @param[in] o view object to intercept request - * @param[in] intercept_request Defined structure to notify requesting infomation - * @param[in] user_data user data + * @param name custom header name to remove the custom header * - * @see ewk_view_intercept_request_callback_set() + * @return @c EINA_TRUE on success or @c EINA_FALSE on failure */ -typedef void (*Ewk_View_Intercept_Request_Callback)(Evas_Object* o, Ewk_Intercept_Request* intercept_request, void* user_data); +EXPORT_API Eina_Bool ewk_view_custom_header_remove(const Evas_Object* o, const char* name); /** - * @brief To set Ewk_View_Intercept_Request_Callback to give a chance to intercept request data before sending it. + * Returns application name string. * - * @since_tizen 2.3 + * @param o view object to get the application name * - * @param[in] o view object to intercept request - * @param[in] callback Defined callback - * @param[in] user_data user data + * @return @c application name. The returned string @b should be freed by + * eina_stringshare_del() after use. + */ +EXPORT_API const char* ewk_view_application_name_for_user_agent_get(const Evas_Object* o); + +/* + * Get cookies associated with an URL. * - * @see Ewk_View_Intercept_Request_Callback + * @param o view object in which URL is opened. + * @param url the url for which cookies needs to be obtained. + * + * @return @c character array containing cookies, @c NULL if no cookies are found. + * + * The return character array has to be owned by the application and freed when not required. */ -EXPORT_API void ewk_view_intercept_request_callback_set (Evas_Object* o, Ewk_View_Intercept_Request_Callback callback, void* user_data); +EXPORT_API char* ewk_view_cookies_get(Evas_Object* o, const char* url); /** * @internal @@ -1082,23 +1207,13 @@ EXPORT_API Eina_Bool ewk_view_custom_encoding_set(Evas_Object* o, const char* en EXPORT_API void ewk_view_force_layout(const Evas_Object* o); /** -* Creates a type name for the callback function used to get video current time. -* -* @param o view object -* @param current time of the video -*@param user_data user data will be passed when ewk_media_current_time_get -*called -*/ -typedef void (*Ewk_View_Video_Current_Time_Get_Callback)(Evas_Object *o, double current_time, void *user_data); - -/** * Gets the video's timestamp. * * @param o view object to get the video's timestamp * * @return timestamp value */ -EXPORT_API void ewk_media_current_time_get(const Evas_Object* o, Ewk_View_Video_Current_Time_Get_Callback callback, void *user_data); +EXPORT_API double ewk_view_media_current_time_get(const Evas_Object *o); /** * @brief Enforces web page to close @@ -1112,6 +1227,79 @@ EXPORT_API void ewk_media_current_time_get(const Evas_Object* o, Ewk_View_Video_ EXPORT_API Eina_Bool ewk_view_page_close(Evas_Object* o); /** +* Clear all tile resources. +* +* @param ewkView view object +*/ +EXPORT_API void ewk_view_clear_all_tiles_resources(Evas_Object* ewkView); + +/** +* Request canvas to be shown in full-screen. +* +* @param ewkView view object +*/ +EXPORT_API void ewk_view_request_canvas_fullscreen(Evas_Object* ewkView); + +/** +* play 360 video in the view +* +* @param ewkView view object +*/ +EXPORT_API void ewk_view_360video_play(Evas_Object* ewkView); + +/** +* pause 360 video in the view +* +* @param ewkView view object +*/ +EXPORT_API void ewk_view_360video_pause(Evas_Object* ewkView); + +/** + * Callback for ewk_view_360video_duration + * + * @param o view object + * @param duration 360 video's duration + * @param user_data user_data will be passsed when ewk_view_360video_duration is called + */ +typedef void (*Ewk_360_Video_Duration_Callback)(Evas_Object* o, double duration, void* user_data); + +/** +* get duration of the 360 video in the view +* +* @param ewkView view object +* +* @return duration of the video +*/ +EXPORT_API void ewk_view_360video_duration(Evas_Object* ewkView, Ewk_360_Video_Duration_Callback callback, void* user_data); + +/** + * Callback for ewk_view_360video_current_time + * + * @param o view object + * @param current_time 360 video's current time + * @param user_data user_data will be passsed when ewk_view_360video_current_time is called + */ +typedef void (*Ewk_360_Video_CurrentTime_Callback)(Evas_Object* o, double current_time, void* user_data); + +/** +* get current time of the 360 video in the view +* +* @param ewkView view object +* +* @return current time of the video +*/ +EXPORT_API void ewk_view_360video_current_time(Evas_Object* ewkView, Ewk_360_Video_CurrentTime_Callback callback, void* user_data); + +/** +* set current time of the 360 video in the view +* +* @param ewkView view object +* +* @param current_time set current time +*/ +EXPORT_API void ewk_view_360video_set_current_time(Evas_Object* ewkView, double current_time); + +/** * @brief Request to set the atk usage set by web app(config.xml). * * Some TV apps use WebSpeech instead of use ATK for regulation U.S.FCC @@ -1125,48 +1313,38 @@ EXPORT_API Eina_Bool ewk_view_page_close(Evas_Object* o); */ EXPORT_API void ewk_view_atk_deactivation_by_app(Evas_Object* view, Eina_Bool enable); -typedef enum { - EWK_TTS_MODE_DEFAULT = 0, /**< Default mode for normal application */ - EWK_TTS_MODE_NOTIFICATION = 1, /**< Notification mode(it has same behavior - with EWK_TTS_MODE_DEFAULT. not supported in - vd) */ - EWK_TTS_MODE_SCREEN_READER = - 2 /**< Accessibiliity mode(TTS works only for accessibility mode) */ -} ewk_tts_mode; - /** - * @brief Sets tts mode - * up to tizen 4.0(in VD), default tts mode is EWK_TTS_MODE_SCREEN_READER. - * so TTS api disabled when accessibility mode turn off. - * this api provided to use tts api in none accessibility mode - * (tts mode decided in chromium's init time. so it should be called in init - * time) tts mode affect to below web apis speech_syntesis + * Requests execution of the given script in the main frame and subframes of the page. * - * @since_tizen 4.0 @if TV @endif + * The result value for the execution can be retrieved from the asynchronous callback. * - * @param[in] o View object to set. - * @param[in] ewk_tts_mode. + * @param o The view to execute script + * @param script JavaScript to execute + * @param callback The function to call when the execution is completed, may be @c NULL + * @param user_data User data, may be @c NULL * + * @return @c EINA_TRUE on success or @c EINA_FALSE on failure */ -EXPORT_API Eina_Bool ewk_view_tts_mode_set(Evas_Object* view, ewk_tts_mode tts_mode); +EXPORT_API Eina_Bool ewk_view_script_execute_all_frames(Evas_Object *o, const char *script, Ewk_View_Script_Execute_Cb callback, void *user_data); /** - * @brief Request to set the spatial navigation usage set by hbbtv + * Floating video's window ON/OFF * - * @since_tizen 3.0 + * @param o view object + * @param bool status (true/false) * - * @param[in] settings setting object - * @param[in] enable @c EINA_TRUE enable to use spatial navigation - * @c EINA_FALSE to disable */ -EXPORT_API void ewk_settings_spatial_navigation_enabled_set(Ewk_Settings* settings, Eina_Bool Enabled); +EXPORT_API void ewk_view_floating_window_state_changed(const Evas_Object *o, Eina_Bool status); /** - * Clear all tile resources. + * Auto login by samsung pass + * + * @param view view object + * @param user_name user name to login + * @param password user password to login * - * @param ewkView view object */ -EXPORT_API void ewk_view_clear_all_tiles_resources(Evas_Object* ewkView); +EXPORT_API void ewk_view_auto_login(Evas_Object *view, const char* user_name, const char* password); /** * @} -- 2.7.4