From 8de05ae8857fcee08bb2d7e7cbaccb9ae1585d3e Mon Sep 17 00:00:00 2001 From: Xavier Claessens Date: Fri, 13 Jun 2008 11:13:49 +0000 Subject: Do not show the keypad when the media channel does not have the DTMF interface (Alban Crequy) svn path=/trunk/; revision=1162 --- src/empathy-call-window.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src') diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c index 67a3d87a8..8a33e4639 100644 --- a/src/empathy-call-window.c +++ b/src/empathy-call-window.c @@ -340,6 +340,7 @@ call_window_update (EmpathyCallWindow *window) EmpathyTpCallStream *audio_stream; EmpathyTpCallStream *video_stream; gboolean is_incoming; + gboolean has_dtmf; gchar *title; g_object_get (window->call, @@ -348,6 +349,7 @@ call_window_update (EmpathyCallWindow *window) "video-stream", &video_stream, "contact", &contact, "is-incoming", &is_incoming, + "has-dtmf", &has_dtmf, NULL); if (video_stream->state > audio_stream->state) @@ -359,6 +361,15 @@ call_window_update (EmpathyCallWindow *window) "is-incoming: %d video-stream direction: %d", window->status, stream_state, is_incoming, video_stream->direction); + if (has_dtmf) + { + gtk_widget_show (window->keypad_expander); + } + else + { + gtk_widget_hide (window->keypad_expander); + } + /* Depending on the status we have to set: * - window's title * - status's label -- cgit v1.2.3