GtkWidget *vbox;
gulong video_output_motion_handler_id;
+ guint bus_message_source_id;
gdouble volume;
GtkWidget *volume_scale;
priv->pipeline = gst_pipeline_new (NULL);
bus = gst_pipeline_get_bus (GST_PIPELINE (priv->pipeline));
- gst_bus_add_watch (bus, empathy_call_window_bus_message, self);
+ priv->bus_message_source_id = gst_bus_add_watch (bus,
+ empathy_call_window_bus_message, self);
priv->fsnotifier = fs_element_added_notifier_new ();
fs_element_added_notifier_add (priv->fsnotifier, GST_BIN (priv->pipeline));
EmpathyCallWindowPriv *priv = GET_PRIV (self);
gchar *tmp;
+ /* translators: Call is a noun and %s is the contact name. This string is used
+ * in the window title */
tmp = g_strdup_printf (_("Call with %s"),
empathy_contact_get_name (priv->contact));
gtk_window_set_title (GTK_WINDOW (self), tmp);
else
{
g_warning ("call handler doesn't have a contact");
+ /* translators: Call is a noun. This string is used in the window title */
gtk_window_set_title (GTK_WINDOW (self), _("Call"));
/* Since we can't access the remote contact, we can't get a connection
if (priv->handler != NULL)
g_object_unref (priv->handler);
-
priv->handler = NULL;
if (priv->pipeline != NULL)
priv->video_output_motion_handler_id = 0;
}
+ if (priv->bus_message_source_id != 0)
+ {
+ g_source_remove (priv->bus_message_source_id);
+ priv->bus_message_source_id = 0;
+ }
+
/* free any data held directly by the object here */
g_mutex_free (priv->lock);
if (priv->pipeline == NULL)
return TRUE;
+ if (priv->bus_message_source_id != 0)
+ {
+ g_source_remove (priv->bus_message_source_id);
+ priv->bus_message_source_id = 0;
+ }
+
state_change_return = gst_element_set_state (priv->pipeline, GST_STATE_NULL);
if (state_change_return == GST_STATE_CHANGE_SUCCESS ||
EmpathyCallWindowPriv *priv = GET_PRIV (window);
if (priv->pipeline != NULL)
- gst_element_set_state (priv->pipeline, GST_STATE_NULL);
+ {
+ if (priv->bus_message_source_id != 0)
+ {
+ g_source_remove (priv->bus_message_source_id);
+ priv->bus_message_source_id = 0;
+ }
+
+ gst_element_set_state (priv->pipeline, GST_STATE_NULL);
+ }
if (priv->call_state == CONNECTING)
empathy_sound_stop (EMPATHY_SOUND_PHONE_OUTGOING);
priv->pipeline = gst_pipeline_new (NULL);
bus = gst_pipeline_get_bus (GST_PIPELINE (priv->pipeline));
- gst_bus_add_watch (bus, empathy_call_window_bus_message, window);
+ priv->bus_message_source_id = gst_bus_add_watch (bus,
+ empathy_call_window_bus_message, window);
empathy_call_window_setup_remote_frame (bus, window);
empathy_call_window_setup_self_frame (bus, window);