summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCedric Bail <cedric.bail@samsung.com>2013-07-19 18:37:11 +0900
committerCedric Bail <cedric.bail@samsung.com>2013-07-19 18:37:43 +0900
commit614263c1ed064444fadefb3367b922d1c34d62fa (patch)
tree00c6b9bc3d8c89e90e83d59d39be540a9cc39a49
parentf325a38632bd6c50842f8aafdba4e66b43f4ac35 (diff)
evas: add geometry_set to please zmike.
Diffstat (limited to '')
-rw-r--r--src/lib/evas/Evas_Legacy.h28
-rw-r--r--src/lib/evas/canvas/evas_object_main.c11
2 files changed, 39 insertions, 0 deletions
diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index c86cc774ca..fed808660f 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -1936,6 +1936,34 @@ EAPI void evas_object_resize(Evas_Object *obj, Evas_Coord w, Evas_Co
1936EAPI void evas_object_geometry_get(const Evas_Object *obj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h) EINA_ARG_NONNULL(1); 1936EAPI void evas_object_geometry_get(const Evas_Object *obj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h) EINA_ARG_NONNULL(1);
1937 1937
1938/** 1938/**
1939 * Set the position and (rectangular) size of the given Evas object.
1940 *
1941 * @param obj The given Evas object.
1942 * @param x X position to move the object to, in canvas units.
1943 * @param y Y position to move the object to, in canvas units.
1944 * @param w The new width of the Evas object.
1945 * @param h The new height of the Evas object.
1946 *
1947 * The position, naturally, will be relative to the top left corner of
1948 * the canvas' viewport.
1949 *
1950 * If the object get moved, the object's ::EVAS_CALLBACK_MOVE callback
1951 * will be called.
1952 *
1953 * If the object get resized, the object's ::EVAS_CALLBACK_RESIZE callback
1954 * will be called.
1955 *
1956 * @see evas_object_move()
1957 * @see evas_object_resize()
1958 * @see evas_object_geometry_get
1959 *
1960 * @since 1.8
1961 * @ingroup Evas_Object_Group_Basic
1962 */
1963EAPI void evas_object_geometry_set(Evas_Object *eo_obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h) EINA_ARG_NONNULL(1);
1964
1965
1966/**
1939 * Makes the given Evas object visible. 1967 * Makes the given Evas object visible.
1940 * 1968 *
1941 * @param obj The given Evas object. 1969 * @param obj The given Evas object.
diff --git a/src/lib/evas/canvas/evas_object_main.c b/src/lib/evas/canvas/evas_object_main.c
index ce414025ee..ef709c62d0 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -671,6 +671,17 @@ end:
671} 671}
672 672
673EAPI void 673EAPI void
674evas_object_geometry_set(Evas_Object *eo_obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h)
675{
676 MAGIC_CHECK(eo_obj, Evas_Object, MAGIC_OBJ);
677 return;
678 MAGIC_CHECK_END();
679 eo_do(eo_obj,
680 evas_obj_position_set(x, y),
681 evas_obj_size_set(w, h));
682}
683
684EAPI void
674evas_object_move(Evas_Object *eo_obj, Evas_Coord x, Evas_Coord y) 685evas_object_move(Evas_Object *eo_obj, Evas_Coord x, Evas_Coord y)
675{ 686{
676 MAGIC_CHECK(eo_obj, Evas_Object, MAGIC_OBJ); 687 MAGIC_CHECK(eo_obj, Evas_Object, MAGIC_OBJ);