diff options
author | JP Rosevear <jpr@ximian.com> | 2002-09-12 04:34:48 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2002-09-12 04:34:48 +0800 |
commit | 5ee24ecb73357537623089e04bc38423c8ec3351 (patch) | |
tree | 6110c9cb76355a8bb233ffc64494eb26fdaf11d7 /calendar/gui/e-day-view.c | |
parent | 75455ef4a1650dddfec7b0ac79ec6584f51cc6f8 (diff) | |
download | gsoc2013-evolution-5ee24ecb73357537623089e04bc38423c8ec3351.tar.gz gsoc2013-evolution-5ee24ecb73357537623089e04bc38423c8ec3351.tar.zst gsoc2013-evolution-5ee24ecb73357537623089e04bc38423c8ec3351.zip |
keep the selection if we right click in it (but not on an appointment)
2002-09-11 JP Rosevear <jpr@ximian.com>
* gui/e-day-view.c (e_day_view_on_top_canvas_button_press): keep
the selection if we right click in it (but not on an appointment)
(e_day_view_on_main_canvas_button_press): ditto
* gui/e-week-view.c (e_week_view_on_button_press): sam
svn path=/trunk/; revision=18046
Diffstat (limited to 'calendar/gui/e-day-view.c')
-rw-r--r-- | calendar/gui/e-day-view.c | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c index 31b71e473c..7a91699185 100644 --- a/calendar/gui/e-day-view.c +++ b/calendar/gui/e-day-view.c @@ -2295,7 +2295,7 @@ e_day_view_set_selected_time_range_in_top_visible (EDayView *day_view, start_col = 0; if (!end_in_grid) end_col = day_view->days_shown - 1; - + if (start_row != day_view->selection_start_row || start_col != day_view->selection_start_day) { need_redraw = TRUE; @@ -3091,9 +3091,11 @@ e_day_view_on_top_canvas_button_press (GtkWidget *widget, if (!GTK_WIDGET_HAS_FOCUS (day_view)) gtk_widget_grab_focus (GTK_WIDGET (day_view)); - e_day_view_start_selection (day_view, day, -1); - e_day_view_finish_selection (day_view); - + if (day < day_view->selection_start_day || day > day_view->selection_end_day) { + e_day_view_start_selection (day_view, day, -1); + e_day_view_finish_selection (day_view); + } + e_day_view_on_event_right_click (day_view, event, -1, -1); } @@ -3228,9 +3230,14 @@ e_day_view_on_main_canvas_button_press (GtkWidget *widget, if (!GTK_WIDGET_HAS_FOCUS (day_view)) gtk_widget_grab_focus (GTK_WIDGET (day_view)); - e_day_view_start_selection (day_view, day, row); - e_day_view_finish_selection (day_view); - + + if ((day < day_view->selection_start_day || day > day_view->selection_end_day) + || (day == day_view->selection_start_day && row < day_view->selection_start_row) + || (day == day_view->selection_end_day && row > day_view->selection_end_row)) { + e_day_view_start_selection (day_view, day, row); + e_day_view_finish_selection (day_view); + } + e_day_view_on_event_right_click (day_view, event, -1, -1); } |