From 6054f4568dc681f9c77ae793ecf411b1c45e7d7f Mon Sep 17 00:00:00 2001 From: JengHyun Kang Date: Tue, 7 Nov 2017 22:49:11 +0900 Subject: [PATCH] ecore_wl2: add ecore_wl2_window_input_get() EAPI @tizen_feature Change-Id: Ie24ced6b5d6e2a62fe5f8d8ae48043a2c122a14f --- src/lib/ecore_wl2/Ecore_Wl2.h | 3 +++ src/lib/ecore_wl2/ecore_wl2_window.c | 19 +++++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/lib/ecore_wl2/Ecore_Wl2.h b/src/lib/ecore_wl2/Ecore_Wl2.h index aaf4c93..62f867d 100644 --- a/src/lib/ecore_wl2/Ecore_Wl2.h +++ b/src/lib/ecore_wl2/Ecore_Wl2.h @@ -2197,6 +2197,9 @@ EAPI void ecore_wl2_window_surface_flush(Ecore_Wl2_Window *window); // TIZEN_ONLY(20171107): support a tizen_keyrouter interface EAPI void ecore_wl2_display_sync(Ecore_Wl2_Display *display); // +// TIZEN_ONLY(20171107): add ecore_wl2_window_input_get() EAPI +EAPI Ecore_Wl2_Input *ecore_wl2_window_input_get(Ecore_Wl2_Window *win); +// # endif diff --git a/src/lib/ecore_wl2/ecore_wl2_window.c b/src/lib/ecore_wl2/ecore_wl2_window.c index 7bacdc0..1fbe00a 100644 --- a/src/lib/ecore_wl2/ecore_wl2_window.c +++ b/src/lib/ecore_wl2/ecore_wl2_window.c @@ -1808,6 +1808,7 @@ ecore_wl2_window_buffer_attach(Ecore_Wl2_Window *win, void *buffer, int x, int y win->has_buffer = EINA_TRUE; } +<<<<<<< 0f309f06c19227cc6445aff8550ae8d885d2a48a EAPI Eina_Bool ecore_wl2_window_resizing_get(Ecore_Wl2_Window *window) { @@ -1856,3 +1857,21 @@ ecore_wl2_window_surface_flush(Ecore_Wl2_Window *window) if (!window->wl2_surface) return; ecore_wl2_surface_flush(window->wl2_surface); } + +// TIZEN_ONLY(20171107): add ecore_wl2_window_input_get() EAPI +EAPI Ecore_Wl2_Input * +ecore_wl2_window_input_get(Ecore_Wl2_Window *win) +{ + Ecore_Wl2_Input *input; + + EINA_SAFETY_ON_NULL_RETURN_VAL(win, NULL); + EINA_SAFETY_ON_NULL_RETURN_VAL(win->display, NULL); + + EINA_INLIST_FOREACH(win->display->inputs, input) + { + if (input->focus.pointer) return input; + } + + return NULL; +} +// -- 2.7.4