#define EOM_NUM_ATTR 3
#define EOM_CONNECT_CHECK_TIMEOUT 4.0
-#define EOERR(f, output, x...) \
+#define EOMERR(f, output, x...) \
do \
{ \
if (!output) \
- ERR("EWL|%20.20s| | |%8s|"f, \
+ ERR("EWL|%20.20s| | |%7s|"f, \
"EOM", "Unknown", ##x); \
else \
- ERR("EWL|%20.20s| | |%8s|"f, \
+ ERR("EWL|%20.20s| | |%7s|"f, \
"EOM", (e_output_output_id_get(output)), ##x); \
} \
while (0)
-#define EOINF(f, output, x...) \
+#define EOMINF(f, ec, output, x...) \
do \
{ \
- if (!output) \
- INF("EWL|%20.20s| | |%8s|"f, \
- "EOM", "Unknown", ##x); \
+ if (!ec) \
+ INF("EWL|%20.20s| | |%7s|"f, \
+ "EOM", (e_output_output_id_get(output)), ##x); \
else \
- INF("EWL|%20.20s| | |%8s|"f, \
- "EOM", (e_output_output_id_get(output)), ##x); \
+ INF("EWL|%20.20s|w:0x%08zx|ec:%8p|%7s|"f, \
+ "EOM", (e_client_util_win_get(ec)), \
+ (ec), (e_output_output_id_get(output)), ##x); \
} \
while (0)
E_EomCompObjectInterceptHookData *hook_data;
EINA_SAFETY_ON_NULL_RETURN_VAL(data, EINA_TRUE);
+ EINA_SAFETY_ON_NULL_RETURN_VAL(ec, EINA_TRUE);
hook_data = (E_EomCompObjectInterceptHookData* )data;
/* Hide the window from Enlightenment main screen */
e_client_redirected_set(ec, EINA_FALSE);
- EOINF("Redirect ec:%p, ec->frame:%p", hook_data->eom_output->output, ec, ec->frame);
+ EOMINF("Redirect ec->frame:%p", ec, hook_data->eom_output->output, ec->frame);
e_comp_object_intercept_hook_del(hook_data->hook);
g_eom->comp_object_intercept_hooks = eina_list_remove(g_eom->comp_object_intercept_hooks, hook_data);
if (!eom_client->resource) continue;
if (attribute_state == EOM_OUTPUT_ATTRIBUTE_STATE_ACTIVE)
- EOINF("Send output connected notification to client: %p", eom_output->output, eom_client);
+ EOMINF("Send output connected notification", eom_client->ec, eom_output->output);
if (attribute_state == EOM_OUTPUT_ATTRIBUTE_STATE_INACTIVE)
- EOINF("Send output disconnected notification to client: %p", eom_output->output, eom_client);
+ EOMINF("Send output disconnected notification", eom_client->ec, eom_output->output);
if (eom_client->ec == e_output_presentation_ec_get(eom_output->output))
wl_eom_send_output_info(eom_client->resource,
g_eom->eom_outputs = eina_list_append(g_eom->eom_outputs, eom_output);
- EOINF("create (%d)output, type:%d, added:%d", eom_output->output,
+ EOMINF("create (%d)output, type:%d, added:%d", NULL, eom_output->output,
eom_output->id, eom_output->type, eom_output->added);
return EINA_TRUE;
eom_output = _e_eom_output_find(output);
EINA_SAFETY_ON_NULL_RETURN_VAL(eom_output, EINA_FALSE);
- EOINF("destroy (%d)output, type:%d, added:%d", eom_output->output,
+ EOMINF("destroy (%d)output, type:%d, added:%d", NULL, eom_output->output,
eom_output->id, eom_output->type, eom_output->added);
g_eom->eom_outputs = eina_list_remove(g_eom->eom_outputs, eom_output);
e_output_size_get(eom_output->output, &w, &h);
cdata->shell.configure_send(ec->comp_data->shell.surface, 0, w, h);
- EOINF("Send Configure Event for Presentation (%d X %d)", eom_output->output, w, h);
+ EOMINF("Send Configure Event for Presentation (%d X %d)", ec, eom_output->output, w, h);
+
+ return;
err:
if (hook_data)
free(hook_data);
EINA_SAFETY_ON_NULL_RETURN_VAL(eom_output, ECORE_CALLBACK_PASS_ON);
if (eom_trace_debug)
- EOINF("===============> EXT START", eom_output->output);
+ EOMINF("===============> EXT START", ec, eom_output->output);
/* TODO: It works but maybe there is better solution exists ?
* Also I do not know how it affects on performance */
if (ec->map_timer)
{
if (eom_trace_debug)
- EOINF("delete map_timer", eom_output->output);
+ EOMINF("delete map_timer", ec, eom_output->output);
E_FREE_FUNC(ec->map_timer, ecore_timer_del);
}
if (eom_trace_debug)
- EOINF("buffer_changed callback ec:%p", eom_output->output, ec);
+ EOMINF("buffer_changed callback", ec, eom_output->output);
/* set the ec to the output for presentation. */
if (!e_output_presentation_update(eom_output->output, eom_client->ec))
{
- EOERR("e_output_presentation_update fails.", eom_output->output);
+ EOMERR("e_output_presentation_update fails.", eom_output->output);
return ECORE_CALLBACK_PASS_ON;
}
}
if (eom_trace_debug)
- EOINF("===============< EXT START", eom_output->output);
+ EOMINF("===============< EXT START", ec, eom_output->output);
return ECORE_CALLBACK_PASS_ON;
}
eom_output = _e_eom_output_get_by_id(output_id);
EINA_SAFETY_ON_NULL_GOTO(eom_output, no_eom_output);
- EOINF("Set attribute:%d, client:%p", eom_output->output, attribute, eom_client);
+ EOMINF("Set attribute:%d", eom_client->ec, eom_output->output, attribute);
/* Bind the client with a concrete output */
eom_client->output_id = output_id;
/* A client is trying to set new attribute */
if (!_e_eom_output_attribute_set(eom_output, attribute))
{
- EOINF("client failed to set attribute", eom_output->output);
+ EOMINF("client failed to set attribute", eom_client->ec, eom_output->output);
wl_eom_send_output_attribute(eom_client->resource, eom_output->id,
_e_eom_output_attribute_get(eom_output),
EOM_OUTPUT_ATTRIBUTE_STATE_LOST,
return;
}
- EOINF("Send changes to previous current client", eom_output->output);
+ EOMINF("Send changes to previous current client(%p)", eom_client->ec, eom_output->output, eom_output->eom_client->ec);
/* eom_output->eom_client is lost the attribute */
wl_eom_send_output_attribute(eom_output->eom_client->resource, eom_output->id,
_e_eom_output_attribute_get(eom_output),
primary_output = e_comp_screen_primary_output_get(e_comp->e_comp_screen);
if (!e_output_mirror_set(eom_output->output, primary_output))
{
- EOERR("e_output_mirror_set fails", eom_output->output);
+ EOMERR("e_output_mirror_set fails", eom_output->output);
goto no_eom_output;
}
if (e_output_presentation_wait_set(eom_output->output, eom_client->ec))
{
- EOERR("e_output_presentation_wait_set fails\n", NULL);
+ EOMERR("e_output_presentation_wait_set fails\n", NULL);
return;
}
return;
}
- EOINF("set shell output id:%d resource:%p surface:%p", NULL, output_id, resource, surface);
-
eom_client = _e_eom_client_get_by_resource(resource);
EINA_SAFETY_ON_NULL_RETURN(eom_client);
if (eom_output == NULL)
{
wl_eom_send_output_set_window(resource, output_id, WL_EOM_ERROR_NO_OUTPUT);
- EOERR("no eom_output error\n", NULL);
+ EOMERR("no eom_output error\n", NULL);
return;
}
+ EOMINF("set shell output id:%d resource:%p surface:%p", ec, eom_output->output, output_id, resource, surface);
+
if (ec == e_output_presentation_ec_get(eom_output->output))
{
wl_eom_send_output_set_window(resource, output_id, WL_EOM_ERROR_OUTPUT_OCCUPIED);
_e_eom_cb_wl_request_get_output_info(struct wl_client *client, struct wl_resource *resource, uint32_t output_id)
{
E_EomOutputPtr eom_output = NULL;
+ E_EomClientPtr eom_client = NULL;
int w, h, pw, ph;
- EOINF("get output info:%d", NULL, output_id);
-
eom_output = _e_eom_output_get_by_id(output_id);
EINA_SAFETY_ON_FALSE_RETURN(eom_output);
+ eom_client = _e_eom_client_get_by_resource(resource);
+ EINA_SAFETY_ON_NULL_RETURN(eom_client);
+
/* get the output size */
e_output_size_get(eom_output->output, &w, &h);
e_output_phys_size_get(eom_output->output, &pw, &ph);
eom_output->connection,
1, 0, 0, 0);
- EOINF("send - id : %d, type : %d, mode : %d, w : %d, h : %d, w_mm : %d, h_mm : %d, conn : %d", NULL,
+ EOMINF("send - id : %d, type : %d, mode : %d, w : %d, h : %d, w_mm : %d, h_mm : %d, conn : %d",
+ eom_client->ec, eom_output->output,
eom_output->id, eom_output->type, e_output_display_mode_get(eom_output->output),
w, h, pw, ph, e_output_connected(eom_output->output));
}
E_Output *primary_output = NULL;
E_Client *output_ec = NULL;
- EOINF("=======================> CLIENT DESTROY", NULL);
-
EINA_SAFETY_ON_NULL_RETURN(resource);
eom_client = _e_eom_client_get_by_resource(resource);
eom_output = _e_eom_output_get_by_id(eom_client->output_id);
EINA_SAFETY_ON_NULL_GOTO(eom_output, end);
+ EOMINF("=======================> CLIENT DESTROY", eom_client->ec, eom_output->output);
+
if (eom_client == eom_output->eom_client)
eom_output->eom_client = NULL;
primary_output = e_comp_screen_primary_output_get(e_comp->e_comp_screen);
if (!e_output_mirror_set(eom_output->output, primary_output))
- EOERR("e_output_mirror_set fails", eom_output->output);
+ EOMERR("e_output_mirror_set fails", eom_output->output);
}
end:
resource = wl_resource_create(client, &wl_eom_interface, MIN(version, 1), id);
if (resource == NULL)
{
- EOERR("resource is null. (version :%d, id:%d)", NULL, version, id);
+ EOMERR("resource is null. (version :%d, id:%d)", NULL, version, id);
wl_client_post_no_memory(client);
return;
}
eom_output->connection,
1, 0, 0, 0);
- EOINF("send - id : %d, type : %d, mode : %d, w : %d, h : %d, w_mm : %d, h_mm : %d, conn : %d", eom_output->output,
+ EOMINF("BIND send - id : %d, type : %d, mode : %d, w : %d, h : %d, w_mm : %d, h_mm : %d, conn : %d",
+ NULL, eom_output->output,
eom_output->id, eom_output->type, e_output_display_mode_get(eom_output->output),
w, h, pw, ph, e_output_connected(eom_output->output));
}
g_eom->clients = eina_list_append(g_eom->clients, eom_client);
- EOINF("=======================> BIND CLIENT", NULL);
+ EOMINF("=======================> BIND CLIENT", NULL, NULL);
}
static Eina_Bool
eom_output = _e_eom_output_find(output);
if (!eom_output)
{
- EOERR("cannot find eom_output", NULL);
+ EOMERR("cannot find eom_output", NULL);
return EINA_FALSE;
}
if (e_output_display_mode_get(eom_output->output) == E_OUTPUT_DISPLAY_MODE_WAIT_PRESENTATION)
{
- EOINF("Send Configure Event for Presentation", eom_output->output);
+ EOMINF("Send Configure Event for Presentation", NULL, eom_output->output);
ec = e_output_presentation_ec_get(eom_output->output);
EINA_SAFETY_ON_NULL_RETURN_VAL(ec, EINA_FALSE);
/* get the output size */
e_output_size_get(eom_output->output, &w, &h);
- EOINF("Setup new eom_output: (%dx%d)", eom_output->output, w, h);
+ EOMINF("Setup new eom_output: (%dx%d)", NULL, eom_output->output, w, h);
return EINA_TRUE;
}
eom_output = _e_eom_output_find(output);
if (!eom_output)
{
- EOERR("cannot find output", NULL);
+ EOMERR("cannot find output", NULL);
return EINA_FALSE;
}
/* If there were previously connected clients to the output - notify them */
_e_eom_output_info_broadcast(eom_output, EOM_OUTPUT_ATTRIBUTE_STATE_INACTIVE);
- EOINF("Destory output.", eom_output->output);
+ EOMINF("Destory output.", NULL, eom_output->output);
return EINA_TRUE;
}
{
if (!_e_eom_output_create(output, EINA_TRUE))
{
- EOERR("_e_eom_output_create fails.", output);
+ EOMERR("_e_eom_output_create fails.", output);
return;
}
}
{
if (!_e_eom_output_destroy(output))
{
- EOERR("_e_eom_output_destroy fails.", output);
+ EOMERR("_e_eom_output_destroy fails.", output);
return;
}
}
EINA_SAFETY_ON_NULL_RETURN_VAL(primary_output, EINA_FALSE);
g_eom->eom_output_count = e_comp_screen->num_outputs - 1;
- EOINF("external output count : %d", NULL, g_eom->eom_output_count);
+ EOMINF("external output count : %d", NULL, NULL, g_eom->eom_output_count);
/* create the eom_output except for the primary output */
EINA_LIST_FOREACH(e_comp_screen->outputs, l, output)
if (!_e_eom_output_create(output, EINA_FALSE))
{
- EOERR("_e_eom_output_create fails.", output);
+ EOMERR("_e_eom_output_create fails.", output);
goto err;
}
}
if (!_e_eom_output_init())
{
- EOERR("_e_eom_output_init fail", NULL);
+ EOMERR("_e_eom_output_init fail", NULL);
goto err;
}