static void _eom_output_process_notify_cb(void *data, GArray *array);
static eom_output_info *_eom_find_output_info(eom_output_id output_id);
static eom_output_info *_eom_alloc_output_info(int output_id, int output_type);
+/*LCOV_EXCL_START*/
static const char*
TYPE(eom_output_type_e output_type)
{
return "UNKNOWN";
}
}
-
+/*LCOV_EXCL_STOP*/
static void
_eom_get_debug_evn(void)
{
char *env = getenv("EOM_DEBUG");
if (env) {
- eom_debug_on = (atoi(env) > 0) ? true : false;
+ eom_debug_on = (atoi(env) > 0) ? true : false;/*LCOV_EXCL_LINE*/
#ifdef HAVE_DLOG
- fprintf(stderr, "eom dlog on\n");
+ fprintf(stderr, "eom dlog on\n");/*LCOV_EXCL_LINE*/
#else
- fprintf(stderr, "eom dlog off\n");
+ fprintf(stderr, "eom dlog off\n");/*LCOV_EXCL_LINE*/
#endif
- INFO("EOM_DEBUG = %s", env);
+ INFO("EOM_DEBUG = %s", env);/*LCOV_EXCL_LINE*/
} else
eom_debug_on = 0;
}
return true;
if (pthread_mutex_init(&eom_lock, NULL)) {
- fprintf(stderr, "fail: eom mutex init");
- return false;
+ fprintf(stderr, "fail: eom mutex init");/*LCOV_EXCL_LINE*/
+ return false;/*LCOV_EXCL_LINE*/
}
init = true;
{
pthread_mutex_unlock(&eom_lock);
}
-
+/*LCOV_EXCL_START*/
static void
_eom_set_output_info_mode(eom_output_info *output_info,
int output_mode)
output_info->output_mode = output_mode;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_set_output_attribute(eom_output_info *output_info,
eom_output_attribute_e attribute)
output_info->attribute = attribute;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_set_output_attribute_state(eom_output_info *output_info,
eom_output_attribute_state_e state)
output_info->state = state;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_set_output_info_size(eom_output_info *output_info,
int w, int h)
output_info->width = w;
output_info->height = h;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_set_output_info_phy_size(eom_output_info *output_info,
int w_mm, int h_mm)
output_info->mm_width = w_mm;
output_info->mm_height = h_mm;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_reset_output_info(eom_output_info *output_info)
{
output_info->mm_width = 0;
output_info->mm_height = 0;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_output_call_notify_cb(eom_output_notify_s *notify)
{
}
}
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_output_process_notify_cb(void *data, GArray *array)
{
exit:
_eom_mutex_unlock();
}
-
-
+/*LCOV_EXCL_STOP*/
static eom_output_info*
_eom_find_output_info(eom_output_id output_id)
{
GList *l;
for (l = output_info_list; l; l = g_list_next(l)) {
+/*LCOV_EXCL_START*/
eom_output_info *output_info = (eom_output_info *)l->data;
if (output_info && (output_id == output_info->id))
return output_info;
+/*LCOV_EXCL_STOP*/
}
return NULL;
}
-
+/*LCOV_EXCL_START*/
static void
_eom_free_output_info(eom_output_info **output_info)
{
*output_info = NULL;
}
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static eom_output_info*
_eom_alloc_output_info(int output_id, int output_type)
{
return NULL;
}
-
+/*LCOV_EXCL_STOP*/
API int
eom_init(void)
{
/* TODO: redesign the life-cycle of output_infos */
/* destory output_info. */
for (l = output_info_list; l; l = output_info_list) {
+/*LCOV_EXCL_START*/
eom_output_info *output_info = (eom_output_info *)l->data;
output_info_list = g_list_remove(output_info_list, output_info);
_eom_free_output_info(&output_info);
+/*LCOV_EXCL_STOP*/
}
_eom_mutex_unlock();
set_last_result(EOM_ERROR_NONE);
return NULL;
}
-
+/*LCOV_EXCL_START*/
if (ret_array->len == 0) {
g_array_free(ret_array, FALSE);
*count = 0;
set_last_result(EOM_ERROR_OUT_OF_MEMORY);
return NULL;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NONE;
-
+/*LCOV_EXCL_START*/
fail:
_eom_mutex_unlock();
return EOM_ERROR_OUT_OF_MEMORY;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NONE;
-
+/*LCOV_EXCL_START*/
fail:
_eom_mutex_unlock();
return EOM_ERROR_OUT_OF_MEMORY;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NONE;
-
+/*LCOV_EXCL_START*/
fail:
_eom_mutex_unlock();
return EOM_ERROR_OUT_OF_MEMORY;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NONE;
-
+/*LCOV_EXCL_START*/
fail:
_eom_mutex_unlock();
return EOM_ERROR_OUT_OF_MEMORY;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NO_SUCH_DEVICE;
}
-
+/*LCOV_EXCL_START*/
INFO("output_id: %d, attr: %d\n", output_id, attr);
#ifdef HAVE_WAYLAND
_eom_mutex_unlock();
return (ret) ? EOM_ERROR_NONE : EOM_ERROR_MESSAGE_OPERATION_FAILURE;
+/*LCOV_EXCL_STOP*/
}
set_last_result(EOM_ERROR_NO_SUCH_DEVICE);
return EOM_ERROR_NO_SUCH_DEVICE;
}
+/*LCOV_EXCL_START*/
*type = output_info->type;
_eom_mutex_unlock();
set_last_result(EOM_ERROR_NONE);
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
set_last_result(EOM_ERROR_NO_SUCH_DEVICE);
return EOM_ERROR_NO_SUCH_DEVICE;
}
+/*LCOV_EXCL_START*/
*mode = output_info->output_mode;
_eom_mutex_unlock();
set_last_result(EOM_ERROR_NONE);
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
set_last_result(EOM_ERROR_NO_SUCH_DEVICE);
return EOM_ERROR_NO_SUCH_DEVICE;
}
+/*LCOV_EXCL_START*/
*attribute = output_info->attribute;
_eom_mutex_unlock();
set_last_result(EOM_ERROR_NONE);
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
set_last_result(EOM_ERROR_NO_SUCH_DEVICE);
return EOM_ERROR_NO_SUCH_DEVICE;
}
+/*LCOV_EXCL_START*/
*state = output_info->state;
_eom_mutex_unlock();
set_last_result(EOM_ERROR_NONE);
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NO_SUCH_DEVICE;
}
-
+/*LCOV_EXCL_START*/
if (width)
*width = output_info->width;
if (height)
_eom_mutex_unlock();
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
set_last_result(EOM_ERROR_NO_SUCH_DEVICE);
return EOM_ERROR_NO_SUCH_DEVICE;
}
-
+/*LCOV_EXCL_START*/
if (phy_width)
*phy_width = output_info->mm_width;
if (phy_height)
_eom_mutex_unlock();
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
API int
_eom_mutex_unlock();
return EOM_ERROR_NO_SUCH_DEVICE;
}
-
+/*LCOV_EXCL_START*/
INFO("output_id: %d, evas_win: %p\n", output_id, win);
#ifdef HAVE_WAYLAND
_eom_mutex_unlock();
return EOM_ERROR_NONE;
+/*LCOV_EXCL_STOP*/
}
static EomWaylandClientInfo wl_client_info;
static int eom_wayland_init;
-
+/*LCOV_EXCL_START*/
static eom_output_type_e
_convert_to_eom_output_type(enum wl_eom_type eom_type)
{
return output_type;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static eom_output_mode_e
_convert_to_eom_output_mode(enum wl_eom_mode eom_mode)
{
return output_mode;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static eom_output_attribute_e
_convert_to_eom_output_attribute(enum wl_eom_attribute eom_attribute)
{
return output_attribute;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static eom_output_attribute_state_e
_convert_to_eom_output_attribute_state(
enum wl_eom_attribute_state eom_attribute_state)
return output_attribute_state;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static enum wl_eom_attribute
_convert_to_wl_eom_attribute(eom_output_attribute_e attr)
{
return eom_attribute;
}
-
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_wayland_client_call_notify(EomWaylandOutput *eom_wl_output,
eom_output_notify_type_e type)
if (array)
g_array_free(array, FALSE);
}
-
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static EomWaylandOutput *
_eom_wayland_client_find_output_from_wl_output(
struct wl_list *eom_wl_output_list, int output_id)
return ret;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static EomWaylandOutput *
_eom_wayland_client_find_output_from_eom_output(
struct wl_list *eom_wl_output_list, eom_output_id id)
return ret;
}
-
-
+/*LCOV_EXCL_STOP*/
+#if 0
static void
_eom_wl_output_handle_geometry(void *data,
struct wl_output *wl_output,
}
-
static void
_eom_wl_output_handle_mode(void *data,
struct wl_output *wl_output,
_eom_wl_output_handle_done,
_eom_wl_output_handle_scale,
};
-
+#endif
+/*LCOV_EXCL_START*/
static void
_eom_wl_eom_output_count(void *data,
struct wl_eom *wl_eom,
eom_client_info->num_outputs = count;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_wl_eom_output_info(void *data,
struct wl_eom *wl_eom,
wl_list_insert(&eom_client_info->eom_wl_output_list, &eom_wl_output->link);
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_wl_eom_output_type(void *data,
struct wl_eom *wl_eom,
EOM_OUTPUT_NOTIFY_REMOVE);
}
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_wl_eom_output_mode(void *data,
struct wl_eom *wl_eom,
EOM_OUTPUT_NOTIFY_MODE_CHANGED);
}
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static void
_eom_wl_eom_output_attribute(void *data,
struct wl_eom *wl_eom,
EOM_OUTPUT_NOTIFY_ATTRIBUTE_CHANGED);
}
}
-
-
+/*LCOV_EXCL_STOP*/
static const struct wl_eom_listener eom_wl_eom_listener = {
_eom_wl_eom_output_count,
_eom_wl_eom_output_info,
output = wl_registry_bind(registry, name,
&wl_output_interface, 1);
if (!output)
- ERR("Error. fail to bind %s.\n", interface);
+ ERR("Error. fail to bind %s.\n", interface);/*LCOV_EXCL_LINE*/
else {
INFO("bind %s.\n", interface);
#if 0
} else if (strcmp(interface, "wl_eom") == 0) {
eom = wl_registry_bind(registry, name, &wl_eom_interface, 1);
if (!eom)
- ERR("Error. fail to bind %s.\n", interface);
+ ERR("Error. fail to bind %s.\n", interface);/*LCOV_EXCL_LINE*/
else {
- INFO("bind %s.\n", interface);
+ INFO("bind %s.\n", interface);/*LCOV_EXCL_LINE*/
ci->eom = eom;
} else
INFO("Not bind %s.\n", interface);
}
-
+/*LCOV_EXCL_START*/
static void
_eom_wl_registry_handle_global_remove(void *data,
struct wl_registry *registry, uint32_t name)
{
}
-
+/*LCOV_EXCL_STOP*/
static const struct wl_registry_listener eom_registry_listener = {
_eom_wl_registry_handle_global,
_eom_wl_registry_handle_global_remove
return true;
fail:
- return false;
+ return false;/*LCOV_EXCL_LINE*/
}
static void
ERR("error. no outputs.\n");
return NULL;
}
-
+/*LCOV_EXCL_START*/
array = g_array_new(FALSE, FALSE, sizeof(GValue));
wl_list_for_each_safe(eom_wl_output, tmp,
/* returned array will be freed by caller */
return array;
+/*LCOV_EXCL_STOP*/
}
-
+/*LCOV_EXCL_START*/
GArray *
eom_wayland_client_get_output_info(eom_output_id output_id)
{
/* returned array will be freed by caller */
return array;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
GArray *
eom_wayland_client_set_attribute(eom_output_id output_id,
eom_output_attribute_e attr)
return NULL;
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
GArray *
eom_wayland_client_set_window(eom_output_id output_id, Evas_Object *win)
{
e_wl_win = elm_win_wl_window_get(win);
GOTO_IF_FAIL(e_wl_win != NULL, fail);
- eom_wl_output = _eom_wayland_client_find_output_from_eom_output(
+ eom_wl_output = _eom_wayland_client_find_output_from_eom_output(
&wl_client_info.eom_wl_output_list, output_id);
GOTO_IF_FAIL(eom_wl_output != NULL, fail);
return NULL;
}
+/*LCOV_EXCL_STOP*/
uint32_t attribute_state,
uint32_t error);
};
-
+/*LCOV_EXCL_START*/
static inline int
wl_eom_add_listener(struct wl_eom *wl_eom,
const struct wl_eom_listener *listener, void *data)
return wl_proxy_add_listener((struct wl_proxy *) wl_eom,
(void (**)(void)) listener, data);
}
-
+/*LCOV_EXCL_STOP*/
#define WL_EOM_SET_ATTRIBUTE 0
#define WL_EOM_SET_XDG_WINDOW 1
#define WL_EOM_SET_SHELL_WINDOW 2
{
wl_proxy_destroy((struct wl_proxy *) wl_eom);
}
-
+/*LCOV_EXCL_START*/
static inline void
wl_eom_set_attribute(struct wl_eom *wl_eom, uint32_t output_id, uint32_t attribute)
{
wl_proxy_marshal((struct wl_proxy *) wl_eom,
WL_EOM_SET_ATTRIBUTE, output_id, attribute);
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static inline void
wl_eom_set_xdg_window(struct wl_eom *wl_eom, uint32_t output_id, struct xdg_surface *surface)
{
wl_proxy_marshal((struct wl_proxy *) wl_eom,
WL_EOM_SET_XDG_WINDOW, output_id, surface);
}
-
+/*LCOV_EXCL_STOP*/
+/*LCOV_EXCL_START*/
static inline void
wl_eom_set_shell_window(struct wl_eom *wl_eom, uint32_t output_id, struct wl_shell_surface *surface)
{
wl_proxy_marshal((struct wl_proxy *) wl_eom,
WL_EOM_SET_SHELL_WINDOW, output_id, surface);
}
-
+/*LCOV_EXCL_STOP*/
static inline void
wl_eom_get_output_info(struct wl_eom *wl_eom, uint32_t output_id)
{
<entry name="dsi" value="16" summary="VGA output connector type"/>
</enum>
- <enum name="status">
+ <enum name="status">
<description summary="connection status of the external output">
***** TODO ******
</description>
<entry name="disconnection" value="2" summary="output disconnected"/>
</enum>
- <enum name="mode">
+ <enum name="mode">
<description summary="mode of the external output">
***** TODO ******
</description>
<entry name="presentation" value="2" summary="presentation mode"/>
</enum>
- <enum name="attribute">
+ <enum name="attribute">
<description summary="attribute of the external output">
***** TODO ******
</description>
<entry name="exclusive" value="3" summary="exclusive attribute"/>
</enum>
- <enum name="attribute_state">
+ <enum name="attribute_state">
<description summary="state of the external output attribute">
***** TODO ******
</description>