diff options
-rw-r--r-- | widgets/ChangeLog | 5 | ||||
-rw-r--r-- | widgets/misc/e-dateedit.c | 22 |
2 files changed, 27 insertions, 0 deletions
diff --git a/widgets/ChangeLog b/widgets/ChangeLog index 09fe5ea3eb..b05102092c 100644 --- a/widgets/ChangeLog +++ b/widgets/ChangeLog @@ -1,3 +1,8 @@ +2005-05-12 Srinivasa Ragavan <sragavan@novell.com> + * misc/e-dateedit.c: (on_time_entry_key_release), + (create_children): Fix the bug 303856. Enables OK button + when arrow key used to change the time in a appointment. + 2005-05-06 Sarfraaz Ahmed <asarfraaz@novell.com> * misc/e-search-bar.c: (set_menu) Solaris gettext crashes on NULL diff --git a/widgets/misc/e-dateedit.c b/widgets/misc/e-dateedit.c index 58962c2cb7..b27d1778c6 100644 --- a/widgets/misc/e-dateedit.c +++ b/widgets/misc/e-dateedit.c @@ -181,6 +181,9 @@ static void on_date_edit_time_selected (GtkList *list, static gint on_time_entry_key_press (GtkWidget *widget, GdkEventKey *event, EDateEdit *dedit); +static gint on_time_entry_key_release (GtkWidget *widget, + GdkEventKey *event, + EDateEdit *dedit); static gint on_date_entry_focus_out (GtkEntry *entry, GdkEventFocus *event, EDateEdit *dedit); @@ -375,6 +378,10 @@ create_children (EDateEdit *dedit) "key_press_event", G_CALLBACK (on_time_entry_key_press), dedit); + g_signal_connect (GTK_COMBO (priv->time_combo)->entry, + "key_release_event", + G_CALLBACK (on_time_entry_key_release), + dedit); g_signal_connect_after (GTK_COMBO (priv->time_combo)->entry, "focus_out_event", G_CALLBACK (on_time_entry_focus_out), @@ -1577,6 +1584,21 @@ on_time_entry_key_press (GtkWidget *widget, return FALSE; } +static gint +on_time_entry_key_release (GtkWidget *widget, + GdkEventKey *event, + EDateEdit *dedit) +{ + if (event->keyval == GDK_Up || event->keyval == GDK_Down) { + g_signal_stop_emission_by_name (widget, + "key_release_event"); + e_date_edit_check_time_changed (dedit); + return TRUE; + } + + return FALSE; +} + static gint on_date_entry_focus_out (GtkEntry *entry, |