summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2018-01-30 14:46:23 -0600
committerDerek Foreman <derekf@osg.samsung.com>2018-01-30 17:09:51 -0600
commitcc0cfb782221684ed9e65614a07e0018031788c2 (patch)
treeb33ebe1d46ab2e06fe85cc6ae751ff9db40ea866
parentda9eef6027489fd0555e61860646fc9ca91f5695 (diff)
ecore_wl2: Add internal _ecore_wl2_output_find
This finds the Ecore_Wl2_Output * for a given struct wl_output *
-rw-r--r--src/lib/ecore_wl2/ecore_wl2_output.c11
-rw-r--r--src/lib/ecore_wl2/ecore_wl2_private.h2
2 files changed, 13 insertions, 0 deletions
diff --git a/src/lib/ecore_wl2/ecore_wl2_output.c b/src/lib/ecore_wl2/ecore_wl2_output.c
index ba1d7cea8f..0aa8791c12 100644
--- a/src/lib/ecore_wl2/ecore_wl2_output.c
+++ b/src/lib/ecore_wl2/ecore_wl2_output.c
@@ -117,6 +117,17 @@ _ecore_wl2_output_del(Ecore_Wl2_Output *output)
117 free(output); 117 free(output);
118} 118}
119 119
120Ecore_Wl2_Output *
121_ecore_wl2_output_find(Ecore_Wl2_Display *display, struct wl_output *op)
122{
123 Ecore_Wl2_Output *wl2op;
124
125 EINA_INLIST_FOREACH(display->outputs, wl2op)
126 if (wl2op->wl_output == op) return wl2op;
127
128 return NULL;
129}
130
120EAPI int 131EAPI int
121ecore_wl2_output_dpi_get(Ecore_Wl2_Output *output) 132ecore_wl2_output_dpi_get(Ecore_Wl2_Output *output)
122{ 133{
diff --git a/src/lib/ecore_wl2/ecore_wl2_private.h b/src/lib/ecore_wl2/ecore_wl2_private.h
index 05d264b993..ec7b767691 100644
--- a/src/lib/ecore_wl2/ecore_wl2_private.h
+++ b/src/lib/ecore_wl2/ecore_wl2_private.h
@@ -606,4 +606,6 @@ EAPI void ecore_wl2_window_weight_set(Ecore_Wl2_Window *window, double w, double
606EAPI extern int _ecore_wl2_event_window_www; 606EAPI extern int _ecore_wl2_event_window_www;
607EAPI extern int _ecore_wl2_event_window_www_drag; 607EAPI extern int _ecore_wl2_event_window_www_drag;
608 608
609Ecore_Wl2_Output *_ecore_wl2_output_find(Ecore_Wl2_Display *dsp, struct wl_output *op);
610
609#endif 611#endif