From: sanjeev Date: Wed, 29 Feb 2012 03:01:58 +0000 (+0000) Subject: Implementation for elm_panes_content_right_size_get/set(). X-Git-Tag: REL_F_I9500_20120323_1~17^2~487 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4120b003a5fdf3270cae963fbaf4577af6fdde06;p=framework%2Fuifw%2Felementary.git Implementation for elm_panes_content_right_size_get/set(). Thanks to jeremy@asynk.ch Signed-off-by: Sanjeev BA git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/elementary@68527 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/elm_panes.c b/src/lib/elm_panes.c index 042c185..605740c 100644 --- a/src/lib/elm_panes.c +++ b/src/lib/elm_panes.c @@ -422,6 +422,18 @@ elm_panes_content_left_size_set(Evas_Object *obj, double size) edje_object_part_drag_value_set(wd->panes, "elm.bar", size, 0.0); } +EAPI double +elm_panes_content_right_size_get(const Evas_Object *obj) +{ + return (1.0 - elm_panes_content_left_size_get(obj)); +} + +EAPI void +elm_panes_content_right_size_set(Evas_Object *obj, double size) +{ + elm_panes_content_left_size_set(obj, (1.0 - size)); +} + EAPI void elm_panes_horizontal_set(Evas_Object *obj, Eina_Bool horizontal) { diff --git a/src/lib/elm_panes.h b/src/lib/elm_panes.h index 373ca88..9fbf6f8 100644 --- a/src/lib/elm_panes.h +++ b/src/lib/elm_panes.h @@ -63,7 +63,7 @@ EAPI Evas_Object *elm_panes_add(Evas_Object *parent); * @param obj The panes object. * @param fixed Use @c EINA_TRUE to make @p obj to be * resize the left and right panes @b homogeneously. - * Use @c EINA_FALSE to make use of the values specified in + * Use @c EINA_FALSE to make use of the values specified in * elm_panes_content_left_size_set() and * elm_panes_content_right_size_set() * to resize the left and right panes. @@ -71,7 +71,7 @@ EAPI Evas_Object *elm_panes_add(Evas_Object *parent); * By default panes are resized homogeneously. * * @see elm_panes_fixed_get() - * @see elmpanes_content_left_size_set() + * @see elm_panes_content_left_size_set() * @see elm_panes_content_right_size_set() * * @ingroup Panes @@ -85,7 +85,7 @@ EAPI void elm_panes_fixed_set(Evas_Object *obj, Eina_Boo * @return @c EINA_TRUE, if @p obj is set to be resized @b homogeneously, * * @see elm_panes_fixed_set() for more details. - * @see elmpanes_content_left_size_get() + * @see elm_panes_content_left_size_get() * @see elm_panes_content_right_size_get() * * @ingroup Panes @@ -141,7 +141,6 @@ EAPI void elm_panes_content_left_size_set(Evas_Object *o * * @ingroup Panes */ -// XXX: no implementation for this api? EAPI double elm_panes_content_right_size_get(const Evas_Object *obj); /** @@ -156,9 +155,9 @@ EAPI double elm_panes_content_right_size_get(const Evas_Ob * If something different is required, it can be set with this function. * For example, if the right content should be displayed over * 75% of the panes size, @p size should be passed as @c 0.75. - * This way, right content will be resized to 25% of panes size. + * This way, left content will be resized to 25% of panes size. * - * If displayed vertically, right content is displayed at top, and + * If displayed vertically, left content is displayed at top, and * right content at bottom. * * @note This proportion will change when user drags the panes bar. @@ -167,7 +166,6 @@ EAPI double elm_panes_content_right_size_get(const Evas_Ob * * @ingroup Panes */ -// XXX: no implementation for this api? EAPI void elm_panes_content_right_size_set(Evas_Object *obj, double size);