From 4b829c4fffe52585ce7cb98b9916d2dedd8f39cd Mon Sep 17 00:00:00 2001 From: Radek Doulik Date: Thu, 10 Jun 2004 17:00:45 +0000 Subject: fixes to get rid of compiler warnings 2004-06-10 Radek Doulik * gal/a11y/e-table/gal-a11y-e-table-click-to-add.c (idle_do_action): added cast * gal/a11y/e-table/gal-a11y-e-cell-tree.c (gal_a11y_e_cell_tree_new): added cast * gal/a11y/e-table/gal-a11y-e-cell.c: added #include * gal/e-text/e-text.c (_get_position): removed unused variable * gal/e-text/e-completion.c: #if 0'ed e_completion_sort * tests/test-text.c (create_entry): removed unused variables added #include "gal/widgets/e-canvas-utils.h" added #include "gal/e-text/e-text-model.h" (create_text): removed unused variables (create_ro_text): ditto * tests/test-table-1.c (create_table): added cast * tests/test-completion.c (main): added cast * gal/a11y/e-text/gal-a11y-e-text.c (et_get_text): return NULL if check fails added #include for strlen (et_get_text_after_offset): fixed typo defalut --> default (et_get_text_at_offset): ditto (et_get_character_extents): removed unused variables (et_set_selection): ditto (_et_command_cb): added default: label to quiet compiler * gal/a11y/e-table/gal-a11y-e-table-click-to-add-factory.c (gal_a11y_e_table_click_to_add_factory_create_accessible): return NULL if check fails * gal/a11y/e-table/gal-a11y-e-table-click-to-add.c (idle_do_action): fixed wrong cast (idle_do_action): removed unused variables (etcta_ref_child): return NULL if check fails (gal_a11y_e_table_click_to_add_new): ditto (gal_a11y_e_table_click_to_add_new): removed unused variable * gal/a11y/e-table/gal-a11y-e-table-item-factory.c (gal_a11y_e_table_item_factory_create_accessible): return NULL if fails (gal_a11y_e_table_item_factory_create_accessible): added cast (gal_a11y_e_table_item_factory_create_accessible): removed unused variable * gal/a11y/e-table/gal-a11y-e-table-item.c (eti_dispose): removed unused variable (eti_get_parent): ditto (eti_get_n_children): ditto (eti_ref_child): ditto (eti_get_index_in_parent): ditto (eti_ref_accessible_at_point): return value (NULL) (cell_destroyed): removed unused variable (cell_destroyed): ditto (table_add_row_selection): ditto added #inclued for memset, memmove (eti_rows_inserted): removed unused variable (eti_rows_deleted): ditto (eti_header_structure_changed): ditto * gal/a11y/e-table/gal-a11y-e-cell-popup.c (gal_a11y_e_cell_popup_class_init): removed unused variable added #include "gal-a11y-e-cell-registry.h" (popup_cell_action): removed unused variable * gal/a11y/e-table/gal-a11y-e-cell-toggle.c (toggle_cell_action): removed unused variable * gal/a11y/e-table/gal-a11y-e-cell-tree.c: added #include "gal-a11y-e-cell-registry.h" (gal_a11y_e_cell_tree_new): add cast (gal_a11y_e_cell_tree_new): removed unused variable * gal/a11y/e-table/gal-a11y-e-cell-text.c: added #include (ect_remove_selection): removed unused variable (ect_copy_text): added cast (ect_delete_text): ditto (ect_paste_text): ditto (ect_init): ditto * gal/a11y/e-table/gal-a11y-e-cell.c (eti_grab_focus): added cast (eti_grab_focus): ditto (eti_grab_focus): return TRUE (grab was successful) added #include * gal/a11y/e-table/gal-a11y-e-tree.c: added #include "gal-a11y-e-table-item.h" (gal_a11y_e_tree_new): removed unused variable * gal/e-text/e-text.c (_do_tooltip): removed unused variable (e_text_event): added cast (primary_clear_cb): removed unused variable (_get_position): ditto (_get_position): ditto #if 0'ed unused prototypes * gal/e-text/e-text-model.c (e_text_model_real_insert_length): removed unused variables * gal/e-text/e-completion.c (e_completion_sort): #if'0 ed, as it's not used anywhere * gal/widgets/e-reflow.c (items_inserted): remove unused variables * gal/widgets/e-categories.c (e_categories_get_property): remove unused variable * gal/widgets/e-categories-master-list-dialog.c (dialog_destroyed): added cast * gal/widgets/e-categories-master-list-combo.c (ecmlc_ecml_changed): remove unused variable * gal/widgets/color-palette.c: include string.h for memset prototype svn path=/trunk/; revision=26288 --- a11y/e-table/gal-a11y-e-table-click-to-add.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'a11y/e-table/gal-a11y-e-table-click-to-add.c') diff --git a/a11y/e-table/gal-a11y-e-table-click-to-add.c b/a11y/e-table/gal-a11y-e-table-click-to-add.c index 1b55d526df..13214a7ddd 100644 --- a/a11y/e-table/gal-a11y-e-table-click-to-add.c +++ b/a11y/e-table/gal-a11y-e-table-click-to-add.c @@ -57,11 +57,11 @@ idle_do_action (gpointer data) { GdkEventButton event; ETableClickToAdd * etcta; - gint x, y, width, height, finished; + gint finished; g_return_val_if_fail ( data!= NULL, FALSE); - etcta = atk_gobject_accessible_get_object (ATK_OBJECT(data)); + etcta = E_TABLE_CLICK_TO_ADD (atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (data))); g_return_val_if_fail (etcta, FALSE); event.x = 0; @@ -127,7 +127,7 @@ etcta_ref_child (AtkObject *accessible, etcta = E_TABLE_CLICK_TO_ADD(atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (accessible))); - g_return_if_fail (etcta); + g_return_val_if_fail (etcta, NULL); if (etcta->rect) { atk_obj = atk_gobject_accessible_for_object (G_OBJECT(etcta->rect)); @@ -247,9 +247,8 @@ gal_a11y_e_table_click_to_add_new (GObject *widget) GalA11yETableClickToAdd *a11y; ETableClickToAdd * etcta; GalA11yETableClickToAddPrivate *priv; - gint id; - g_return_if_fail (widget != NULL); + g_return_val_if_fail (widget != NULL, NULL); a11y = g_object_new (gal_a11y_e_table_click_to_add_get_type (), NULL); priv = GET_PRIVATE (a11y); -- cgit