forked from enlightenment/efl
Ecore_Wayland: Add ecore_wl_pointer_xy_get function.
SVN revision: 68576
This commit is contained in:
parent
e3cb7f5f21
commit
6cbf9fa01a
|
@ -149,8 +149,8 @@ struct _Ecore_Wl_Window
|
||||||
Eina_Rectangle allocation, pending_allocation;
|
Eina_Rectangle allocation, pending_allocation;
|
||||||
Eina_Rectangle saved_allocation, server_allocation;
|
Eina_Rectangle saved_allocation, server_allocation;
|
||||||
|
|
||||||
Eina_Bool redraw_scheduled : 1;
|
/* Eina_Bool redraw_scheduled : 1; */
|
||||||
Eina_Bool resize_scheduled : 1;
|
/* Eina_Bool resize_scheduled : 1; */
|
||||||
Eina_Bool transparent : 1;
|
Eina_Bool transparent : 1;
|
||||||
|
|
||||||
Ecore_Wl_Window_Type type;
|
Ecore_Wl_Window_Type type;
|
||||||
|
@ -275,6 +275,7 @@ EAPI void ecore_wl_sync(void);
|
||||||
EAPI struct wl_shm *ecore_wl_shm_get(void);
|
EAPI struct wl_shm *ecore_wl_shm_get(void);
|
||||||
EAPI struct wl_display *ecore_wl_display_get(void);
|
EAPI struct wl_display *ecore_wl_display_get(void);
|
||||||
EAPI void ecore_wl_screen_size_get(int *w, int *h);
|
EAPI void ecore_wl_screen_size_get(int *w, int *h);
|
||||||
|
EAPI void ecore_wl_pointer_xy_get(Ecore_Wl_Window *win, int *x, int *y);
|
||||||
|
|
||||||
EAPI Ecore_Wl_Window *ecore_wl_window_new(Ecore_Wl_Window *parent, int x, int y, int w, int h, int buffer_type);
|
EAPI Ecore_Wl_Window *ecore_wl_window_new(Ecore_Wl_Window *parent, int x, int y, int w, int h, int buffer_type);
|
||||||
EAPI void ecore_wl_window_free(Ecore_Wl_Window *win);
|
EAPI void ecore_wl_window_free(Ecore_Wl_Window *win);
|
||||||
|
|
|
@ -309,6 +309,19 @@ ecore_wl_screen_size_get(int *w, int *h)
|
||||||
if (h) *h = _ecore_wl_disp->output->allocation.h;
|
if (h) *h = _ecore_wl_disp->output->allocation.h;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* @since 1.2 */
|
||||||
|
EAPI void
|
||||||
|
ecore_wl_pointer_xy_get(Ecore_Wl_Window *win, int *x, int *y)
|
||||||
|
{
|
||||||
|
LOGFN(__FILE__, __LINE__, __FUNCTION__);
|
||||||
|
|
||||||
|
if (x) *x = 0;
|
||||||
|
if (y) *y = 0;
|
||||||
|
if ((!win) || (!win->pointer_device)) return;
|
||||||
|
if (x) *x = win->pointer_device->sx;
|
||||||
|
if (y) *y = win->pointer_device->sy;
|
||||||
|
}
|
||||||
|
|
||||||
/* local functions */
|
/* local functions */
|
||||||
static Eina_Bool
|
static Eina_Bool
|
||||||
_ecore_wl_shutdown(Eina_Bool close)
|
_ecore_wl_shutdown(Eina_Bool close)
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
# include "Ecore_Wayland.h"
|
# include "Ecore_Wayland.h"
|
||||||
|
|
||||||
# define LOGFNS 1
|
//# define LOGFNS 1
|
||||||
|
|
||||||
# ifdef LOGFNS
|
# ifdef LOGFNS
|
||||||
# include <stdio.h>
|
# include <stdio.h>
|
||||||
|
|
Loading…
Reference in New Issue