aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-week-view.c
diff options
context:
space:
mode:
authorLi Yuan <li.yuan@sun.com>2004-10-13 12:58:51 +0800
committerHarry Lu <haip@src.gnome.org>2004-10-13 12:58:51 +0800
commitcc8be7047b362cc88466d7f880f3cddbe9ecd535 (patch)
tree9e52f9346d3a08792e225920868a565e82e92a76 /calendar/gui/e-week-view.c
parent894f6a90c2d22d88c45c0226c898b16ed5110a67 (diff)
downloadgsoc2013-evolution-cc8be7047b362cc88466d7f880f3cddbe9ecd535.tar.gz
gsoc2013-evolution-cc8be7047b362cc88466d7f880f3cddbe9ecd535.tar.zst
gsoc2013-evolution-cc8be7047b362cc88466d7f880f3cddbe9ecd535.zip
If main_canvas has focus, do not grub it. Emit the selected_time_changed
2004-10-12 Li Yuan <li.yuan@sun.com> * gui/e-day-view.c: (e_day_view_on_main_canvas_button_press): * gui/e-week-view.c: (e_week_view_on_button_press): If main_canvas has focus, do not grub it. Emit the selected_time_changed signal after the selection day changed. svn path=/trunk/; revision=27563
Diffstat (limited to 'calendar/gui/e-week-view.c')
-rw-r--r--calendar/gui/e-week-view.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c
index 27d9eb28c8..bd22b7f61e 100644
--- a/calendar/gui/e-week-view.c
+++ b/calendar/gui/e-week-view.c
@@ -2144,7 +2144,7 @@ e_week_view_on_button_press (GtkWidget *widget,
if (event->button == 1) {
/* Start the selection drag. */
- if (!GTK_WIDGET_HAS_FOCUS (week_view))
+ if (!GTK_WIDGET_HAS_FOCUS (week_view) && !GTK_WIDGET_HAS_FOCUS (week_view->main_canvas))
gtk_widget_grab_focus (GTK_WIDGET (week_view));
if (gdk_pointer_grab (GTK_LAYOUT (widget)->bin_window, FALSE,
@@ -2154,6 +2154,7 @@ e_week_view_on_button_press (GtkWidget *widget,
week_view->selection_start_day = day;
week_view->selection_end_day = day;
week_view->selection_drag_pos = E_WEEK_VIEW_DRAG_END;
+ g_signal_emit_by_name (week_view, "selected_time_changed");
/* FIXME: Optimise? */
gtk_widget_queue_draw (week_view->main_canvas);