aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-day-view.c
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@helixcode.com>2000-06-03 10:28:34 +0800
committerFederico Mena Quintero <federico@src.gnome.org>2000-06-03 10:28:34 +0800
commit6ec291cbc6660e1732543bcfc20885c7020cb8ed (patch)
treeae96a9e80e9f2f1e24ca0adaa55be3fc95c45c3f /calendar/gui/e-day-view.c
parent31642359471574aad4a8427a18692d2558c91c5c (diff)
downloadgsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar.gz
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar.bz2
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar.lz
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar.xz
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.tar.zst
gsoc2013-evolution-6ec291cbc6660e1732543bcfc20885c7020cb8ed.zip
New function to call the print engine. (calendar_toolbar): Added the Print
2000-06-02 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-commands.c (print): New function to call the print engine. (calendar_toolbar): Added the Print button. (calendar_control_activate): Added the File/Print item. * gui/e-day-view.c (e_day_view_get_selected_time_range): Allow start_time and end_time to be NULL. * gui/e-week-view.c (e_week_view_get_selected_time_range): Likewise. * gui/print.c (range_selector_new): Show the range selector widgets. Use the correct radio group for all of them! (print_calendar): Do the dialog box here. We may want to split this function later into smaller chunks. svn path=/trunk/; revision=3409
Diffstat (limited to 'calendar/gui/e-day-view.c')
-rw-r--r--calendar/gui/e-day-view.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c
index 66fd908afd..891c378816 100644
--- a/calendar/gui/e-day-view.c
+++ b/calendar/gui/e-day-view.c
@@ -1566,6 +1566,7 @@ e_day_view_get_selected_time_range (EDayView *day_view,
time_t *end_time)
{
gint start_col, start_row, end_col, end_row;
+ time_t start, end;
start_col = day_view->selection_start_day;
start_row = day_view->selection_start_row;
@@ -1582,13 +1583,19 @@ e_day_view_get_selected_time_range (EDayView *day_view,
/* Check if the selection is only in the top canvas, in which case
we can simply use the day_starts array. */
if (day_view->selection_in_top_canvas) {
- *start_time = day_view->day_starts[start_col];
- *end_time = day_view->day_starts[end_col + 1];
+ start = day_view->day_starts[start_col];
+ end = day_view->day_starts[end_col + 1];
} else {
/* Convert the start col + row into a time. */
- *start_time = e_day_view_convert_grid_position_to_time (day_view, start_col, start_row);
- *end_time = e_day_view_convert_grid_position_to_time (day_view, end_col, end_row + 1);
+ start = e_day_view_convert_grid_position_to_time (day_view, start_col, start_row);
+ end = e_day_view_convert_grid_position_to_time (day_view, end_col, end_row + 1);
}
+
+ if (start_time)
+ *start_time = start;
+
+ if (end_time)
+ *end_time = end;
}