aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2002-04-26 04:05:40 +0800
committerChris Lahey <clahey@src.gnome.org>2002-04-26 04:05:40 +0800
commit0a226a048384c990cb180b5f52a6c51f153252c3 (patch)
treeb6d6490c760d524cbb676681d38c7093fa18a123
parent6c0fded334bf9c7a2b7142cae6ee372afe2026be (diff)
downloadgsoc2013-evolution-0a226a048384c990cb180b5f52a6c51f153252c3.tar.gz
gsoc2013-evolution-0a226a048384c990cb180b5f52a6c51f153252c3.tar.zst
gsoc2013-evolution-0a226a048384c990cb180b5f52a6c51f153252c3.zip
Ansification patch from danw.
2002-04-25 Christopher James Lahey <clahey@ximian.com> * gal/e-paned/e-paned.c, gal/e-text/e-entry.c, gal/util/e-bit-array.c, gal/util/e-sorter-array.c, gal/util/e-sorter.c, gal/util/e-text-event-processor.c, gal/widgets/color-group.c, gal/widgets/color-palette.c, gal/widgets/e-canvas-vbox.c, gal/widgets/e-canvas.c, gal/widgets/e-canvas.h, gal/widgets/e-categories-master-list-array.c, gal/widgets/e-categories-master-list-combo.c, gal/widgets/e-categories-master-list-dialog-model.c, gal/widgets/e-categories-master-list-dialog.c, gal/widgets/e-categories.c, gal/widgets/e-reflow-model.c, gal/widgets/e-reflow.c, gal/widgets/e-selection-model-array.c, gal/widgets/e-selection-model-simple.c, gal/widgets/e-selection-model.c, gal/widgets/e-selection-model.h, gal/widgets/gtk-combo-box.c, gal/widgets/gtk-combo-stack.c, gal/widgets/widget-color-combo.c, gal/widgets/widget-pixmap-combo.c: Ansification patch from danw. svn path=/trunk/; revision=16589
-rw-r--r--e-util/e-bit-array.c14
-rw-r--r--e-util/e-sorter-array.c4
-rw-r--r--e-util/e-sorter.c2
-rw-r--r--e-util/e-text-event-processor.c2
-rw-r--r--widgets/misc/e-canvas-vbox.c2
-rw-r--r--widgets/misc/e-canvas.c21
-rw-r--r--widgets/misc/e-canvas.h2
-rw-r--r--widgets/misc/e-reflow-model.c2
-rw-r--r--widgets/misc/e-reflow.c2
-rw-r--r--widgets/misc/e-selection-model-array.c4
-rw-r--r--widgets/misc/e-selection-model-simple.c2
-rw-r--r--widgets/misc/e-selection-model.c4
-rw-r--r--widgets/misc/e-selection-model.h2
-rw-r--r--widgets/text/e-entry.c4
14 files changed, 34 insertions, 33 deletions
diff --git a/e-util/e-bit-array.c b/e-util/e-bit-array.c
index 274ee32b09..9dd8a17b60 100644
--- a/e-util/e-bit-array.c
+++ b/e-util/e-bit-array.c
@@ -48,7 +48,7 @@ e_bit_array_insert_real(EBitArray *eba, int row)
if(eba->bit_count >= 0) {
/* Add another word if needed. */
if ((eba->bit_count & 0x1f) == 0) {
- eba->data = g_renew(gint, eba->data, (eba->bit_count >> 5) + 1);
+ eba->data = g_renew(guint32, eba->data, (eba->bit_count >> 5) + 1);
eba->data[eba->bit_count >> 5] = 0;
}
@@ -97,7 +97,7 @@ e_bit_array_delete_real(EBitArray *eba, int row, gboolean move_selection_mode)
eba->bit_count --;
/* Remove the last word if not needed. */
if ((eba->bit_count & 0x1f) == 0) {
- eba->data = g_renew(gint, eba->data, eba->bit_count >> 5);
+ eba->data = g_renew(guint32, eba->data, eba->bit_count >> 5);
}
if (move_selection_mode && selected) {
e_bit_array_select_single_row (eba, row > 0 ? row - 1 : 0);
@@ -266,7 +266,7 @@ e_bit_array_select_all (EBitArray *eba)
int i;
if (!eba->data)
- eba->data = g_new0 (gint, (eba->bit_count + 31) / 32);
+ eba->data = g_new0 (guint32, (eba->bit_count + 31) / 32);
for (i = 0; i < (eba->bit_count + 31) / 32; i ++) {
eba->data[i] = ONES;
@@ -298,7 +298,7 @@ e_bit_array_invert_selection (EBitArray *eba)
int i;
if (!eba->data)
- eba->data = g_new0 (gint, (eba->bit_count + 31) / 32);
+ eba->data = g_new0 (guint32, (eba->bit_count + 31) / 32);
for (i = 0; i < (eba->bit_count + 31) / 32; i ++) {
eba->data[i] = ~eba->data[i];
@@ -379,7 +379,7 @@ e_bit_array_select_single_row (EBitArray *eba, int row)
if (!((i == BOX(row) && eba->data[i] == BITMASK(row)) ||
(i != BOX(row) && eba->data[i] == 0))) {
g_free(eba->data);
- eba->data = g_new0(gint, (eba->bit_count + 31) / 32);
+ eba->data = g_new0(guint32, (eba->bit_count + 31) / 32);
eba->data[BOX(row)] = BITMASK(row);
break;
@@ -417,13 +417,13 @@ e_bit_array_class_init (EBitArrayClass *klass)
}
E_MAKE_TYPE(e_bit_array, "EBitArray", EBitArray,
- e_bit_array_class_init, e_bit_array_init, PARENT_TYPE);
+ e_bit_array_class_init, e_bit_array_init, PARENT_TYPE)
EBitArray *
e_bit_array_new (int count)
{
EBitArray *eba = gtk_type_new (e_bit_array_get_type ());
eba->bit_count = count;
- eba->data = g_new0(gint, (eba->bit_count + 31) / 32);
+ eba->data = g_new0(guint32, (eba->bit_count + 31) / 32);
return eba;
}
diff --git a/e-util/e-sorter-array.c b/e-util/e-sorter-array.c
index 500bbe466e..11a40a9ca9 100644
--- a/e-util/e-sorter-array.c
+++ b/e-util/e-sorter-array.c
@@ -32,7 +32,7 @@
/* The arguments we take */
enum {
- ARG_0,
+ ARG_0
};
#define PARENT_TYPE e_sorter_get_type()
@@ -289,4 +289,4 @@ esa_init (ESorterArray *esa)
esa->backsorted = NULL;
}
-E_MAKE_TYPE(e_sorter_array, "ESorterArray", ESorterArray, esa_class_init, esa_init, PARENT_TYPE);
+E_MAKE_TYPE(e_sorter_array, "ESorterArray", ESorterArray, esa_class_init, esa_init, PARENT_TYPE)
diff --git a/e-util/e-sorter.c b/e-util/e-sorter.c
index 0617045b6f..4f6c8e069a 100644
--- a/e-util/e-sorter.c
+++ b/e-util/e-sorter.c
@@ -59,7 +59,7 @@ es_init (ESorter *es)
{
}
-E_MAKE_TYPE(e_sorter, "ESorter", ESorter, es_class_init, es_init, PARENT_TYPE);
+E_MAKE_TYPE(e_sorter, "ESorter", ESorter, es_class_init, es_init, PARENT_TYPE)
ESorter *
e_sorter_new (void)
diff --git a/e-util/e-text-event-processor.c b/e-util/e-text-event-processor.c
index 8ef98c5447..b24ce2433a 100644
--- a/e-util/e-text-event-processor.c
+++ b/e-util/e-text-event-processor.c
@@ -36,7 +36,7 @@ static GtkObjectClass *parent_class = NULL;
/* The arguments we take */
enum {
ARG_0,
- ARG_ALLOW_NEWLINES,
+ ARG_ALLOW_NEWLINES
};
enum {
diff --git a/widgets/misc/e-canvas-vbox.c b/widgets/misc/e-canvas-vbox.c
index e3ca3ce5d1..2bbff343ed 100644
--- a/widgets/misc/e-canvas-vbox.c
+++ b/widgets/misc/e-canvas-vbox.c
@@ -53,7 +53,7 @@ enum {
ARG_WIDTH,
ARG_MINIMUM_WIDTH,
ARG_HEIGHT,
- ARG_SPACING,
+ ARG_SPACING
};
GtkType
diff --git a/widgets/misc/e-canvas.c b/widgets/misc/e-canvas.c
index 594591f011..378bc31e56 100644
--- a/widgets/misc/e-canvas.c
+++ b/widgets/misc/e-canvas.c
@@ -800,8 +800,9 @@ e_canvas_item_invoke_reflow (GnomeCanvasItem *item, int flags)
if (item->object.flags & E_CANVAS_ITEM_NEEDS_REFLOW) {
ECanvasItemReflowFunc func;
- func = gtk_object_get_data (GTK_OBJECT (item),
- "ECanvasItem::reflow_callback");
+ func = (ECanvasItemReflowFunc)
+ gtk_object_get_data (GTK_OBJECT (item),
+ "ECanvasItem::reflow_callback");
if (func)
func (item, flags);
}
@@ -917,7 +918,7 @@ e_canvas_item_set_cursor (GnomeCanvasItem *item, gpointer id)
for (list = canvas->selection; list; list = g_list_next(list)) {
info = list->data;
- func = gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc)gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_callback");
if (func)
func(info->item, flags, info->id);
g_message ("ECANVAS: free info (2): item %p, id %p",
@@ -938,7 +939,7 @@ e_canvas_item_set_cursor (GnomeCanvasItem *item, gpointer id)
g_message ("ECANVAS: new info item %p, id %p", item, id);
flags = E_CANVAS_ITEM_SELECTION_SELECT | E_CANVAS_ITEM_SELECTION_CURSOR;
- func = gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc)gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
if (func)
func(item, flags, id);
@@ -969,7 +970,7 @@ e_canvas_item_add_selection (GnomeCanvasItem *item, gpointer id)
canvas = E_CANVAS(item->canvas);
if (canvas->cursor) {
- func = gtk_object_get_data(GTK_OBJECT(canvas->cursor->item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc)gtk_object_get_data(GTK_OBJECT(canvas->cursor->item), "ECanvasItem::selection_callback");
if (func)
func(canvas->cursor->item, flags, canvas->cursor->id);
}
@@ -984,11 +985,11 @@ e_canvas_item_add_selection (GnomeCanvasItem *item, gpointer id)
if (search->item == item) {
ECanvasItemSelectionCompareFunc compare_func;
- compare_func = gtk_object_get_data(GTK_OBJECT(search->item), "ECanvasItem::selection_compare_callback");
+ compare_func = (ECanvasItemSelectionCompareFunc)gtk_object_get_data(GTK_OBJECT(search->item), "ECanvasItem::selection_compare_callback");
if (compare_func(search->item, search->id, id, 0) == 0) {
canvas->cursor = search;
- func = gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc)gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
if (func)
func(item, flags, search->id);
return;
@@ -1002,7 +1003,7 @@ e_canvas_item_add_selection (GnomeCanvasItem *item, gpointer id)
info->id = id;
g_message ("ECANVAS: new info (2): item %p, id %p", item, id);
- func = gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc)gtk_object_get_data(GTK_OBJECT(item), "ECanvasItem::selection_callback");
if (func)
func(item, flags, id);
@@ -1031,11 +1032,11 @@ e_canvas_item_remove_selection (GnomeCanvasItem *item, gpointer id)
if (info->item == item) {
ECanvasItemSelectionCompareFunc compare_func;
- compare_func = gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_compare_callback");
+ compare_func = (ECanvasItemSelectionCompareFunc)gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_compare_callback");
if (compare_func(info->item, info->id, id, 0) == 0) {
ECanvasItemSelectionFunc func;
- func = gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_callback");
+ func = (ECanvasItemSelectionFunc) gtk_object_get_data(GTK_OBJECT(info->item), "ECanvasItem::selection_callback");
if (func)
func(info->item, flags, info->id);
canvas->selection = g_list_remove_link(canvas->selection, list);
diff --git a/widgets/misc/e-canvas.h b/widgets/misc/e-canvas.h
index 1e8397b301..ee25a4b6bf 100644
--- a/widgets/misc/e-canvas.h
+++ b/widgets/misc/e-canvas.h
@@ -66,7 +66,7 @@ enum {
enum {
E_CANVAS_ITEM_SELECTION_SELECT = 1 << 0, /* TRUE = select. FALSE = unselect. */
E_CANVAS_ITEM_SELECTION_CURSOR = 1 << 1, /* TRUE = has become cursor. FALSE = not cursor. */
- E_CANVAS_ITEM_SELECTION_DELETE_DATA = 1 << 2,
+ E_CANVAS_ITEM_SELECTION_DELETE_DATA = 1 << 2
};
typedef struct {
diff --git a/widgets/misc/e-reflow-model.c b/widgets/misc/e-reflow-model.c
index 0cf218e829..8e75b8249e 100644
--- a/widgets/misc/e-reflow-model.c
+++ b/widgets/misc/e-reflow-model.c
@@ -32,7 +32,7 @@
#define d(x)
-d(static gint depth = 0);
+d(static gint depth = 0;)
static GtkObjectClass *e_reflow_model_parent_class;
diff --git a/widgets/misc/e-reflow.c b/widgets/misc/e-reflow.c
index f628dec126..6b4ff4a416 100644
--- a/widgets/misc/e-reflow.c
+++ b/widgets/misc/e-reflow.c
@@ -63,7 +63,7 @@ enum {
ARG_HEIGHT,
ARG_EMPTY_MESSAGE,
ARG_MODEL,
- ARG_COLUMN_WIDTH,
+ ARG_COLUMN_WIDTH
};
enum {
diff --git a/widgets/misc/e-selection-model-array.c b/widgets/misc/e-selection-model-array.c
index 2ed1f0a6be..76efe13de3 100644
--- a/widgets/misc/e-selection-model-array.c
+++ b/widgets/misc/e-selection-model-array.c
@@ -35,7 +35,7 @@ static ESelectionModelClass *parent_class;
enum {
ARG_0,
ARG_CURSOR_ROW,
- ARG_CURSOR_COL,
+ ARG_CURSOR_COL
};
void
@@ -547,4 +547,4 @@ e_selection_model_array_class_init (ESelectionModelArrayClass *klass)
}
E_MAKE_TYPE(e_selection_model_array, "ESelectionModelArray", ESelectionModelArray,
- e_selection_model_array_class_init, e_selection_model_array_init, PARENT_TYPE);
+ e_selection_model_array_class_init, e_selection_model_array_init, PARENT_TYPE)
diff --git a/widgets/misc/e-selection-model-simple.c b/widgets/misc/e-selection-model-simple.c
index 0d87cdc779..23257d071d 100644
--- a/widgets/misc/e-selection-model-simple.c
+++ b/widgets/misc/e-selection-model-simple.c
@@ -53,7 +53,7 @@ e_selection_model_simple_class_init (ESelectionModelSimpleClass *klass)
}
E_MAKE_TYPE(e_selection_model_simple, "ESelectionModelSimple", ESelectionModelSimple,
- e_selection_model_simple_class_init, e_selection_model_simple_init, PARENT_TYPE);
+ e_selection_model_simple_class_init, e_selection_model_simple_init, PARENT_TYPE)
/**
* e_selection_model_simple_new
diff --git a/widgets/misc/e-selection-model.c b/widgets/misc/e-selection-model.c
index b7472e99f5..aea1ad9163 100644
--- a/widgets/misc/e-selection-model.c
+++ b/widgets/misc/e-selection-model.c
@@ -47,7 +47,7 @@ enum {
ARG_0,
ARG_SORTER,
ARG_SELECTION_MODE,
- ARG_CURSOR_MODE,
+ ARG_CURSOR_MODE
};
inline static void
@@ -215,7 +215,7 @@ e_selection_model_class_init (ESelectionModelClass *klass)
}
E_MAKE_TYPE(e_selection_model, "ESelectionModel", ESelectionModel,
- e_selection_model_class_init, e_selection_model_init, PARENT_TYPE);
+ e_selection_model_class_init, e_selection_model_init, PARENT_TYPE)
/**
* e_selection_model_is_row_selected
diff --git a/widgets/misc/e-selection-model.h b/widgets/misc/e-selection-model.h
index fde97a0035..c9219a7e48 100644
--- a/widgets/misc/e-selection-model.h
+++ b/widgets/misc/e-selection-model.h
@@ -48,7 +48,7 @@ typedef void (*EForeachFunc) (int model_row,
typedef enum {
E_CURSOR_LINE,
E_CURSOR_SIMPLE,
- E_CURSOR_SPREADSHEET,
+ E_CURSOR_SPREADSHEET
} ECursorMode;
typedef struct {
diff --git a/widgets/text/e-entry.c b/widgets/text/e-entry.c
index 6c060244f5..6e4b6a1949 100644
--- a/widgets/text/e-entry.c
+++ b/widgets/text/e-entry.c
@@ -97,7 +97,7 @@ enum {
ARG_DRAW_BACKGROUND,
ARG_DRAW_BUTTON,
ARG_EMULATE_LABEL_RESIZE,
- ARG_CURSOR_POS,
+ ARG_CURSOR_POS
};
typedef struct _EEntryPrivate EEntryPrivate;
@@ -1352,4 +1352,4 @@ e_entry_class_init (GtkObjectClass *object_class)
GTK_TYPE_INT, GTK_ARG_READWRITE, ARG_CURSOR_POS);
}
-E_MAKE_TYPE(e_entry, "EEntry", EEntry, e_entry_class_init, e_entry_init, PARENT_TYPE);
+E_MAKE_TYPE(e_entry, "EEntry", EEntry, e_entry_class_init, e_entry_init, PARENT_TYPE)