[empathy] Fixed Bug 586284 – Crasher: click on the microphone once disconnected
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: svn-commits-list gnome org
- Subject: [empathy] Fixed Bug 586284 – Crasher: click on the microphone once disconnected
- Date: Tue, 23 Jun 2009 09:57:09 -0400 (EDT)
commit 03fa531203802810a57bc723132368bf2761e19c
Author: Jonathan Tellier <jonathan tellier gmail com>
Date: Mon Jun 22 09:10:29 2009 -0400
Fixed Bug 586284 â?? Crasher: click on the microphone once disconnected
src/empathy-call-window.c | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c
index 4ad1b26..75c6abf 100644
--- a/src/empathy-call-window.c
+++ b/src/empathy-call-window.c
@@ -488,7 +488,7 @@ empathy_call_window_mic_volume_changed_cb (GtkAdjustment *adj,
priv->volume = volume;
/* Ensure that the toggle button is active if the volume is > 0 and inactive
- * if it's smaller then 0 */
+ * if it's smaller than 0 */
if ((volume > 0) != gtk_toggle_tool_button_get_active (
GTK_TOGGLE_TOOL_BUTTON (priv->mic_button)))
gtk_toggle_tool_button_set_active (
@@ -1201,13 +1201,17 @@ empathy_call_window_disconnected (EmpathyCallWindow *self)
gtk_action_set_sensitive (priv->redial, TRUE);
gtk_widget_set_sensitive (priv->redial_button, TRUE);
- /* Reseting the send_video and camera_buton to their initial state */
+ /* Reseting the send_video, camera_buton and mic_button to their
+ initial state */
gtk_widget_set_sensitive (priv->camera_button, FALSE);
+ gtk_widget_set_sensitive (priv->mic_button, FALSE);
gtk_action_set_sensitive (priv->send_video, FALSE);
gtk_toggle_action_set_active (GTK_TOGGLE_ACTION (priv->send_video),
initial_video);
gtk_toggle_tool_button_set_active (
GTK_TOGGLE_TOOL_BUTTON (priv->camera_button), initial_video);
+ gtk_toggle_tool_button_set_active (
+ GTK_TOGGLE_TOOL_BUTTON (priv->mic_button), TRUE);
gtk_toggle_action_set_active (GTK_TOGGLE_ACTION (priv->show_preview),
FALSE);
@@ -1348,6 +1352,8 @@ empathy_call_window_connected (gpointer user_data)
gtk_action_set_sensitive (priv->redial, FALSE);
gtk_widget_set_sensitive (priv->redial_button, FALSE);
+ gtk_widget_set_sensitive (priv->mic_button, TRUE);
+
empathy_call_window_update_avatars_visibility (call, self);
g_object_unref (call);
@@ -1850,6 +1856,9 @@ empathy_call_window_mic_toggled_cb (GtkToggleToolButton *toggle,
EmpathyCallWindowPriv *priv = GET_PRIV (window);
gboolean active;
+ if (priv->audio_input == NULL)
+ return;
+
active = (gtk_toggle_tool_button_get_active (toggle));
if (active)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]