[evolution-patches] patch for bug #207071 [Calendar]



Hi,

Attached patch fixes bug 
http://bugzilla.gnome.org/show_bug.cgi?id=207071



Thanks,
Viren
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/calendar/ChangeLog,v
retrieving revision 1.2808
diff -u -p -r1.2808 ChangeLog
--- ChangeLog	29 Sep 2005 13:02:55 -0000	1.2808
+++ ChangeLog	1 Oct 2005 13:48:37 -0000
@@ -1,3 +1,10 @@
+2005-10-01  Viren.L  <lviren novell com>
+	Fixes #207071
+
+	* gui/e-week-view.c (e_week_view_do_key_press), (e_week_view_scroll_a_step):
+	Handled PageUp & PageDown cases and compute new value for
+	adjustment using the current page size value.	
+
 2005-08-29  Chenthill Palanisamy  <pchenthill novell com>
 
 	* gui/e-calendar-table.c (e_calendar_table_open_task): Set the 
Index: gui/e-week-view.c
===================================================================
RCS file: /cvs/gnome/evolution/calendar/gui/e-week-view.c,v
retrieving revision 1.248
diff -u -p -r1.248 e-week-view.c
--- gui/e-week-view.c	24 Aug 2005 03:07:49 -0000	1.248
+++ gui/e-week-view.c	1 Oct 2005 13:48:38 -0000
@@ -2166,10 +2166,8 @@ e_week_view_on_scroll (GtkWidget *widget
 	default:
 		return FALSE;
 	}
-	
 	new_value = CLAMP (new_value, adj->lower, adj->upper - adj->page_size);
 	gtk_adjustment_set_value (adj, new_value);
-	
 	return TRUE;
 }
 
@@ -3169,10 +3167,15 @@ e_week_view_scroll_a_step (EWeekView *we
 	case E_CAL_VIEW_MOVE_DOWN:
 		new_value = adj->value + adj->step_increment;
 		break;
+	case E_CAL_VIEW_MOVE_PAGE_UP:
+		new_value = adj->value - adj->page_size;
+		break;
+	case E_CAL_VIEW_MOVE_PAGE_DOWN:
+		new_value = adj->value + adj->page_size;
+		break;
 	default:
 		return;
 	}
-	
 	new_value = CLAMP (new_value, adj->lower, adj->upper - adj->page_size);
 	gtk_adjustment_set_value (adj, new_value);
 }
@@ -3735,6 +3738,18 @@ e_week_view_do_key_press (GtkWidget *wid
 		&& !(event->state & GDK_MOD1_MASK)) {
 		stop_emission = TRUE;
 		switch (keyval) {
+		case GDK_Page_Up:
+			if (!week_view->multi_week_view)
+				e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_UP);
+			else 
+				e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_PAGE_UP);
+			break;
+		case GDK_Page_Down:
+			if (!week_view->multi_week_view)
+				e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_DOWN);
+			else 
+				e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_PAGE_DOWN);
+			break;	
 		case GDK_Up:
 			e_week_view_cursor_key_up (week_view, view_type);
 			break;


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