seoz pushed a commit to branch master.
commit 358d225d35826ec6d402096a1683b2d8bb0e0d67
Author: Daniel Juyung Seo <[email protected]>
Date: Wed Jun 5 14:40:03 2013 +0900
elm: refactoring. no printf in the library. use eina log instead.
---
src/lib/elm_access.c | 2 +-
src/lib/elm_config.c | 8 ++++----
src/lib/elm_factory.c | 10 +++++-----
src/lib/elm_image.c | 4 ++--
src/lib/elm_index.c | 2 +-
src/lib/elm_main.c | 26 +++++++++++++-------------
src/lib/elm_widget.c | 8 ++++----
src/lib/elm_win.c | 2 +-
8 files changed, 31 insertions(+), 31 deletions(-)
diff --git a/src/lib/elm_access.c b/src/lib/elm_access.c
index c5497b1..7d1c39e 100644
--- a/src/lib/elm_access.c
+++ b/src/lib/elm_access.c
@@ -328,7 +328,7 @@ _access_obj_del_cb(void *data, Evas *e __UNUSED__,
Evas_Object *obj, void *event
static void
_access_read_done(void *data __UNUSED__)
{
- printf("read done\n");
+ DBG("read done");
// FIXME: produce event here
}
diff --git a/src/lib/elm_config.c b/src/lib/elm_config.c
index 73e01c2..c356b12 100644
--- a/src/lib/elm_config.c
+++ b/src/lib/elm_config.c
@@ -273,7 +273,7 @@ _desc_init(void)
_config_edd = eet_data_descriptor_file_new(&eddc);
if (!_config_edd)
{
- printf("EEEK! eet_data_descriptor_file_new() failed\n");
+ ERR("EEEK! eet_data_descriptor_file_new() failed.");
return;
}
@@ -285,7 +285,7 @@ _desc_init(void)
_config_font_overlay_edd = eet_data_descriptor_stream_new(&eddc);
if (!_config_font_overlay_edd)
{
- printf("EEEK! eet_data_descriptor_stream_new() failed\n");
+ ERR("EEEK! eet_data_descriptor_stream_new() failed.");
eet_data_descriptor_free(_config_edd);
return;
}
@@ -298,7 +298,7 @@ _desc_init(void)
_config_color_edd = eet_data_descriptor_stream_new(&eddc);
if (!_config_color_edd)
{
- printf("EEEK! eet_data_descriptor_stream_new() failed\n");
+ ERR("EEEK! eet_data_descriptor_stream_new() failed.");
eet_data_descriptor_free(_config_edd);
return;
}
@@ -311,7 +311,7 @@ _desc_init(void)
_config_color_palette_edd = eet_data_descriptor_stream_new(&eddc);
if (!_config_color_palette_edd)
{
- printf("EEEK! eet_data_descriptor_stream_new() failed\n");
+ ERR("EEEK! eet_data_descriptor_stream_new() failed.");
eet_data_descriptor_free(_config_edd);
return;
}
diff --git a/src/lib/elm_factory.c b/src/lib/elm_factory.c
index 88478b6..14ef56b 100644
--- a/src/lib/elm_factory.c
+++ b/src/lib/elm_factory.c
@@ -63,7 +63,7 @@ _del_hook(Evas_Object *obj)
wd->content = NULL;
evas_object_del(o);
fac--;
-// printf("FAC-- = %i\n", fac);
+// DBG("FAC-- = %i", fac);
}
free(wd);
}
@@ -100,7 +100,7 @@ _sizing_eval(Evas_Object *obj)
evas_object_size_hint_min_set(obj, minw, minh);
}
evas_object_size_hint_max_set(obj, maxw, maxh);
-// printf("FAC SZ: %i %i | %i %i\n", minw, minh, maxw, maxh);
+// DBG("FAC SZ: %i %i | %i %i", minw, minh, maxw, maxh);
}
static void
@@ -129,7 +129,7 @@ _eval(Evas_Object *obj)
{
if (!wd->content)
{
-// printf(" + %i %i %ix%i <> %i %i %ix%i\n", x, y,
w, h, cvx, cvy, cvw, cvh);
+// DBG(" + %i %i %ix%i <> %i %i %ix%i", x, y, w,
h, cvx, cvy, cvw, cvh);
evas_object_smart_callback_call(obj, SIG_REALIZE, NULL);
if (wd->content)
{
@@ -213,7 +213,7 @@ _child_del(void *data, Evas *e __UNUSED__, Evas_Object
*obj, void *event_info __
_child_del, obj);
wd->content = NULL;
fac--;
-// printf("FAC-- = %i\n", fac);
+// DBG("FAC-- = %i", fac);
}
static Evas_Object *
@@ -236,7 +236,7 @@ _content_unset_hook(Evas_Object *obj, const char *part)
_child_del, obj);
wd->content = NULL;
fac--;
-// printf("FAC-- = %i\n", fac);
+// DBG("FAC-- = %i", fac);
return content;
}
diff --git a/src/lib/elm_image.c b/src/lib/elm_image.c
index 7b09da9..9a903eb 100644
--- a/src/lib/elm_image.c
+++ b/src/lib/elm_image.c
@@ -612,7 +612,7 @@ _elm_image_drag_n_drop_cb(void *elm_obj,
eo_do(obj, elm_obj_image_file_set(drop->data, NULL, &ret));
if(ret)
{
- printf("dnd: %s, %s, %s", elm_widget_type_get(elm_obj),
+ DBG("dnd: %s, %s, %s", elm_widget_type_get(elm_obj),
SIG_DND, (char *)drop->data);
evas_object_smart_callback_call(elm_obj, SIG_DND, drop->data);
@@ -1036,7 +1036,7 @@ _elm_image_smart_editable_set(Eo *obj, void *_pd, va_list
*list)
if (sd->edje)
{
- printf("No editing edje objects yet (ever)\n");
+ WRN("No editing edje objects yet (ever)\n");
return;
}
diff --git a/src/lib/elm_index.c b/src/lib/elm_index.c
index fb3efa2..97bd6fd 100644
--- a/src/lib/elm_index.c
+++ b/src/lib/elm_index.c
@@ -562,7 +562,7 @@ _sel_eval(Evas_Object *obj,
dist = 0x7fffffff;
dh = h / size;
if (dh == 0)
- printf("too many index items to omit\n"); //FIXME
+ WRN("too many index items to omit."); //FIXME
else
{
for (j = 0; j < size; j++)
diff --git a/src/lib/elm_main.c b/src/lib/elm_main.c
index add6f22..1d63c35 100644
--- a/src/lib/elm_main.c
+++ b/src/lib/elm_main.c
@@ -40,19 +40,19 @@ _elm_dangerous_call_check(const char *call)
eval = getenv("ELM_NO_FINGER_WAGGLING");
if ((eval) && (!strcmp(eval, buf)))
return 0;
- printf("ELEMENTARY FINGER WAGGLE!!!!!!!!!!\n"
- "\n"
- " %s() used.\n"
- "PLEASE see the API documentation for this function. This call\n"
- "should almost never be used. Only in very special cases.\n"
- "\n"
- "To remove this warning please set the environment variable:\n"
- " ELM_NO_FINGER_WAGGLING\n"
- "To the value of the Elementary version + revision number. e.g.:\n"
- " 1.2.5.40295\n"
- "\n"
- ,
- call);
+ ERR("ELEMENTARY FINGER WAGGLE!!!!!!!!!!\n"
+ "\n"
+ " %s() used.\n"
+ "PLEASE see the API documentation for this function. This call\n"
+ "should almost never be used. Only in very special cases.\n"
+ "\n"
+ "To remove this warning please set the environment variable:\n"
+ " ELM_NO_FINGER_WAGGLING\n"
+ "To the value of the Elementary version + revision number. e.g.:\n"
+ " 1.2.5.40295\n"
+ "\n"
+ ,
+ call);
return 1;
}
diff --git a/src/lib/elm_widget.c b/src/lib/elm_widget.c
index 85d9d68..bb618b0 100644
--- a/src/lib/elm_widget.c
+++ b/src/lib/elm_widget.c
@@ -5749,14 +5749,14 @@ _sub_obj_tree_dump(const Evas_Object *obj,
{
Eina_List *l;
INTERNAL_ENTRY;
- printf("+ %s(%p)\n",
- elm_widget_type_get(obj),
- obj);
+ DBG("+ %s(%p)\n",
+ elm_widget_type_get(obj),
+ obj);
EINA_LIST_FOREACH(sd->subobjs, l, obj)
_sub_obj_tree_dump(obj, lvl + 1);
}
else
- printf("+ %s(%p)\n", evas_object_type_get(obj), obj);
+ DBG("+ %s(%p)\n", evas_object_type_get(obj), obj);
}
static void
diff --git a/src/lib/elm_win.c b/src/lib/elm_win.c
index 02f44b1..3ec6ddd 100644
--- a/src/lib/elm_win.c
+++ b/src/lib/elm_win.c
@@ -2411,7 +2411,7 @@ _debug_key_down(void *data __UNUSED__,
(!evas_key_modifier_is_set(ev->modifiers, "Control")))
return;
- printf("Tree graph generated.\n");
+ INFO("Tree graph generated.\n");
elm_object_tree_dot_dump(obj, "./dump.dot");
}
--
------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j