From 152deb9a9ade98a6a192e1f47658de1fbf7e3b79 Mon Sep 17 00:00:00 2001 From: Ryuan Choi Date: Thu, 25 Apr 2013 18:10:18 +0900 Subject: [PATCH] elm table: Fixed wrong description and argument name about packing API --- legacy/elementary/src/lib/elm_table.c | 70 ++++++++++---------- legacy/elementary/src/lib/elm_table.h | 6 +- legacy/elementary/src/lib/elm_table_eo.h | 30 ++++----- legacy/elementary/src/lib/elm_table_legacy.h | 34 +++++----- 4 files changed, 70 insertions(+), 70 deletions(-) diff --git a/legacy/elementary/src/lib/elm_table.c b/legacy/elementary/src/lib/elm_table.c index 49199e3abb..a125db52ce 100644 --- a/legacy/elementary/src/lib/elm_table.c +++ b/legacy/elementary/src/lib/elm_table.c @@ -322,27 +322,27 @@ _padding_get(Eo *obj, void *_pd EINA_UNUSED, va_list *list) EAPI void elm_table_pack(Evas_Object *obj, Evas_Object *subobj, - int x, - int y, - int w, - int h) + int col, + int row, + int colspan, + int rowspan) { ELM_TABLE_CHECK(obj); - eo_do(obj, elm_obj_table_pack(subobj, x, y, w, h)); + eo_do(obj, elm_obj_table_pack(subobj, col, row, colspan, rowspan)); } static void _pack(Eo *obj, void *_pd EINA_UNUSED, va_list *list) { Evas_Object *subobj = va_arg(*list, Evas_Object *); - int x = va_arg(*list, int); - int y = va_arg(*list, int); - int w = va_arg(*list, int); - int h = va_arg(*list, int); + int col = va_arg(*list, int); + int row = va_arg(*list, int); + int colspan = va_arg(*list, int); + int rowspan = va_arg(*list, int); ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); elm_widget_sub_object_add(obj, subobj); - evas_object_table_pack(wd->resize_obj, subobj, x, y, w, h); + evas_object_table_pack(wd->resize_obj, subobj, col, row, colspan, rowspan); } EAPI void @@ -365,61 +365,61 @@ _unpack(Eo *obj, void *_pd EINA_UNUSED, va_list *list) EAPI void elm_table_pack_set(Evas_Object *subobj, - int x, - int y, - int w, - int h) + int col, + int row, + int colspan, + int rowspan) { Evas_Object *obj = elm_widget_parent_widget_get(subobj); ELM_TABLE_CHECK(obj); - eo_do(obj, elm_obj_table_pack_set(subobj, x, y, w, h)); + eo_do(obj, elm_obj_table_pack_set(subobj, col, row, colspan, rowspan)); } static void _pack_set(Eo *obj, void *_pd EINA_UNUSED, va_list *list) { Evas_Object *subobj = va_arg(*list, Evas_Object *); - int x = va_arg(*list, int); - int y = va_arg(*list, int); - int w = va_arg(*list, int); - int h = va_arg(*list, int); + int col = va_arg(*list, int); + int row = va_arg(*list, int); + int colspan = va_arg(*list, int); + int rowspan = va_arg(*list, int); ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); - evas_object_table_pack(wd->resize_obj, subobj, x, y, w, h); + evas_object_table_pack(wd->resize_obj, subobj, col, row, colspan, rowspan); } EAPI void elm_table_pack_get(Evas_Object *subobj, - int *x, - int *y, - int *w, - int *h) + int *col, + int *row, + int *colspan, + int *rowspan) { Evas_Object *obj = elm_widget_parent_widget_get(subobj); ELM_TABLE_CHECK(obj); - eo_do(obj, elm_obj_table_pack_get(subobj, x, y, w, h)); + eo_do(obj, elm_obj_table_pack_get(subobj, col, row, colspan, rowspan)); } static void _pack_get(Eo *obj, void *_pd EINA_UNUSED, va_list *list) { Evas_Object *subobj = va_arg(*list, Evas_Object *); - int *x = va_arg(*list, int *); - int *y = va_arg(*list, int *); - int *w = va_arg(*list, int *); - int *h = va_arg(*list, int *); + int *col = va_arg(*list, int *); + int *row = va_arg(*list, int *); + int *colspan = va_arg(*list, int *); + int *rowspan = va_arg(*list, int *); - unsigned short ix, iy, iw, ih; + unsigned short icol, irow, icolspan, irowspan; ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); evas_object_table_pack_get - (wd->resize_obj, subobj, &ix, &iy, &iw, &ih); - if (x) *x = ix; - if (y) *y = iy; - if (w) *w = iw; - if (h) *h = ih; + (wd->resize_obj, subobj, &icol, &irow, &icolspan, &irowspan); + if (col) *col = icol; + if (row) *row = irow; + if (colspan) *colspan = icolspan; + if (rowspan) *rowspan = irowspan; } EAPI void diff --git a/legacy/elementary/src/lib/elm_table.h b/legacy/elementary/src/lib/elm_table.h index 4d040c8111..aeef9392f5 100644 --- a/legacy/elementary/src/lib/elm_table.h +++ b/legacy/elementary/src/lib/elm_table.h @@ -17,9 +17,9 @@ * table = elm_table_add(win); * evas_object_show(table); * elm_table_padding_set(table, space_between_columns, space_between_rows); - * elm_table_pack(table, table_content_object, x_coord, y_coord, colspan, rowspan); - * elm_table_pack(table, table_content_object, next_x_coord, next_y_coord, colspan, rowspan); - * elm_table_pack(table, table_content_object, other_x_coord, other_y_coord, colspan, rowspan); + * elm_table_pack(table, table_content_object, column, row, colspan, rowspan); + * elm_table_pack(table, table_content_object, next_column, next_row, colspan, rowspan); + * elm_table_pack(table, table_content_object, other_column, other_row, colspan, rowspan); * @endcode * * The following are examples of how to use a table: diff --git a/legacy/elementary/src/lib/elm_table_eo.h b/legacy/elementary/src/lib/elm_table_eo.h index 23e0c759f3..5f8f770545 100644 --- a/legacy/elementary/src/lib/elm_table_eo.h +++ b/legacy/elementary/src/lib/elm_table_eo.h @@ -86,16 +86,16 @@ enum * @brief Add a subobject on the table with the coordinates passed * * @param[in] subobj - * @param[in] x - * @param[in] y - * @param[in] w - * @param[in] h + * @param[in] column + * @param[in] row + * @param[in] colspan + * @param[in] rowspan * * @see elm_table_pack * * @ingroup Table */ -#define elm_obj_table_pack(subobj, x, y, w, h) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int, x), EO_TYPECHECK(int, y), EO_TYPECHECK(int, w), EO_TYPECHECK(int, h) +#define elm_obj_table_pack(subobj, column, row, colspan, rowspan) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int, col), EO_TYPECHECK(int, row), EO_TYPECHECK(int, colspan), EO_TYPECHECK(int, rowspan) /** * @def elm_obj_table_unpack @@ -118,16 +118,16 @@ enum * @brief Set the packing location of an existing child of the table * * @param[in] subobj - * @param[in] x - * @param[in] y - * @param[in] w - * @param[in] h + * @param[in] column + * @param[in] row + * @param[in] colspan + * @param[in] rowspan * * @see elm_table_pack_set * * @ingroup Table */ -#define elm_obj_table_pack_set(subobj, x, y, w, h) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK_SET), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int, x), EO_TYPECHECK(int, y), EO_TYPECHECK(int, w), EO_TYPECHECK(int, h) +#define elm_obj_table_pack_set(subobj, col, row, colspan, rowspan) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK_SET), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int, col), EO_TYPECHECK(int, row), EO_TYPECHECK(int, colspan), EO_TYPECHECK(int, rowspan) /** * @def elm_obj_table_pack_get @@ -136,16 +136,16 @@ enum * @brief Get the packing location of an existing child of the table * * @param[in] subobj - * @param[out] x - * @param[out] y - * @param[out] w - * @param[out] h + * @param[out] column + * @param[out] row + * @param[out] colspan + * @param[out] rowspan * * @see elm_table_pack_get * * @ingroup Table */ -#define elm_obj_table_pack_get(subobj, x, y, w, h) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK_GET), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int *, x), EO_TYPECHECK(int *, y), EO_TYPECHECK(int *, w), EO_TYPECHECK(int *, h) +#define elm_obj_table_pack_get(subobj, col, row, colspan, rowspan) ELM_OBJ_TABLE_ID(ELM_OBJ_TABLE_SUB_ID_PACK_GET), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(int *, col), EO_TYPECHECK(int *, row), EO_TYPECHECK(int *, colspan), EO_TYPECHECK(int *, rowspan) /** * @def elm_obj_table_clear diff --git a/legacy/elementary/src/lib/elm_table_legacy.h b/legacy/elementary/src/lib/elm_table_legacy.h index 1a20529c0f..018fb0e739 100644 --- a/legacy/elementary/src/lib/elm_table_legacy.h +++ b/legacy/elementary/src/lib/elm_table_legacy.h @@ -59,10 +59,10 @@ EAPI void elm_table_padding_get(const Evas_Object *obj, Evas_Coord *horizon * * @param obj The table object * @param subobj The subobject to be added to the table - * @param x Row number - * @param y Column number - * @param w colspan - * @param h rowspan + * @param col Column number + * @param row Row number + * @param colspan colspan + * @param rowspan rowspan * * @note All positioning inside the table is relative to rows and columns, so * a value of 0 for x and y, means the top left cell of the table, and a @@ -70,7 +70,7 @@ EAPI void elm_table_padding_get(const Evas_Object *obj, Evas_Coord *horizon * * @ingroup Table */ -EAPI void elm_table_pack(Evas_Object *obj, Evas_Object *subobj, int x, int y, int w, int h); +EAPI void elm_table_pack(Evas_Object *obj, Evas_Object *subobj, int col, int row, int colspan, int rowspan); /** * @brief Remove child from table. @@ -86,35 +86,35 @@ EAPI void elm_table_unpack(Evas_Object *obj, Evas_Object *subobj); * @brief Set the packing location of an existing child of the table * * @param subobj The subobject to be modified in the table - * @param x Row number - * @param y Column number - * @param w rowspan - * @param h colspan + * @param col Column number + * @param row Row number + * @param colspan colspan + * @param rowspan rowspan * * Modifies the position of an object already in the table. * * @note All positioning inside the table is relative to rows and columns, so - * a value of 0 for x and y, means the top left cell of the table, and a - * value of 1 for w and h means @p subobj only takes that 1 cell. + * a value of 0 for col and row, means the top left cell of the table, and a + * value of 1 for colspan and rowspan means @p subobj only takes that 1 cell. * * @ingroup Table */ -EAPI void elm_table_pack_set(Evas_Object *subobj, int x, int y, int w, int h); +EAPI void elm_table_pack_set(Evas_Object *subobj, int col, int row, int colspan, int rowspan); /** * @brief Get the packing location of an existing child of the table * * @param subobj The subobject to be modified in the table - * @param x Row number - * @param y Column number - * @param w rowspan - * @param h colspan + * @param col Column number + * @param row Row number + * @param colspan colspan + * @param rowspan rowspan * * @see elm_table_pack_set() * * @ingroup Table */ -EAPI void elm_table_pack_get(Evas_Object *subobj, int *x, int *y, int *w, int *h); +EAPI void elm_table_pack_get(Evas_Object *subobj, int *col, int *row, int *colspan, int *rowspan); /** * @brief Faster way to remove all child objects from a table object.