Enlightenment CVS committal
Author : moom
Project : e17
Module : libs/edje
Dir : e17/libs/edje/src/lib
Modified Files:
Edje.h edje_util.c
Log Message:
* Add edje_object_part_object_get() to get the 'Evas_Object *'
corresponding to a given part.
===================================================================
RCS file: /cvs/e/e17/libs/edje/src/lib/Edje.h,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -3 -r1.46 -r1.47
--- Edje.h 23 Jul 2006 19:33:27 -0000 1.46
+++ Edje.h 19 Aug 2006 18:22:01 -0000 1.47
@@ -218,6 +218,7 @@
EAPI void edje_object_calc_force (Evas_Object *obj);
EAPI void edje_object_size_min_calc (Evas_Object *obj,
Evas_Coord *minw, Evas_Coord *minh);
EAPI int edje_object_part_exists (Evas_Object *obj, const
char *part);
+ EAPI Evas_Object *edje_object_part_object_get (Evas_Object *obj, const
char *part);
EAPI void edje_object_part_geometry_get (Evas_Object *obj, const
char *part, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h);
EAPI void edje_object_text_change_cb_set (Evas_Object *obj, void
(*func) (void *data, Evas_Object *obj, const char *part), void *data);
EAPI void edje_object_part_text_set (Evas_Object *obj, const
char *part, const char *text);
===================================================================
RCS file: /cvs/e/e17/libs/edje/src/lib/edje_util.c,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -3 -r1.81 -r1.82
--- edje_util.c 23 Jul 2006 19:33:27 -0000 1.81
+++ edje_util.c 19 Aug 2006 18:22:01 -0000 1.82
@@ -573,6 +573,31 @@
return 1;
}
+/**
+ * Gets the Evas_Object corresponding to a given part.
+ * You should never modify the state of the returned object
+ * (with evas_object_move() or evas_object_hide() for example),
+ * but you can safely query infos about its current state
+ * (with evas_object_visible_get() or evas_object_color_get() for example)
+ *
+ * @param obj A valid Evas_Object handle
+ * @param part The Edje part
+ * @return Returns the Evas_Object corresponding to the given part,
+ * or NULL on failure (if the part doesn't exist)
+ **/
+EAPI Evas_Object *
+edje_object_part_object_get(Evas_Object *obj, const char *part)
+{
+ Edje *ed;
+ Edje_Real_Part *rp;
+
+ ed = _edje_fetch(obj);
+ if ((!ed) || (!part)) return NULL;
+ rp = _edje_real_part_get(ed, (char *)part);
+ if (!rp) return NULL;
+ return rp->object;
+}
+
/** Get Edje part geometry
* @param obj A valid Evas_Object handle
* @param part The Edje part
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs