Re: [evolution-patches] Cleanups for evolution/a11y



lør, 10,.12.2005 kl. 15.25 +0100, skrev Kjartan Maraas:
> More cleanups for evolution.
> 
And this time without random whitespace changes

Index: calendar/ea-cal-view.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/calendar/ea-cal-view.c,v
retrieving revision 1.6
diff -u -p -r1.6 ea-cal-view.c
--- calendar/ea-cal-view.c	30 Sep 2004 07:32:36 -0000	1.6
+++ calendar/ea-cal-view.c	10 Dec 2005 17:07:33 -0000
@@ -191,7 +191,6 @@ ea_cal_view_event_changed_cb (ECalendarV
                               gpointer data)
 {
 	AtkObject *atk_obj;
-	EaCalView *ea_cal_view;
 	AtkObject *event_atk_obj = NULL;
 
 	g_return_if_fail (E_IS_CALENDAR_VIEW (cal_view));
@@ -199,7 +198,6 @@ ea_cal_view_event_changed_cb (ECalendarV
 	atk_obj = gtk_widget_get_accessible (GTK_WIDGET(cal_view));
 	if (!EA_IS_CAL_VIEW (atk_obj))
 		return;
-	ea_cal_view = EA_CAL_VIEW (atk_obj);
 
 	if ((E_IS_DAY_VIEW (cal_view)) && event && event->canvas_item) {
 		event_atk_obj =
@@ -230,7 +228,6 @@ ea_cal_view_event_added_cb (ECalendarVie
                             gpointer data)
 {
 	AtkObject *atk_obj;
-	EaCalView *ea_cal_view;
 	AtkObject *event_atk_obj = NULL;
 	gint index;
 
@@ -239,7 +236,6 @@ ea_cal_view_event_added_cb (ECalendarVie
 	atk_obj = gtk_widget_get_accessible (GTK_WIDGET(cal_view));
 	if (!EA_IS_CAL_VIEW (atk_obj))
 		return;
-	ea_cal_view = EA_CAL_VIEW (atk_obj);
 
 	if ((E_IS_DAY_VIEW (cal_view)) && event && event->canvas_item) {
 		event_atk_obj =
@@ -391,7 +387,6 @@ static G_CONST_RETURN gchar*
 action_interface_get_keybinding (AtkAction *action, gint index)
 {
 	GtkWidget *widget;
-	EaCalView *ea_cal_view;
 
 	widget = GTK_ACCESSIBLE (action)->widget;
 	if (widget == NULL)
@@ -403,29 +398,22 @@ action_interface_get_keybinding (AtkActi
 	if (!GTK_WIDGET_IS_SENSITIVE (widget) || !GTK_WIDGET_VISIBLE (widget))
 		return FALSE;
 
-	 ea_cal_view = EA_CAL_VIEW (action);
-
 	 switch (index) {
 	 case 0:
 		 /* New Appointment */
 		 return "<Alt>fna;<Control>n";
-		 break;
 	 case 1:
 		 /* New Event */
 		 return "<Alt>fnd;<Shift><Control>d";
-		 break;
 	 case 2:
 		 /* New Meeting */
 		 return "<Alt>fne;<Shift><Control>e";
-		 break;
 	 case 3:
 		 /* Go to today */
 		 return "<Alt>vt;<Alt><Control>t";
-		 break;
 	 case 4:
 		 /* Go to date */
 		 return "<Alt>vd;<Alt><Control>g";
-		 break;
 	 default:
 		 break;
 	 }
Index: calendar/ea-day-view-main-item.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/calendar/ea-day-view-main-item.c,v
retrieving revision 1.5
diff -u -p -r1.5 ea-day-view-main-item.c
--- calendar/ea-day-view-main-item.c	25 Apr 2005 09:23:53 -0000	1.5
+++ calendar/ea-day-view-main-item.c	10 Dec 2005 17:07:33 -0000
@@ -1085,8 +1085,6 @@ table_interface_get_row_description (Atk
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EDayViewMainItem *main_item;
-	EDayView *day_view;
 	EaDayViewMainItem* ea_main_item = EA_DAY_VIEW_MAIN_ITEM (table);
 	const gchar *description;
 	EaCellTable *cell_data;
@@ -1095,9 +1093,6 @@ table_interface_get_row_description (Atk
 	g_obj = atk_gobject_accessible_get_object (atk_gobj);
 	if (!g_obj)
 		return NULL;
-
-	main_item = E_DAY_VIEW_MAIN_ITEM (g_obj);
-	day_view = main_item->day_view;
 
 	if (row < 0 || row >= 12 * 24)
 		return NULL;
Index: calendar/ea-week-view-main-item.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/calendar/ea-week-view-main-item.c,v
retrieving revision 1.3
diff -u -p -r1.3 ea-week-view-main-item.c
--- calendar/ea-week-view-main-item.c	25 Apr 2005 09:23:53 -0000	1.3
+++ calendar/ea-week-view-main-item.c	10 Dec 2005 17:07:33 -0000
@@ -491,8 +491,6 @@ ea_week_view_main_item_get_row_at_index 
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EWeekViewMainItem *main_item;
-	EWeekView *week_view;
 	gint n_children;
 
 	g_return_val_if_fail (ea_main_item, -1);
@@ -502,9 +500,6 @@ ea_week_view_main_item_get_row_at_index 
 	if (!g_obj)
 		return -1;
 
-	main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
-	week_view = main_item->week_view;
-
 	n_children = ea_week_view_main_item_get_n_children (ATK_OBJECT (ea_main_item));
 	if (index >= 0 && index < n_children)
 		return index / 7;
@@ -517,8 +512,6 @@ ea_week_view_main_item_get_column_at_ind
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EWeekViewMainItem *main_item;
-	EWeekView *week_view;
 	gint n_children;
 
 	g_return_val_if_fail (ea_main_item, -1);
@@ -528,9 +521,6 @@ ea_week_view_main_item_get_column_at_ind
 	if (!g_obj)
 		return -1;
 
-	main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
-	week_view = main_item->week_view;
-
 	n_children = ea_week_view_main_item_get_n_children (ATK_OBJECT (ea_main_item));
 	if (index >= 0 && index < n_children)
 		return index % 7;
@@ -543,8 +533,6 @@ ea_week_view_main_item_get_row_label (Ea
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EWeekViewMainItem *main_item;
-	EWeekView *week_view;
 
 	g_return_val_if_fail (ea_main_item, 0);
 
@@ -553,9 +541,6 @@ ea_week_view_main_item_get_row_label (Ea
 	if (!g_obj)
 		return 0 ;
 
-	main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
-	week_view = main_item->week_view;
-
 	return g_snprintf (buffer, buffer_size, "the %i week",
 			   row + 1);
 
@@ -715,8 +700,6 @@ table_interface_get_n_columns (AtkTable 
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EWeekViewMainItem *main_item;
-	EWeekView *week_view;
 	EaWeekViewMainItem* ea_main_item = EA_WEEK_VIEW_MAIN_ITEM (table);
 
 	atk_gobj = ATK_GOBJECT_ACCESSIBLE (ea_main_item);
@@ -724,9 +707,6 @@ table_interface_get_n_columns (AtkTable 
 	if (!g_obj)
 		return -1;
 
-	main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
-	week_view = main_item->week_view;
-
 	return 7;
 }
 
@@ -1037,8 +1017,6 @@ table_interface_get_column_description (
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	EWeekViewMainItem *main_item;
-	EWeekView *week_view;
 	EaWeekViewMainItem* ea_main_item = EA_WEEK_VIEW_MAIN_ITEM (table);
 	const gchar *description;
 	EaCellTable *cell_data;
@@ -1047,9 +1025,6 @@ table_interface_get_column_description (
 	g_obj = atk_gobject_accessible_get_object (atk_gobj);
 	if (!g_obj)
 		return NULL;
-
-	main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
-	week_view = main_item->week_view;
 
 	if (in_col < 0 || in_col > 6)
 		return NULL;
Index: e-table/gal-a11y-e-table-item.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/e-table/gal-a11y-e-table-item.c,v
retrieving revision 1.23
diff -u -p -r1.23 gal-a11y-e-table-item.c
--- e-table/gal-a11y-e-table-item.c	17 Aug 2005 06:35:20 -0000	1.23
+++ e-table/gal-a11y-e-table-item.c	10 Dec 2005 17:07:34 -0000
@@ -1002,7 +1002,6 @@ gal_a11y_e_table_item_new (ETableItem *i
 {
 	GalA11yETableItem *a11y;
 	AtkObject *accessible;
-	int n;
 	ESelectionModel * esm;
 	AtkObject *parent;
 	const char *name;
@@ -1024,7 +1023,6 @@ gal_a11y_e_table_item_new (ETableItem *i
 	accessible  = ATK_OBJECT(a11y);
 
 	/* Initialize cell data. */
-	n = item->cols * item->rows;
 	GET_PRIVATE (a11y)->cols = item->cols;
 	GET_PRIVATE (a11y)->rows = item->rows;
 
Index: e-table/gal-a11y-e-table.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/e-table/gal-a11y-e-table.c,v
retrieving revision 1.7
diff -u -p -r1.7 gal-a11y-e-table.c
--- e-table/gal-a11y-e-table.c	17 Jun 2005 15:20:24 -0000	1.7
+++ e-table/gal-a11y-e-table.c	10 Dec 2005 17:07:34 -0000
@@ -162,7 +162,6 @@ et_ref_child (AtkObject *accessible,
 			}
 		}
 	} else if (i == child_no -1) {
-        	AtkObject * accessible;
 		ETableClickToAdd * etcta;
 
 		if (et && et->use_click_to_add && et->click_to_add) {
Index: e-table/gal-a11y-e-tree.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/e-table/gal-a11y-e-tree.c,v
retrieving revision 1.8
diff -u -p -r1.8 gal-a11y-e-tree.c
--- e-table/gal-a11y-e-tree.c	17 Jun 2005 15:20:24 -0000	1.8
+++ e-table/gal-a11y-e-tree.c	10 Dec 2005 17:07:34 -0000
@@ -155,9 +155,6 @@ AtkObject *
 gal_a11y_e_tree_new (GObject *widget)
 {
 	GalA11yETree *a11y;
-	ETree *tree;
-
-	tree = E_TREE (widget);
 
 	a11y = g_object_new (gal_a11y_e_tree_get_type (), NULL);
 
Index: e-text/gal-a11y-e-text.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/e-text/gal-a11y-e-text.c,v
retrieving revision 1.10
diff -u -p -r1.10 gal-a11y-e-text.c
--- e-text/gal-a11y-e-text.c	17 Jun 2005 15:20:24 -0000	1.10
+++ e-text/gal-a11y-e-text.c	10 Dec 2005 17:07:34 -0000
@@ -766,14 +766,12 @@ et_set_selection (AtkText *text,
 		  gint end_offset)
 {
 	GObject *obj;
-	EText *etext;
 
 	g_return_val_if_fail (ATK_IS_GOBJECT_ACCESSIBLE (text), FALSE);
 	obj = atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (text));
 	if (obj == NULL)
 		return FALSE;
 	g_return_val_if_fail (E_IS_TEXT (obj), FALSE);
-	etext = E_TEXT (obj);
 	if (selection_num == 0)
                 return et_add_selection (text, start_offset, end_offset);
         return FALSE;
@@ -1015,7 +1013,6 @@ static void
 et_real_initialize (AtkObject *obj,
                     gpointer  data)
 {
-	GalA11yEText *a11y;
 	EText *etext;
 
 	ATK_OBJECT_CLASS (parent_class)->initialize (obj, data);
@@ -1023,7 +1020,6 @@ et_real_initialize (AtkObject *obj,
 	g_return_if_fail (GAL_A11Y_IS_E_TEXT (obj));
 	g_return_if_fail (E_IS_TEXT (data));
 
-	a11y = GAL_A11Y_E_TEXT (obj);
 	etext = E_TEXT (data);
 
 	/* Set up signal callbacks */
Index: widgets/ea-calendar-item.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/widgets/ea-calendar-item.c,v
retrieving revision 1.8
diff -u -p -r1.8 ea-calendar-item.c
--- widgets/ea-calendar-item.c	17 Jun 2005 15:20:24 -0000	1.8
+++ widgets/ea-calendar-item.c	10 Dec 2005 17:07:35 -0000
@@ -786,7 +786,6 @@ table_interface_get_column_description (
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	ECalendarItem *calitem;
 	EaCalendarItem* ea_calitem = EA_CALENDAR_ITEM (table);
 	const gchar *description = NULL;
 	EaCellTable *cell_data;
@@ -797,7 +796,6 @@ table_interface_get_column_description (
 	if (!g_obj)
 		return NULL;
 
-	calitem = E_CALENDAR_ITEM (g_obj);
 	n_columns = table_interface_get_n_columns (table);
 	if (in_col < 0 || in_col >= n_columns)
 		return NULL;
@@ -822,7 +820,6 @@ table_interface_get_row_description (Atk
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	ECalendarItem *calitem;
 	EaCalendarItem* ea_calitem = EA_CALENDAR_ITEM (table);
 	const gchar *description = NULL;
 	EaCellTable *cell_data;
@@ -833,7 +830,6 @@ table_interface_get_row_description (Atk
 	if (!g_obj)
 		return NULL;
 
-	calitem = E_CALENDAR_ITEM (g_obj);
 	n_rows = table_interface_get_n_rows (table);
 	if (row < 0 || row >= n_rows)
 		return NULL;
@@ -972,7 +968,6 @@ selection_interface_is_child_selected (A
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	ECalendarItem *calitem;
 	EaCalendarItem* ea_calitem = EA_CALENDAR_ITEM (selection);
 	gint row, column, n_children;
 
@@ -981,7 +976,6 @@ selection_interface_is_child_selected (A
 	if (!g_obj)
 		return FALSE;
 
-	calitem = E_CALENDAR_ITEM (g_obj);
 	n_children = atk_object_get_n_accessible_children (ATK_OBJECT (selection));
 	if (index < 0 || index >= n_children)
 		return FALSE;
@@ -1042,7 +1036,6 @@ ea_calendar_item_get_cell_data (EaCalend
 {
 	AtkGObjectAccessible *atk_gobj;
 	GObject *g_obj;
-	ECalendarItem *calitem;
 	EaCellTable *cell_data;
 
 	g_return_val_if_fail (ea_calitem, NULL);
@@ -1051,8 +1044,6 @@ ea_calendar_item_get_cell_data (EaCalend
 	g_obj = atk_gobject_accessible_get_object (atk_gobj);
 	if (!g_obj)
 		return NULL;
-
-	calitem = E_CALENDAR_ITEM (g_obj);
 
 	cell_data = g_object_get_data (G_OBJECT(ea_calitem),
 				       "ea-calendar-cell-table");
Index: widgets/ea-widgets.c
===================================================================
RCS file: /cvs/gnome/evolution/a11y/widgets/ea-widgets.c,v
retrieving revision 1.3
diff -u -p -r1.3 ea-widgets.c
--- widgets/ea-widgets.c	4 Jan 2005 07:40:37 -0000	1.3
+++ widgets/ea-widgets.c	10 Dec 2005 17:07:35 -0000
@@ -28,8 +28,8 @@
 #include "widgets/ea-combo-button.h"
 #include "ea-widgets.h"
 
-EA_FACTORY_GOBJECT (EA_TYPE_CALENDAR_ITEM, ea_calendar_item, ea_calendar_item_new);
-EA_FACTORY (EA_TYPE_COMBO_BUTTON, ea_combo_button, ea_combo_button_new);
+EA_FACTORY_GOBJECT (EA_TYPE_CALENDAR_ITEM, ea_calendar_item, ea_calendar_item_new)
+EA_FACTORY (EA_TYPE_COMBO_BUTTON, ea_combo_button, ea_combo_button_new)
 
 void e_calendar_item_a11y_init (void)
 {




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]