From 6d23f46e64152fa219b5ad8a5455996b36e9c6db Mon Sep 17 00:00:00 2001 From: Xavier Claessens Date: Thu, 1 May 2008 22:02:48 +0000 Subject: Keypad is unsensitive if the call is not ACCEPTED svn path=/trunk/; revision=1072 --- libempathy/empathy-tp-call.c | 4 +- src/empathy-call-window.c | 5 ++ src/empathy-call-window.glade | 106 +++++++++++++++++++++--------------------- 3 files changed, 60 insertions(+), 55 deletions(-) diff --git a/libempathy/empathy-tp-call.c b/libempathy/empathy-tp-call.c index 32debb8b3..c5e977d1c 100644 --- a/libempathy/empathy-tp-call.c +++ b/libempathy/empathy-tp-call.c @@ -817,7 +817,7 @@ empathy_tp_call_start_tone (EmpathyTpCall *call, TpDTMFEvent event) EmpathyTpCallPriv *priv = GET_PRIV (call); g_return_if_fail (EMPATHY_IS_TP_CALL (call)); - g_return_if_fail (priv->status != EMPATHY_TP_CALL_STATUS_ACCEPTED); + g_return_if_fail (priv->status == EMPATHY_TP_CALL_STATUS_ACCEPTED); if (!priv->audio->exists) return; @@ -834,7 +834,7 @@ empathy_tp_call_stop_tone (EmpathyTpCall *call) EmpathyTpCallPriv *priv = GET_PRIV (call); g_return_if_fail (EMPATHY_IS_TP_CALL (call)); - g_return_if_fail (priv->status != EMPATHY_TP_CALL_STATUS_ACCEPTED); + g_return_if_fail (priv->status == EMPATHY_TP_CALL_STATUS_ACCEPTED); if (!priv->audio->exists) return; diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c index cddb11433..2d52fcf7c 100644 --- a/src/empathy-call-window.c +++ b/src/empathy-call-window.c @@ -58,6 +58,7 @@ typedef struct GtkWidget *video_button; GtkWidget *hang_up_button; GtkWidget *confirmation_dialog; + GtkWidget *keypad_expander; } EmpathyCallWindow; static gboolean @@ -140,6 +141,7 @@ call_window_finalize (EmpathyCallWindow *window) gtk_widget_set_sensitive (window->video_button, FALSE); gtk_widget_set_sensitive (window->output_volume_button, FALSE); gtk_widget_set_sensitive (window->input_volume_button, FALSE); + gtk_widget_set_sensitive (window->keypad_expander, FALSE); if (window->call) { @@ -365,6 +367,7 @@ call_window_update (EmpathyCallWindow *window) gtk_widget_set_sensitive (window->output_volume_button, FALSE); gtk_widget_set_sensitive (window->input_volume_button, FALSE); gtk_widget_set_sensitive (window->hang_up_button, FALSE); + gtk_widget_set_sensitive (window->keypad_expander, FALSE); } else if (window->status == EMPATHY_TP_CALL_STATUS_PENDING) { @@ -410,6 +413,7 @@ call_window_update (EmpathyCallWindow *window) gtk_widget_set_sensitive (window->output_volume_button, TRUE); gtk_widget_set_sensitive (window->input_volume_button, TRUE); gtk_widget_set_sensitive (window->hang_up_button, TRUE); + gtk_widget_set_sensitive (window->keypad_expander, TRUE); } else if (window->status == EMPATHY_TP_CALL_STATUS_CLOSED) call_window_finalize (window); @@ -480,6 +484,7 @@ empathy_call_window_new (EmpathyTpCall *call) "status_label", &window->status_label, "video_button", &window->video_button, "hang_up_button", &window->hang_up_button, + "keypad_expander", &window->keypad_expander, NULL); g_free (filename); diff --git a/src/empathy-call-window.glade b/src/empathy-call-window.glade index 8e62c6c32..684aed3ce 100644 --- a/src/empathy-call-window.glade +++ b/src/empathy-call-window.glade @@ -1,6 +1,6 @@ - + @@ -62,190 +62,190 @@ - + True True - + True 4 3 True - + True True - # + 1 True 0 - 2 - 3 - 3 - 4 - + True True - 0 + 2 True 0 1 2 - 3 - 4 - + True True - * + 3 True 0 - 3 - 4 + 2 + 3 - + True True - 9 + 4 True 0 - 2 - 3 - 2 - 3 + 1 + 2 - + True True - 8 + 5 True 0 1 2 - 2 - 3 + 1 + 2 - + True True - 7 + 6 True 0 - 2 - 3 + 2 + 3 + 1 + 2 - + True True - 6 + 7 True 0 - 2 - 3 - 1 - 2 + 2 + 3 - + True True - 5 + 8 True 0 1 2 - 1 - 2 + 2 + 3 - + True True - 4 + 9 True 0 - 1 - 2 + 2 + 3 + 2 + 3 - + True True - 3 + * True 0 - 2 - 3 + 3 + 4 - + True True - 2 + 0 True 0 1 2 + 3 + 4 - + True True - 1 + # True 0 + 2 + 3 + 3 + 4 -- cgit v1.2.3