From 2fa7c9f86b0684a361e14edf7acd46db6ba30698 Mon Sep 17 00:00:00 2001 From: Seunghun Lee Date: Mon, 21 Dec 2015 19:41:29 +0900 Subject: [PATCH] rotation: Move backend dependency code to common header. Change-Id: Iaab631248d4ed1a95c276b481f4a9eb08839999e --- src/e_mod_rotation.c | 6 ------ src/e_mod_rotation.h | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/src/e_mod_rotation.c b/src/e_mod_rotation.c index 051c7b8..c3f3a4b 100644 --- a/src/e_mod_rotation.c +++ b/src/e_mod_rotation.c @@ -20,10 +20,6 @@ #include "e_mod_rotation.h" #include "e_mod_utils.h" -#ifdef HAVE_WAYLAND_ONLY -#include "e_mod_rotation_wl.h" -#endif - static Eina_List *_event_handlers = NULL; /* externally accessible functions */ @@ -75,7 +71,6 @@ _e_mod_pol_rotation_cb_info_rotation_message(void *data EINA_UNUSED, int ev_type if (EINA_UNLIKELY((ev == NULL) || (ev->zone == NULL))) goto end; -#ifdef HAVE_WAYLAND_ONLY switch (ev->message) { case E_INFO_ROTATION_MESSAGE_SET: @@ -89,7 +84,6 @@ _e_mod_pol_rotation_cb_info_rotation_message(void *data EINA_UNUSED, int ev_type default: ERR("Unknown message"); } -#endif end: return ECORE_CALLBACK_RENEW; diff --git a/src/e_mod_rotation.h b/src/e_mod_rotation.h index 7a94e47..f8da00a 100644 --- a/src/e_mod_rotation.h +++ b/src/e_mod_rotation.h @@ -2,6 +2,22 @@ #define E_MOD_ROTATION_H #include +#ifdef HAVE_WAYLAND_ONLY +#include "e_mod_rotation_wl.h" +#else /* HAVE_WAYLAND_ONLY */ +static inline void +e_zone_rotation_set(E_Zone *zone EINA_UNUSED, int rot EINA_UNUSED) +{ + return; +} + +static inline Eina_Bool +e_zone_rotation_block_set(E_Zone *zone EINA_UNUSED, const char *name_hint EINA_UNUSED, Eina_Bool set EINA_UNUSED) +{ + return EINA_FALSE; +} +#endif /* HAVE_WAYLAND_ONLY */ + EINTERN int e_client_rotation_curr_angle_get(const E_Client *ec); EINTERN void e_mod_pol_rotation_init(void); EINTERN void e_mod_pol_rotation_shutdown(void); -- 2.34.1