aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-06-27 12:18:13 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-07-02 22:34:10 +0800
commit0b9b5aa31d7e4a328959b3db3038b56a7cf89891 (patch)
treed0fbd111b3e59c9f85c21a18d2821143f839313b /e-util
parent59ddc1f073aff7d67399c3b0ecc3ec3ec9218aba (diff)
downloadgsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar.gz
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar.bz2
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar.lz
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar.xz
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.tar.zst
gsoc2013-evolution-0b9b5aa31d7e4a328959b3db3038b56a7cf89891.zip
ETableSortInfo: Use *unsigned* ints for index/length params.
So we don't have to worry about negative values.
Diffstat (limited to 'e-util')
-rw-r--r--e-util/e-table-sort-info.c28
-rw-r--r--e-util/e-table-sort-info.h12
2 files changed, 20 insertions, 20 deletions
diff --git a/e-util/e-table-sort-info.c b/e-util/e-table-sort-info.c
index 9f9774555d..d6fadfd9a0 100644
--- a/e-util/e-table-sort-info.c
+++ b/e-util/e-table-sort-info.c
@@ -248,7 +248,7 @@ e_table_sort_info_grouping_get_count (ETableSortInfo *sort_info)
static void
table_sort_info_grouping_real_truncate (ETableSortInfo *sort_info,
- gint length)
+ guint length)
{
if (length < sort_info->priv->group_count)
sort_info->priv->group_count = length;
@@ -271,7 +271,7 @@ table_sort_info_grouping_real_truncate (ETableSortInfo *sort_info,
*/
void
e_table_sort_info_grouping_truncate (ETableSortInfo *sort_info,
- gint length)
+ guint length)
{
g_return_if_fail (E_IS_TABLE_SORT_INFO (sort_info));
@@ -289,7 +289,7 @@ e_table_sort_info_grouping_truncate (ETableSortInfo *sort_info,
*/
ETableSortColumn
e_table_sort_info_grouping_get_nth (ETableSortInfo *sort_info,
- gint n)
+ guint n)
{
ETableSortColumn fake = {0, 0};
@@ -315,7 +315,7 @@ e_table_sort_info_grouping_get_nth (ETableSortInfo *sort_info,
*/
void
e_table_sort_info_grouping_set_nth (ETableSortInfo *sort_info,
- gint n,
+ guint n,
ETableSortColumn column)
{
g_return_if_fail (E_IS_TABLE_SORT_INFO (sort_info));
@@ -344,7 +344,7 @@ e_table_sort_info_sorting_get_count (ETableSortInfo *sort_info)
static void
table_sort_info_sorting_real_truncate (ETableSortInfo *sort_info,
- gint length)
+ guint length)
{
if (length < sort_info->priv->sort_count)
sort_info->priv->sort_count = length;
@@ -367,7 +367,7 @@ table_sort_info_sorting_real_truncate (ETableSortInfo *sort_info,
*/
void
e_table_sort_info_sorting_truncate (ETableSortInfo *sort_info,
- gint length)
+ guint length)
{
g_return_if_fail (E_IS_TABLE_SORT_INFO (sort_info));
@@ -385,7 +385,7 @@ e_table_sort_info_sorting_truncate (ETableSortInfo *sort_info,
*/
ETableSortColumn
e_table_sort_info_sorting_get_nth (ETableSortInfo *sort_info,
- gint n)
+ guint n)
{
ETableSortColumn fake = {0, 0};
@@ -408,7 +408,7 @@ e_table_sort_info_sorting_get_nth (ETableSortInfo *sort_info,
*/
void
e_table_sort_info_sorting_set_nth (ETableSortInfo *sort_info,
- gint n,
+ guint n,
ETableSortColumn column)
{
g_return_if_fail (E_IS_TABLE_SORT_INFO (sort_info));
@@ -435,7 +435,7 @@ e_table_sort_info_load_from_node (ETableSortInfo *sort_info,
xmlNode *node,
gdouble state_version)
{
- gint i;
+ guint i;
xmlNode *grouping;
g_return_if_fail (E_IS_TABLE_SORT_INFO (sort_info));
@@ -457,8 +457,8 @@ e_table_sort_info_load_from_node (ETableSortInfo *sort_info,
e_table_sort_info_sorting_set_nth (sort_info, i++, column);
}
} else {
- gint gcnt = 0;
- gint scnt = 0;
+ guint gcnt = 0;
+ guint scnt = 0;
for (grouping = node->children; grouping; grouping = grouping->next) {
ETableSortColumn column;
@@ -494,9 +494,9 @@ e_table_sort_info_save_to_node (ETableSortInfo *sort_info,
xmlNode *parent)
{
xmlNode *grouping;
- gint sort_count;
- gint group_count;
- gint i;
+ guint sort_count;
+ guint group_count;
+ guint i;
g_return_val_if_fail (E_IS_TABLE_SORT_INFO (sort_info), NULL);
diff --git a/e-util/e-table-sort-info.h b/e-util/e-table-sort-info.h
index 28ca607f3f..ad3b3db4e4 100644
--- a/e-util/e-table-sort-info.h
+++ b/e-util/e-table-sort-info.h
@@ -89,28 +89,28 @@ guint e_table_sort_info_grouping_get_count
(ETableSortInfo *sort_info);
void e_table_sort_info_grouping_truncate
(ETableSortInfo *sort_info,
- gint length);
+ guint length);
ETableSortColumn
e_table_sort_info_grouping_get_nth
(ETableSortInfo *sort_info,
- gint n);
+ guint n);
void e_table_sort_info_grouping_set_nth
(ETableSortInfo *sort_info,
- gint n,
+ guint n,
ETableSortColumn column);
guint e_table_sort_info_sorting_get_count
(ETableSortInfo *sort_info);
void e_table_sort_info_sorting_truncate
(ETableSortInfo *sort_info,
- gint length);
+ guint length);
ETableSortColumn
e_table_sort_info_sorting_get_nth
(ETableSortInfo *sort_info,
- gint n);
+ guint n);
void e_table_sort_info_sorting_set_nth
(ETableSortInfo *sort_info,
- gint n,
+ guint n,
ETableSortColumn column);
void e_table_sort_info_load_from_node
(ETableSortInfo *sort_info,