Note that this patch does not directly handle any wayland APIs.
It will be handled in other patch set, enabling blocked feature.
1) All of x11 dependent codes are blocked by flag 'BRINGUP_WAYLAND'.
It is starting point of supporting chromium-efl on wayland.
2) The wayland library rpm packages are included, and
the required packages are listed in alphabetical order in spec file.
3) In gyp, all changes of wayland are located under
the condition 'building_for_tizen' to avoid affecting desktop build.
4) This patch supports builds for TV and mobile on arm-wayland or arm-x11,
including desktop.
Bug: http://web.sec.samsung.net/bugzilla/show_bug.cgi?id=12490
Reviewed by: Antonio Gomes, DaeHyun Ko, Hyunhak Kim, SeungSeop Park
Change-Id: Ie059c270a1545bbba98e4297014f905d5883afe3
Signed-off-by: Youngsoo Choi <kenshin.choi@samsung.com>
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/i.86/ia32/;s/x86_64/x64/;s/amd64/x64/;s/arm.*/arm/;s/i86pc/ia32/;s/aarch64/arm64/')
}
function getPythonVersion() {
-Dchromium_efl_tizen_version=*)
tizen_version=$(echo $1 | sed -e 's#-Dchromium_efl_tizen_version\=\([0-9.]*\)#\1#')
;;
+ -Dtizen_emulator_support=1)
+ tizen_emulator_support=1
+ ;;
+ -Duse_wayland=1)
+ use_wayland=1
+ ;;
esac
shift;
done
-Dtizen_multimedia_use_capi_for_me=0
-Dtizen_multimedia_support=1
-Dwerror=
+ -Duse_wayland=0
"
}
"
fi
-
if [ "$target" == "mobile" ]; then
ADDITIONAL_GYP_PARAMETERS+="-Dtizen_multimedia_use_capi_for_me=0
"
ADDITIONAL_GYP_PARAMETERS+="-Dtizen_multimedia_use_capi_for_me=0
"
fi
+
+ add_wayland_flags
+}
+
+add_wayland_flags() {
+ if [ "$use_wayland" == "1" ]; then
+ ADDITIONAL_GYP_PARAMETERS+="-Duse_wayland=1
+ -Dwayland_bringup=1
+ -Duse_x11=0
+ -Dtizen_multimedia_pixmap_support=0
+ "
+ else
+ ADDITIONAL_GYP_PARAMETERS+="-Duse_wayland=0
+ -Dwayland_bringup=0
+ -Duse_x11=1
+ "
+ fi
}
add_gbs_flags() {
{
'target_name': 'ecore-x',
'type': 'none',
- 'direct_dependent_settings': {
- 'cflags': [
- '<!@(<(pkg-config) --cflags ecore-x)',
- ],
- },
- 'link_settings': {
- 'ldflags': [
- '<!@(<(pkg-config) --libs-only-L --libs-only-other ecore-x)',
- ],
- 'libraries': [
- '<!@(<(pkg-config) --libs-only-l ecore-x)',
- ],
- },
+ 'conditions': [
+ ['use_wayland==0', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags ecore-x)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other ecore-x)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l ecore-x)',
+ ],
+ },
+ }],
+ ],
}, # ecore-x
{
+ 'target_name': 'ecore-wayland',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags ecore-wayland)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other ecore-wayland)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l ecore-wayland)',
+ ],
+ },
+ }],
+ ],
+ }, # ecore-wayland
+ {
'target_name': 'ecore-evas',
'type': 'none',
'direct_dependent_settings': {
'target_name': 'libdri2',
'type': 'none',
'conditions': [
- ['building_for_tizen==1', {
+ ['building_for_tizen==1 and use_wayland==0', {
'direct_dependent_settings': {
'cflags': [
'<!@(<(pkg-config) --cflags libdri2)',
}],
],
}, # feedback
+ {
+ 'target_name': 'wayland-client',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags wayland-client)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other wayland-client)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l wayland-client)',
+ ],
+ },
+ }],
+ ],
+ }, # wayland-client
+ {
+ 'target_name': 'wayland-cursor',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags wayland-cursor)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other wayland-cursor)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l wayland-cursor)',
+ ],
+ },
+ }],
+ ],
+ }, # wayland-cursor
+ {
+ 'target_name': 'wayland-egl',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags wayland-egl)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other wayland-egl)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l wayland-egl)',
+ ],
+ },
+ }],
+ ],
+ }, # wayland-egl
+ {
+ 'target_name': 'wayland-server',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags wayland-server)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other wayland-server)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l wayland-server)',
+ ],
+ },
+ }],
+ ],
+ }, # wayland-server
+ {
+ 'target_name': 'xkbcommon',
+ 'type': 'none',
+ 'conditions': [
+ ['building_for_tizen==1 and use_wayland==1', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags xkbcommon)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other xkbcommon)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l xkbcommon)',
+ ],
+ },
+ }],
+ ],
+ }, # xkbcommon
],
}
#include <Ecore.h>
#include <Ecore_Evas.h>
#include <Ecore_Input.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <Elementary.h>
#include "base/auto_reset.h"
int height = std::min(size.height(), EFL_MAX_HEIGHT);
if (popup_type_ != blink::WebPopupTypeNone) {
// We're a popup, honor the size request.
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_resize(GetEcoreXWindow(), width, height);
+#else
+ NOTIMPLEMENTED();
+#endif
}
// Update the size of the RWH.
return;
if (!move.visible) {
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_hide(surface_window);
+#else
+ NOTIMPLEMENTED();
+#endif
return;
}
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_show(surface_window);
+#else
+ NOTIMPLEMENTED();
+#endif
if (!move.rects_valid)
return;
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_move(surface_window, move.window_rect.x(), move.window_rect.y());
ecore_x_window_resize(surface_window, move.window_rect.width(), move.window_rect.height());
+#else
+ NOTIMPLEMENTED();
+#endif
}
void RenderWidgetHostViewEfl::MovePluginWindows(
void RenderWidgetHostViewEfl::UpdateCursor(const WebCursor& webcursor) {
if (is_loading_) {
// Setting native Loading cursor
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_cursor_set(GetEcoreXWindow(), ecore_x_cursor_shape_get(ECORE_X_CURSOR_CLOCK));
+#else
+ NOTIMPLEMENTED();
+#endif
} else {
WebCursor::CursorInfo cursor_info;
webcursor.GetCursorInfo(&cursor_info);
int cursor_type = GetCursorType(cursor_info.type);
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_cursor_set(GetEcoreXWindow(), ecore_x_cursor_shape_get(cursor_type));
+#else
+ NOTIMPLEMENTED();
+#endif
}
// Need to check for cursor visibility
//ecore_x_window_cursor_show(GetEcoreXWindow(), true);
if (!rwhv->touch_events_enabled_) {
blink::WebMouseEvent event = MakeWebMouseEvent(obj,
- static_cast<Evas_Event_Mouse_Move*>(event_info));
+ static_cast<Evas_Event_Mouse_Move*>(event_info));
rwhv->host_->ForwardMouseEvent(event);
} else {
rwhv->ProcessTouchEvents();
return;
if (!rwhv->touch_events_enabled_) {
- blink::WebMouseWheelEvent event = MakeWebMouseEvent(
- obj, static_cast<Evas_Event_Mouse_Wheel*>(event_info));
- rwhv->host_->ForwardWheelEvent(event);
+ blink::WebMouseWheelEvent event = MakeWebMouseEvent(
+ obj, static_cast<Evas_Event_Mouse_Wheel*>(event_info));
+ rwhv->host_->ForwardWheelEvent(event);
}
}
// found in the LICENSE file.
#include "content/common/cursors/webcursor_efl.h"
-#include "ecore_x_wrapper.h"
+#include "ecore_x_wayland_wrapper.h"
#include "base/logging.h"
#include "content/common/cursors/webcursor.h"
} // namespace content
int GetCursorType(int type) {
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
switch (type) {
case WebCursorInfo::TypePointer:
return ECORE_X_CURSOR_ARROW;
}
NOTREACHED();
return ECORE_X_CURSOR_XTERM;
+#else
+ NOTIMPLEMENTED();
+ return 0;
+#endif
}
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)) {
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)) {
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();
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<GpuMemoryBufferImpl>();
}
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<GpuMemoryBufferImpl>(new GpuMemoryBufferImplEflPixmap(
handle.id, size, format, callback,make_scoped_ptr<gfx::EflPixmapImpl>(new gfx::EflPixmapImpl(
gfx::EflPixmapBase::BUFFER, handle.efl_pixmap_id))));
+#else
+ NOTIMPLEMENTED();
+ return NULL;
+#endif
}
void GpuMemoryBufferImplEflPixmap::DeletedByChildProcess(
gfx::GpuMemoryBuffer::Usage usage,
int client_id) override {
switch (type) {
- case gfx::EFL_PIXMAP_BUFFER:{
+ 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();
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();
return image;
}
case gfx::EFL_PIXMAP_BUFFER: {
- return efl_pixmap_factory_.CreateImageForGpuMemoryBuffer(
+ // 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();
}
}
+#if !defined(WAYLAND_BRINGUP)
private:
+ // TODO: Rendering TG will implement following for Wayland.
GpuMemoryBufferFactoryEflPixmap efl_pixmap_factory_;
+#endif
};
} // namespace
{
'variables': {
'external_content_common_deps': [
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
'<(DEPTH)/tizen_src/build/system.gyp:capi-appfw-application',
'<(DEPTH)/tizen_src/build/system.gyp:capi-system-system-settings',
'<(DEPTH)/tizen_src/build/system.gyp:gstreamer',
],
'external_content_browser_deps': [
'<(DEPTH)/tizen_src/build/system.gyp:ecore',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
'<(DEPTH)/tizen_src/build/system.gyp:ecore-imf-evas',
'<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
'<(DEPTH)/tizen_src/build/system.gyp:elementary',
'external_content_shell_deps': [
'<(DEPTH)/tizen_src/build/system.gyp:evas',
'<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
'<(DEPTH)/tizen_src/build/system.gyp:elementary',
'<(DEPTH)/tizen_src/chromium_impl/efl/efl.gyp:efl-init',
'<(DEPTH)/tizen_src/chromium_impl/components/components.gyp:js_dialogs_efl',
'external_native_theme_deps': [
'<(DEPTH)/tizen_src/chromium_impl/ui/ui_targets_efl.gyp:ui_native_theme_inject',
],
+ 'conditions': [
+ ['use_wayland==0', {
+ 'external_content_common_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ 'external_content_browser_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ 'external_content_shell_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ },
+ {
+ 'external_content_common_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ 'external_content_browser_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ 'external_content_shell_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ }],
+ ],
},
'target_defaults': {
if (!bsm || !timetofull_changed_cb)
return;
- char* keyname = vconf_keynode_get_name(key);
+ const char* keyname = vconf_keynode_get_name(key);
if (keyname == NULL)
return;
time > 0) {
timetofull_changed_cb(time, timetofull_cb_user_data);
}
-
- free(keyname);
}
void timetoempty_vconf_cb(keynode_t* key, void* data) {
if (!bsm || !timetoempty_changed_cb)
return;
- char* keyname = vconf_keynode_get_name(key);
+ const char* keyname = vconf_keynode_get_name(key);
if (keyname == NULL)
return;
time > 0) {
timetoempty_changed_cb(time, timetoempty_cb_user_data);
}
-
- free(keyname);
}
void OnChargingStatusChanged(keynode_t* key, void* data) {
#include "efl/init.h"
#include <Elementary.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <Ecore.h>
#include "base/logging.h"
elm_config_accel_preference_set("hw");
ecore_init();
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_init(NULL);
+#else
+ NOTIMPLEMENTED();
+#endif
eina_init();
evas_init();
#include "ui/gl/efl_pixmap.h"
#include <Ecore.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#endif
namespace media {
#define MEDIA_BASE_EFL_MEDIA_SOURCE_PLAYER_GSTREAMER_H_
#include <Ecore.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <gst/gst.h>
#include "base/cancelable_callback.h"
#if defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
#include <Ecore.h>
-#include "ecore_x_wrapper.h"
+#include "ecore_x_wayland_wrapper.h"
#endif
#include "base/memory/scoped_ptr.h"
'variables': {
'external_media_deps': [
'<(DEPTH)/tizen_src/build/system.gyp:ecore',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
'<(DEPTH)/tizen_src/build/system.gyp:gstreamer',
'<(DEPTH)/tizen_src/build/system.gyp:capi-media-camera',
],
+ 'conditions': [
+ ['use_wayland==0', {
+ 'external_media_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ },
+ {
+ 'external_media_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ }],
+ ],
},
'target_defaults': {
#include <Evas.h>
#include <Ecore_Evas.h>
-#include "ecore_x_wrapper.h"
+#include "ecore_x_wayland_wrapper.h"
#include <Elementary.h>
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
#include <X11/Xatom.h>
#include <X11/Xlib.h>
+#endif
#include "base/memory/singleton.h"
#include "base/logging.h"
struct ClipData
{
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Selection selection;
void (* request)(Ecore_X_Window window, const char* pTarget);
+#endif
Elm_Sel_Format format;
Elm_Sel_Format requestedFormat;
EWebView* webView;
};
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
typedef int (*ClipNotifyHandler)(ClipData* clipData, Ecore_X_Event_Selection_Notify* notifyData);
+#endif
enum
{
{
const char* pName;
Elm_Sel_Format formats;
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ClipNotifyHandler notify;
Ecore_X_Atom atom;
+#endif
};
AtomData atomList[ATOM_MAX];
Eina_Bool propertyChangeCallback(void* data, int type, void* event) {
ClipboardHelperEfl *clipboardHelper = static_cast<ClipboardHelperEfl*>(data);
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Event_Window_Property *ev = (Ecore_X_Event_Window_Property*) event;
if (ev->atom == ECORE_X_ATOM_E_ILLUME_CLIPBOARD_STATE)
clipboardHelper->UpdateClipboardWindowState(ev);
+#else
+ NOTIMPLEMENTED();
+#endif
return EINA_TRUE;
}
}
void ClipboardHelperEfl::SetData(const std::string& data, ClipboardDataType type) {
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Atom data_type = 0;
switch(type)
}
SetClipboardItem(data_type, data);
+#else
+ NOTIMPLEMENTED();
+#endif
}
void ClipboardHelperEfl::Clear() {
NOTIMPLEMENTED();
}
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Window ClipboardHelperEfl::GetCbhmWindow() {
Ecore_X_Atom xAtomCbhm = ecore_x_atom_get(kCbhmAtomXWindow);
Ecore_X_Window xCbhmWin = 0;
return xCbhmWin;
}
+#endif
bool ClipboardHelperEfl::SendCbhmMessage(const std::string& message) {
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Window cbhm_win = GetCbhmWindow();
Ecore_X_Atom atom_cbhm_item = ecore_x_atom_get(kCbhmAtomMessage);
reinterpret_cast<XEvent*>(&messageEvent));
ecore_x_sync();
+#else
+ NOTIMPLEMENTED();
+#endif
return true;
}
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
bool ClipboardHelperEfl::SetClipboardItem(Ecore_X_Atom data_type,const std::string& data) {
if (data.empty())
return false;
return false;
}
+#endif
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
std::string ClipboardHelperEfl::GetCbhmReply(Ecore_X_Window xwin, Ecore_X_Atom property, Ecore_X_Atom* data_type) {
if (!property)
return std::string();
return cbhm_data;
}
+#endif
bool ClipboardHelperEfl::RetrieveClipboardItem(int index, int* format, std::string* data) {
if (!data)
return false;
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Window cbhm_win = GetCbhmWindow();
std::ostringstream cbhm_item;
cbhm_item << kCbhmAtomItem << index;
data->swap(result);
return true;
}
+#else
+ NOTIMPLEMENTED();
+#endif
return false;
}
int ClipboardHelperEfl::NumberOfItems() {
// 1. Get CBHM Ecore_X_Window.
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Atom x_atom;
x_atom = ecore_x_atom_get(kCbhmAtomXWindow);
if (!x_atom)
return 0;
}
return count;
+#else
+ NOTIMPLEMENTED();
+ return 0;
+#endif
}
static void pasteSelectedClipboardItem(std::string data, std::string type, EWebView *webview) {
}
static Eina_Bool clearClip(void* data, int type, void* event) {
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Event_Selection_Clear* clearEvent = (Ecore_X_Event_Selection_Clear*) event;
Ecore_X_Window window = clearEvent->win;
clipList[clipType].requestedFormat = static_cast<Elm_Sel_Format>(ELM_SEL_FORMAT_TEXT | ELM_SEL_FORMAT_IMAGE);
ecore_x_selection_secondary_request(window, ECORE_X_SELECTION_TARGET_TARGETS);
+#else
+ NOTIMPLEMENTED();
+#endif
return ECORE_CALLBACK_PASS_ON;
}
static Eina_Bool notifyClip(void* data , int type, void* event) {
EWebView *webview = static_cast<EWebView*>(data);
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Event_Selection_Notify* notifytEvent = (Ecore_X_Event_Selection_Notify*) event;
int i = 0;
if (!strcmp(notifytEvent->target, atomList[i].pName) && atomList[i].notify)
atomList[i].notify(clipData, notifytEvent);
}
+#else
+ NOTIMPLEMENTED();
+#endif
return ECORE_CALLBACK_PASS_ON;
}
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
static int notifyTarget(ClipData* clipData, Ecore_X_Event_Selection_Notify* notifyData) {
Ecore_X_Atom dataType = 0;
clipData->request(notifyData->win, atomList[j].pName);
return ECORE_CALLBACK_PASS_ON;
}
+#endif
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
static int notifyText(ClipData* clipData, Ecore_X_Event_Selection_Notify* notifyData) {
Ecore_X_Selection_Data* pData = (Ecore_X_Selection_Data*) notifyData->data;
pasteSelectedClipboardItem(std::string((char*)pData->data), "InsertText", clipData->webView);
"InsertHTML", clipData->webView);
return 0;
}
+#endif
void ClipboardHelperEfl::initializeAtomList() {
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
atomList[ATOM_TARGETS].pName = "TARGETS";
atomList[ATOM_TARGETS].formats = ELM_SEL_FORMAT_TARGETS;
atomList[ATOM_TARGETS].notify = notifyTarget;
for (int i = 0; i < ATOM_MAX; i++)
atomList[i].atom = ecore_x_atom_get(atomList[i].pName);
+#else
+ NOTIMPLEMENTED();
+#endif
}
void ClipboardHelperEfl::clearClipboardHandler() {
clipboard_window_opened_ = false;
}
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
bool ClipboardHelperEfl::getSelectedCbhmItem(Ecore_X_Atom* pDataType) {
Ecore_X_Window cbhmWin = GetCbhmWindow();
Ecore_X_Atom atomCbhmItem = ecore_x_atom_get("CBHM_SELECTED_ITEM");
return true;
}
+#endif
void ClipboardHelperEfl::OpenClipboardWindow(EWebView* view, bool richly_editable) {
clearClipboardHandler();
initializeAtomList();
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
property_change_handler_ = ecore_event_handler_add(
ECORE_X_EVENT_WINDOW_PROPERTY, propertyChangeCallback, this);
m_selectionClearHandler = ecore_event_handler_add(ECORE_X_EVENT_SELECTION_CLEAR, clearClip, view);
m_selectionNotifyHandler = ecore_event_handler_add(ECORE_X_EVENT_SELECTION_NOTIFY, notifyClip, view);
+#else
+ NOTIMPLEMENTED();
+#endif
if (richly_editable)
SendCbhmMessage(kCbhmMessageShow1);
}
void ClipboardHelperEfl::connectClipboardWindow() {
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_selection_secondary_set(ecore_x_window_focus_get(), "",1);
+#else
+ NOTIMPLEMENTED();
+#endif
}
bool ClipboardHelperEfl::IsClipboardWindowOpened() {
SendCbhmMessage(kCbhmMessageHide);
}
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
void ClipboardHelperEfl::UpdateClipboardWindowState(Ecore_X_Event_Window_Property* ev) {
Ecore_X_Illume_Clipboard_State state = ecore_x_e_illume_clipboard_state_get(ev->win);
else if (state == ECORE_X_ILLUME_CLIPBOARD_STATE_ON)
clipboard_window_opened_ = true;
}
+#endif
#include <string>
#include <Ecore.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include "base/basictypes.h"
void OpenClipboardWindow(EWebView* view, bool richly_editable);
void CloseClipboardWindow();
bool IsClipboardWindowOpened();
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
bool getSelectedCbhmItem(Ecore_X_Atom* pDataType);
void UpdateClipboardWindowState(Ecore_X_Event_Window_Property* ev);
+#endif
static void connectClipboardWindow();
private:
ClipboardHelperEfl();
friend struct DefaultSingletonTraits<ClipboardHelperEfl>;
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Window GetCbhmWindow();
+#endif
bool SendCbhmMessage(const std::string& message);
+ // TODO: Webview TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
bool SetClipboardItem(Ecore_X_Atom data_type, const std::string& data);
std::string GetCbhmReply(Ecore_X_Window xwin, Ecore_X_Atom property, Ecore_X_Atom* data_type);
+#endif
void clearClipboardHandler();
void initializeAtomList();
DISALLOW_COPY_AND_ASSIGN(ClipboardHelperEfl);
#include "ui/gfx/screen_efl.h"
+#if !defined(WAYLAND_BRINGUP)
#include <Ecore_X.h>
+#endif
#include "content/browser/renderer_host/dip_util.h"
#include "ui/gfx/screen_type_delegate.h"
}
gfx::Display GetPrimaryDisplay() const override {
+ // TODO: Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
Ecore_X_Screen* screen = ecore_x_default_screen_get();
+#else
+ NOTIMPLEMENTED();
+#endif
const float device_scale_factor =
gfx::Display::HasForceDeviceScaleFactor() ?
#endif
int width, height;
+ // TODO: Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
if (display.rotation() == gfx::Display::ROTATE_90 ||
display.rotation() == gfx::Display::ROTATE_270) {
ecore_x_screen_size_get(screen, &height, &width);
} else {
ecore_x_screen_size_get(screen, &width, &height);
}
+#else
+ NOTIMPLEMENTED();
+#endif
const gfx::Rect bounds_in_pixels = gfx::Rect(width, height);
const gfx::Rect bounds_in_dip =
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();
'external_ui_gl_deps': [
'<(DEPTH)/tizen_src/build/system.gyp:evas',
'<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
- '<(DEPTH)/tizen_src/build/system.gyp:libdri2',
'<(DEPTH)/tizen_src/build/system.gyp:libdrm',
'<(DEPTH)/tizen_src/build/system.gyp:libtbm',
],
- 'external_ui_gfx_x11_deps': [
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
- ],
- 'external_ui_gfx_deps': [
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ 'conditions': [
+ ['use_wayland==0', {
+ 'external_ui_gl_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:libdri2',
+ ],
+ 'external_ui_gfx_x11_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ 'external_ui_gfx_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ },
+ {
+ 'external_ui_gfx_deps': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ }],
],
'external_ui_events_deps': [
'<(DEPTH)/tizen_src/chromium_impl/ui/ui_targets_efl.gyp:ui_events_source_inject',
'sources/': [
['exclude', 'x11_event_source_glib\\.cc$'],
['exclude', 'x11_event_source_libevent\\.cc$'],
- ]
+ ],
}],
['_target_name=="gesture_detection"', {
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef ECORE_X_WRAPPER_H_
-#define ECORE_X_WRAPPER_H_
+#ifndef ECORE_X_WAYLAND_WRAPPER_H_
+#define ECORE_X_WAYLAND_WRAPPER_H_
+#if defined(USE_WAYLAND)
+#include <Ecore_Wayland.h>
+#else
#include <Ecore_X.h>
+#endif
#endif
#if defined(TIZEN_AUTOFILL_SUPPORT)
#include <Ecore.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <Edje.h>
#include <Eina.h>
#include <Elementary.h>
evas_object_focus_set(popup_, true);
int width, height;
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), &width, &height);
+#else
+ NOTIMPLEMENTED();
+#endif
evas_object_resize(popup_, width, height);
evas_object_move(popup_, 0, 0);
return true;
int popupHeight;
int width, height;
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), &width, &height);
+#else
+ NOTIMPLEMENTED();
+#endif
evas_object_geometry_get(obj, 0, 0, 0, &popupHeight);
JavaScriptModalDialogEfl* popup = static_cast<JavaScriptModalDialogEfl*>(data);
#include <Evas.h>
#include <Elementary.h>
-#include "ecore_x_wrapper.h"
+#include "ecore_x_wayland_wrapper.h"
class EWebView;
#include <Elementary.h>
#include <libintl.h>
-#include "ecore_x_wrapper.h"
+#include "ecore_x_wayland_wrapper.h"
#ifdef OS_TIZEN_MOBILE
#include <dlfcn.h>
#include <efl_assist.h>
std::string(),
params_.link_url.spec());
}
+#if !defined(WAYLAND_BRINGUP)
if (params_.is_editable && ClipboardHelperEfl::NumberOfItems() > 0) {
AddItemToPropsedList(MENU_ITEM_TYPE_ACTION, MENU_ITEM_PASTE,
std::string(dgettext("WebKit", "IDS_WEBVIEW_OPT_PASTE")));
}
+#else
+ NOTIMPLEMENTED();
+#endif
if (!params_.selection_text.empty() && params_.is_editable) {
AddItemToPropsedList(MENU_ITEM_TYPE_ACTION, MENU_ITEM_CUT,
std::string(dgettext("WebKit", "IDS_WEBVIEW_OPT_CUT_ABB")));
std::string(dgettext("WebKit", "IDS_WEBVIEW_OPT_DRAG_AND_DROP")));
}
#endif
+#if !defined(WAYLAND_BRINGUP)
if (params_.is_editable && ClipboardHelperEfl::NumberOfItems() > 0) {
AddItemToPropsedList(MENU_ITEM_TYPE_ACTION, MENU_ITEM_CLIPBOARD,
std::string(dgettext("WebKit", "IDS_WEBVIEW_OPT_CLIPBOARD")));
}
+#else
+ NOTIMPLEMENTED();
+#endif
}
bool ContextMenuControllerEfl::CreateContextMenu() {
}
}
+#if !defined(WAYLAND_BRINGUP)
int width = 0;
int height = 0;
ecore_x_screen_size_get(ecore_x_default_screen_get(), &width, &height);
+#else
+ NOTIMPLEMENTED();
+#endif
evas_object_size_hint_weight_set(popup_, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
if(download && download->AllDataSaved()) {
if (clipboard_download_items_.find(download) != clipboard_download_items_.end()) {
const std::string& DownloadPath = download->GetForcedFilePath().value();
+#if !defined(WAYLAND_BRINGUP)
ClipboardHelperEfl::GetInstance()->SetData(DownloadPath,
ClipboardHelperEfl::CLIPBOARD_DATA_TYPE_IMAGE);
+#else
+ NOTIMPLEMENTED();
+#endif
download->RemoveObserver(this);
clipboard_download_items_.erase(download);
}
break;
}
case MENU_ITEM_COPY_LINK_TO_CLIPBOARD: {
+#if !defined(WAYLAND_BRINGUP)
ClipboardHelperEfl::GetInstance()->SetData(params_.link_url.spec(),
ClipboardHelperEfl::CLIPBOARD_DATA_TYPE_URL);
+#else
+ NOTIMPLEMENTED();
+#endif
break;
}
case MENU_ITEM_DOWNLOAD_LINK_TO_DISK: {
// TODO: set true for richly editable.
// Paste operations are blocked by Editor if content is not richly editible.
// Need to find if webview_ has rich editor.
+#if !defined(WAYLAND_BRINGUP)
ClipboardHelperEfl::GetInstance()->OpenClipboardWindow(webview_, true);
+#else
+ NOTIMPLEMENTED();
+#endif
break;
}
-#if !defined(EWK_BRINGUP)
case MENU_ITEM_DRAG: {
+#if !defined(EWK_BRINGUP)
RenderViewHost* rvh = web_contents_.GetRenderViewHost();
rvh->StartDragging();
context_menu_show_pos_.SetPoint(params_.x, params_.y);
+#else
+ NOTIMPLEMENTED();
+#endif
break;
}
-#endif
default:
CustomMenuItemSelected(menu_item);
}
],
'defines': [
- 'HAVE_ECORE_X=<!(if pkg-config ecore-x; then echo 1; fi)',
'CHROMIUM_VERSION=\"<!(python <(version_script) -f <(version_file) -t "<(version_pattern)")\"',
],
'link_settings': {
'-fvisibility=hidden',
],
'conditions': [
+ ['use_wayland==0', {
+ 'defines': [
+ 'HAVE_ECORE_X=<!(if pkg-config ecore-x; then echo 1; fi)'
+ ],
+ }],
['building_for_tizen==1', {
'sources/': [
[ 'exclude', 'browser/sound_effect\\.(cc|h)$' ],
int width = 0;
int height = 0;
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
if (orientation == 0 || orientation == 180) {
ecore_x_screen_size_get(ecore_x_default_screen_get(), &width, &height);
} else {
ecore_x_screen_size_get(ecore_x_default_screen_get(), &height, &width);
}
+#else
+ NOTIMPLEMENTED();
+#endif
if (context_menu_)
context_menu_->SetPopupSize(width, height);
if (inputPicker_)
// Chromium doesn't expect (and doesn't like) these events.
continue;
}
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
if (rwhv()) {
Evas_Coord_Point pt;
pt.x = point->x;
pt, point->state, point->id, evas_object());
rwhv()->HandleTouchEvent(&touch_event);
}
+#else
+ NOTIMPLEMENTED();
+#endif
}
}
#include <Eina.h>
#include <Elementary.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include "base/logging.h"
#include "popup_controller_efl.h"
#include "ui/base/clipboard/clipboard_helper_efl.h"
#if defined(OS_TIZEN)
+// TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
#include <ui-gadget.h>
+#endif
#include <app_control.h>
#else
#include <gio/gio.h>
evas_object_move(popup_, 0, 0);
}
-} //namespace
+} // namespace
#include "private/ewk_private.h"
#include "private/ewk_main_private.h"
-#if defined(HAVE_ECORE_X)
-#include <Ecore_X.h>
-#endif
+#include "ecore_x_wayland_wrapper.h"
static int _ewkInitCount = 0;
#include <Ecore_Evas.h>
#include <Ecore_File.h>
#include <Ecore_Getopt.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <Evas.h>
#include <Elementary.h>
int width = 800;
int height = 600;
+#if defined(USE_WAYLAND)
+ ee = ecore_evas_new("wayland_egl", 0, 0, width, height, 0);
+#else
ee = ecore_evas_new("opengl_x11", 0, 0, width, height, 0);
+#endif
e = ecore_evas_get(ee);
ecore_evas_callback_delete_request_set(ee, _evas_close_cb);
if (use_fullscreen) {
// FIXME: this is wrong with dual screen configuration (desktop).
// We should use XineramaQueryScreens for that setup.
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), &width, &height);
+#endif
ecore_evas_size_base_set(ee, width, height);
}
const int default_width = 300;
const int default_height = 400;
+#if defined(USE_WAYLAND)
+ Ecore_Evas* ee = ecore_evas_new("wayland_egl", 0, 0, default_width, default_height, 0);
+#else
Ecore_Evas* ee = ecore_evas_new("opengl_x11", 0, 0, default_width, default_height, 0);
+#endif
Evas* e = ecore_evas_get(ee);
Evas_Object* view = ewk_view_add(e);
'<(DEPTH)/tizen_src/build/system.gyp:evas',
'<(DEPTH)/tizen_src/build/system.gyp:ecore',
'<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
'<(DEPTH)/tizen_src/build/system.gyp:elementary',
'chromium-ewk',
'launch_exec',
],
+ 'conditions': [
+ ['use_wayland==0', {
+ 'dependencies': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ },
+ {
+ 'dependencies': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ }],
+ ],
'include_dirs': [
'../efl_integration',
],
{
'target_name': 'mini_browser',
'type': 'executable',
- 'conditions': [
+ 'conditions': [
['building_for_tizen==1', { # FIXME: mini_browser shouldn't depend on dlog and appcore-efl without OS(TIZEN) checks
- 'sources': [
- 'mini_browser.c',
- 'browser-object.h',
- 'browser-string.h',
- ],
- 'include_dirs': [
- '../efl_integration',
- ],
- 'dependencies': [
- '<(DEPTH)/tizen_src/build/system.gyp:capi-appfw-application',
- '<(DEPTH)/tizen_src/build/system.gyp:capi-system-device',
- '<(DEPTH)/tizen_src/build/system.gyp:evas',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
- '<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
- '<(DEPTH)/tizen_src/build/system.gyp:efl-assist',
- '<(DEPTH)/tizen_src/build/system.gyp:elementary',
- '<(DEPTH)/build/linux/system.gyp:glib',
- 'chromium-ewk',
- ],
- 'cflags': [
- '<!@(pkg-config --cflags dlog)',
- ],
- 'link_settings': {
- 'ldflags': [
- '<!@(pkg-config --libs-only-L --libs-only-other dlog)',
+ 'sources': [
+ 'mini_browser.c',
+ 'browser-object.h',
+ 'browser-string.h',
+ ],
+ 'include_dirs': [
+ '../efl_integration',
+ ],
+ 'dependencies': [
+ '<(DEPTH)/tizen_src/build/system.gyp:capi-appfw-application',
+ '<(DEPTH)/tizen_src/build/system.gyp:capi-system-device',
+ '<(DEPTH)/tizen_src/build/system.gyp:evas',
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore',
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-evas',
+ '<(DEPTH)/tizen_src/build/system.gyp:efl-assist',
+ '<(DEPTH)/tizen_src/build/system.gyp:elementary',
+ '<(DEPTH)/build/linux/system.gyp:glib',
+ 'chromium-ewk',
+ ],
+ 'conditions': [
+ ['use_wayland==0', {
+ 'dependencies': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-x',
+ ],
+ },
+ {
+ 'dependencies': [
+ '<(DEPTH)/tizen_src/build/system.gyp:ecore-wayland',
+ ],
+ }],
+ ],
+ 'cflags': [
+ '<!@(pkg-config --cflags dlog)',
],
- 'libraries': [
- '<!@(pkg-config --libs-only-l dlog)',
- ]
- },
- }]
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(pkg-config --libs-only-L --libs-only-other dlog)',
+ ],
+ 'libraries': [
+ '<!@(pkg-config --libs-only-l dlog)',
+ ]
+ },
+ }]
],
}
]
#include <Evas.h>
#include <Eina.h>
#include <Ecore.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
+
#include "efl_integration/public/ewk_context.h"
#include "efl_integration/public/ewk_main.h"
#include "efl_integration/public/ewk_view.h"
#include <Ecore_Evas.h>
#include <Ecore_File.h>
#include <Ecore_Getopt.h>
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
#include <Evas.h>
#include <Elementary.h>
#include <glib/gprintf.h>
evas_object_size_hint_align_set(window, EVAS_HINT_FILL, EVAS_HINT_FILL);
elm_win_borderless_set(window, EINA_TRUE);
elm_win_conformant_set(window, EINA_TRUE);
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), &width, &height);
+#endif
evas_object_resize(window, width, height);
elm_win_indicator_mode_set(window, ELM_WIN_INDICATOR_SHOW);
evas_object_smart_callback_add(webview, "load,progress,finished", __load_progress_finished_cb, data);
evas_object_smart_callback_add(webview, "load,started" , __load_started_cb , data);
evas_object_smart_callback_add(webview, "policy,newwindow,decide", __policy_newwindow_decide_cb, data);
- #if defined(OS_TIZEN_TV)
+#if defined(OS_TIZEN_TV)
evas_object_event_callback_add(webview, EVAS_CALLBACK_MOUSE_DOWN, _webview_mouse_down_cb , data);
- #endif
+#endif
evas_object_smart_callback_add(webview, "policy,response,decide", __policy_response_decide_cb, data);
evas_object_smart_callback_add(webview, "policy,navigation,decide", __navigation_policy_decide_cb, data);
evas_object_smart_callback_add(webview, "geolocation,permission,request", __geolocation_permission_request_cb, data);
{
switch (*changed_ang) {
case APP_DEVICE_ORIENTATION_0:
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), width, height);
+#endif
break;
case APP_DEVICE_ORIENTATION_90:
case APP_DEVICE_ORIENTATION_270:
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), height, width);
+#endif
break;
default:
return;
/* On SIP close, Toolbar bring back to original position*/
if (is_imf_shown) {
int width, height;
+ // TODO: Webview and Rendering TG will implement following for Wayland.
+#if !defined(WAYLAND_BRINGUP)
ecore_x_window_size_get(ecore_x_window_root_first_get(), &width, &height);
+#endif
//evas_object_resize(data->webview, width, height - TOOL_BOX_HEIGHT);
evas_object_move(data->bg_tool_box, 0, height - TOOL_BOX_HEIGHT);
evas_object_show(data->bg_tool_box);
['building_for_tizen==1', {
'cflags': [
'<!@(pkg-config --cflags scim)',
- '<!@(pkg-config --cflags x11)',
],
'link_settings': {
'ldflags': [
'<!@(pkg-config --libs-only-L --libs-only-other scim)',
- '<!@(pkg-config --libs-only-L --libs-only-other x11)',
],
'libraries': [
'<!@(pkg-config --libs-only-l scim)',
- '<!@(pkg-config --libs-only-l x11)',
],
},
}],
// found in the LICENSE file.
#ifdef OS_TIZEN
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
// using scim to simulate keyboard typing
#include <scim.h>
#include <scim_event.h>
// found in the LICENSE file.
#ifdef OS_TIZEN
-#include <Ecore_X.h>
+#include "ecore_x_wayland_wrapper.h"
// using scim to simulate keyboard typing
#include <scim.h>
#include <scim_event.h>
],
},
'conditions': [
- ['use_x11==1', {
+ ['use_wayland==0', {
'dependencies': [
'<(chrome_src_dir)/chrome/../build/linux/system.gyp:x11',
'<(chrome_src_dir)/chrome/../ui/gfx/x/gfx_x11.gyp:gfx_x11',
Requires(post): /sbin/ldconfig
Requires(post): xkeyboard-config
Requires(postun): /sbin/ldconfig
-BuildRequires: which, vi, python, python-xml, bison, flex, gperf, gettext, perl, edje-tools
-BuildRequires: libjpeg-turbo-devel, expat-devel, libcap-devel
-BuildRequires: pkgconfig(tts)
-BuildRequires: pkgconfig(glesv2)
-BuildRequires: pkgconfig(libpulse)
-BuildRequires: pkgconfig(recordproto)
-BuildRequires: pkgconfig(libpci)
-BuildRequires: pkgconfig(pangocairo)
-BuildRequires: pkgconfig(libudev)
+
+BuildRequires: bison, edje-tools, expat-devel, flex, gettext, gperf, libcap-devel
+BuildRequires: libjpeg-turbo-devel, perl, python, python-xml, vi, which
+BuildRequires: pkgconfig(appcore-efl)
+BuildRequires: pkgconfig(capi-appfw-application)
+BuildRequires: pkgconfig(capi-location-manager)
+BuildRequires: pkgconfig(capi-media-audio-io)
+BuildRequires: pkgconfig(capi-media-camera)
+BuildRequires: pkgconfig(capi-media-player)
+BuildRequires: pkgconfig(capi-system-device)
+BuildRequires: pkgconfig(capi-system-info)
+BuildRequires: pkgconfig(capi-system-system-settings)
+BuildRequires: pkgconfig(dlog)
+BuildRequires: pkgconfig(ecore)
+BuildRequires: pkgconfig(ecore-evas)
+BuildRequires: pkgconfig(ecore-imf)
+BuildRequires: pkgconfig(ecore-imf-evas)
+BuildRequires: pkgconfig(ecore-input)
+BuildRequires: pkgconfig(elementary)
+BuildRequires: pkgconfig(evas)
+BuildRequires: pkgconfig(feedback)
+BuildRequires: pkgconfig(flac)
BuildRequires: pkgconfig(fontconfig)
BuildRequires: pkgconfig(freetype2)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(harfbuzz)
BuildRequires: pkgconfig(icu-i18n)
-BuildRequires: pkgconfig(openssl)
+BuildRequires: pkgconfig(libdrm)
+BuildRequires: pkgconfig(libexif)
+BuildRequires: pkgconfig(libpci)
+BuildRequires: pkgconfig(libpng)
+BuildRequires: pkgconfig(libpulse)
+BuildRequires: pkgconfig(libtbm)
+BuildRequires: pkgconfig(libudev)
+BuildRequires: pkgconfig(libusb-1.0)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(libxslt)
BuildRequires: pkgconfig(sqlite3)
BuildRequires: pkgconfig(capi-system-system-settings)
BuildRequires: pkgconfig(capi-location-manager)
BuildRequires: pkgconfig(location)
-BuildRequires: pkgconfig(gles20)
-BuildRequires: pkgconfig(libpng)
-BuildRequires: pkgconfig(libusb-1.0)
-BuildRequires: pkgconfig(speex)
-BuildRequires: pkgconfig(flac)
BuildRequires: pkgconfig(minizip)
-BuildRequires: pkgconfig(xrandr)
+BuildRequires: pkgconfig(nspr)
+BuildRequires: pkgconfig(openssl)
+BuildRequires: pkgconfig(pangocairo)
+BuildRequires: pkgconfig(scim)
+BuildRequires: pkgconfig(speex)
+BuildRequires: pkgconfig(sqlite3)
+BuildRequires: pkgconfig(tts)
+BuildRequires: pkgconfig(ui-gadget-1)
+BuildRequires: pkgconfig(vconf)
+BuildRequires: pkgconfig(zlib)
+
+%if "%{?_with_wayland}" == "1"
+BuildRequires: pkgconfig(ecore-wayland)
+BuildRequires: pkgconfig(wayland-client)
+BuildRequires: pkgconfig(wayland-cursor)
+# gles20 provides wayland-egl.pc
+BuildRequires: pkgconfig(wayland-egl)
+%else
+BuildRequires: pkgconfig(ecore-x)
+BuildRequires: pkgconfig(libdri2)
+BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(xcomposite)
+BuildRequires: pkgconfig(xcursor)
BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(xi)
+BuildRequires: pkgconfig(xrandr)
BuildRequires: pkgconfig(xt)
BuildRequires: pkgconfig(xfixes)
BuildRequires: pkgconfig(xtst)
-BuildRequires: pkgconfig(xdamage)
-BuildRequires: pkgconfig(xcursor)
-BuildRequires: pkgconfig(libdrm)
-BuildRequires: pkgconfig(ecore)
-BuildRequires: pkgconfig(evas)
-BuildRequires: pkgconfig(ecore-x)
-BuildRequires: pkgconfig(ecore-evas)
-BuildRequires: pkgconfig(ecore-input)
-BuildRequires: pkgconfig(ecore-imf-evas)
-BuildRequires: pkgconfig(elementary)
-BuildRequires: pkgconfig(ui-gadget-1)
-BuildRequires: pkgconfig(libexif)
-BuildRequires: pkgconfig(nspr)
-BuildRequires: pkgconfig(zlib)
-BuildRequires: pkgconfig(capi-media-camera)
-BuildRequires: pkgconfig(capi-media-audio-io)
-BuildRequires: pkgconfig(capi-media-player)
-BuildRequires: pkgconfig(vconf)
-BuildRequires: pkgconfig(libdri2)
-BuildRequires: pkgconfig(libtbm)
-BuildRequires: pkgconfig(x11)
-BuildRequires: pkgconfig(feedback)
-BuildRequires: pkgconfig(appcore-efl)
-BuildRequires: pkgconfig(dlog)
-BuildRequires: pkgconfig(ecore-imf)
-BuildRequires: pkgconfig(scim)
-# for Mobile
-%if %{!?chromium_efl_tizen_profile:0}%{?chromium_efl_tizen_profile} == "mobile"
+%endif
+
+# Version Conditions for Each Targets
+%if "%{?chromium_efl_tizen_profile}%{!?chromium_efl_tizen_profile:0}" == "mobile"
BuildRequires: bzip2-devel
BuildRequires: pkgconfig(efl-assist)
BuildRequires: pkgconfig(capi-network-connection)
BuildRequires: pkgconfig(capi-system-sensor)
+%if "%{?_with_wayland}" != "1"
+BuildRequires: pkgconfig(xdamage)
+%endif
%if "%{?chromium_efl_tizen_version}%{!?chromium_efl_tizen_version:0}" == "2.4"
BuildRequires: pkgconfig(ttrace)
%endif
BuildRequires: pkgconfig(audio-session-mgr)
BuildRequires: pkgconfig(mm-session)
%endif
-# for Tizen v3.0 and Tizen v2.4
+
+# Version Conditions for Every Targets
%if "%{?chromium_efl_tizen_version}%{!?chromium_efl_tizen_version:0}" >= "2.4"
BuildRequires: binutils-gold
BuildRequires: pkgconfig(gstreamer-1.0)
%if 0%{?chromium_efl_tizen_version:1}
-Dchromium_efl_tizen_version=%{chromium_efl_tizen_version} \
%endif
+%if "%{?_with_wayland}" == "1"
+ -Duse_wayland=1 \
+%endif
+%if "%{?_repository}" == "emulator" || "%{?_repository}" == "emulator32-x11"
+ -Dtizen_emulator_support=1 \
+%endif
%if 0%{?build_xwalk}
--xwalk \
%endif
%ifarch %{arm}
tizen_src/build/prebuild/ninja.arm %{_smp_mflags} -C"%{OUTPUT_FOLDER}" \
%else
+%ifarch aarch64
+tizen_src/build/prebuild/ninja-linux64 %{_smp_mflags} -C"%{OUTPUT_FOLDER}" \
+%else
tizen_src/build/prebuild/ninja %{_smp_mflags} -C"%{OUTPUT_FOLDER}" \
%endif
+%endif
%if 0%{?_enable_content_shell}
content_shell \
%endif
'include_dirs': [
'.',
+ '<(DEPTH)/tizen_src/ecore_wrapper',
# Mobile gcc 4.6.x hack begin
'<(DEPTH)/tizen_src/gcc46_compat_wrappers',
# Mobile gcc 4.6.x hack end
'WTF_OS_TIZEN=1',
],
'conditions': [
+ ['chromium_efl_tizen_version=="3.0"', {
+ 'defines': [
+ 'TIZEN_V_3_0=1',
+ ],
+ }],
['chromium_efl_tizen_version=="2.4"', {
'defines': [
'TIZEN_V_2_4=1',
'TIZEN_LEGACY_V_2_2_1=1',
],
}],
- ['chromium_efl_tizen_version=="3.0"', {
+ ['use_wayland==1', {
'defines': [
- 'TIZEN_V_3_0=1',
+ 'USE_WAYLAND=1',
+ ],
+ }],
+ # TODO: There are X11 dependencies in following condition.
+ # The files need to be implemented based on Wayland.
+ ['wayland_bringup==1', {
+ 'defines': [
+ 'WAYLAND_BRINGUP=1',
+ ],
+ 'target_conditions': [
+ ['_target_name=="content_common"', {
+ 'sources/': [
+ ['exclude', 'content/common/gpu/client/gpu_memory_buffer_impl_efl_pixmap\\.(h|cc)$'],
+ ['exclude', 'content/common/gpu/gpu_memory_buffer_factory_efl_pixmap\\.(h|cc)$'],
+ ],
+ }],
+ ['_target_name=="gl"', {
+ 'sources/': [
+ ['exclude', 'ui/gl/efl_pixmap\\.(h|cc)$'],
+ ],
+ }],
+ ['_target_name=="x11_events_platform"', {
+ 'sources/': [
+ ['exclude', 'gfx/x11_event_source_efl\\.(h|cc)$'],
+ ],
+ }],
+ ['_target_name=="gfx_x11"', {
+ 'sources/': [
+ ['exclude', 'gfx/x11_types_override\\.cc$'],
+ ],
+ }],
+ ['_target_name=="ui_base"', {
+ 'sources/': [
+ ['exclude', 'ui/base/cursor/cursor_loader_x11\\.(h|cc)$'],
+ ['exclude', 'ui/base/cursor/cursor_x11\\.(h|cc)$'],
+ ],
+ }],
],
}],
],