[evolution-patches] [calendar] patch for bug #312533



Attached patch fixes bug#312533, the problem when all instances are
updated, for updating an individual instance, the bug is a duplicate of
318777.

Please review.


Regards,
--DL

Index: gui/e-day-view.c
===================================================================
RCS file: /cvs/gnome/evolution/calendar/gui/e-day-view.c,v
retrieving revision 1.286
diff -u -p -r1.286 e-day-view.c
--- gui/e-day-view.c	24 Aug 2005 03:07:49 -0000	1.286
+++ gui/e-day-view.c	20 Oct 2005 09:57:52 -0000
@@ -4005,7 +4005,7 @@ e_day_view_finish_resize (EDayView *day_
 	EDayViewEvent *event;
 	gint day, event_num;
 	ECalComponent *comp;
-	ECalComponentDateTime date;
+	ECalComponentDateTime prev_date, date;
 	struct icaltimetype itt;
 	time_t dt;
 	ECal *client;
@@ -4040,11 +4040,19 @@ e_day_view_finish_resize (EDayView *day_
 		dt = e_day_view_convert_grid_position_to_time (day_view, day, day_view->resize_start_row);
 		*date.value = icaltime_from_timet_with_zone (dt, FALSE,
 							     e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
+		e_cal_component_get_dtstart (comp, &prev_date);
+		date.value->year = prev_date.value->year;
+		date.value->month = prev_date.value->month;
+		date.value->day = prev_date.value->day;
 		e_cal_component_set_dtstart (comp, &date);
 	} else {
 		dt = e_day_view_convert_grid_position_to_time (day_view, day, day_view->resize_end_row + 1);
 		*date.value = icaltime_from_timet_with_zone (dt, FALSE,
 							     e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
+		e_cal_component_get_dtstart (comp, &prev_date);
+		date.value->year = prev_date.value->year;
+		date.value->month = prev_date.value->month;
+		date.value->day = prev_date.value->day;
 		e_cal_component_set_dtend (comp, &date);
 	}
 
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/calendar/ChangeLog,v
retrieving revision 1.2831
diff -u -p -r1.2831 ChangeLog
--- ChangeLog	19 Oct 2005 11:38:14 -0000	1.2831
+++ ChangeLog	20 Oct 2005 09:57:55 -0000
@@ -1,3 +1,8 @@
+2005-10-20  Dinesh Layek <LDinesh novell com>
+
+	Fixes 312533
+	* gui/e-day-view.c (e_day_view_finish_resize): set the start and end date properly
+
 2005-10-19  Harish Krishnaswamy <kharish novell com>
 
 	Committing for Nathan Owens <pianocomp81 yahoo com>


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