From 3546af6b2b14fa640c1a86e6a975eef6fcb37a00 Mon Sep 17 00:00:00 2001 From: Sjoerd Simons Date: Wed, 15 Jul 2009 15:24:48 +0100 Subject: Remove last references to mission-control 4 --- src/empathy-accounts-dialog.c | 3 -- src/empathy-debug-dialog.c | 4 --- src/empathy-event-manager.c | 1 + src/empathy-main-window.c | 3 -- src/empathy-tube-dispatch.c | 1 + src/empathy.c | 76 ++----------------------------------------- 6 files changed, 4 insertions(+), 84 deletions(-) (limited to 'src') diff --git a/src/empathy-accounts-dialog.c b/src/empathy-accounts-dialog.c index bfb92af37..080a6cae3 100644 --- a/src/empathy-accounts-dialog.c +++ b/src/empathy-accounts-dialog.c @@ -85,7 +85,6 @@ typedef struct { guint connecting_id; EmpathyAccountManager *account_manager; - MissionControl *mc; } EmpathyAccountsDialog; enum { @@ -1030,7 +1029,6 @@ accounts_dialog_destroy_cb (GtkWidget *widget, } g_object_unref (dialog->account_manager); - g_object_unref (dialog->mc); g_free (dialog); } @@ -1104,7 +1102,6 @@ empathy_accounts_dialog_show (GtkWindow *parent, /* Set up signalling */ dialog->account_manager = empathy_account_manager_dup_singleton (); - dialog->mc = empathy_mission_control_dup_singleton (); g_signal_connect (dialog->account_manager, "account-created", G_CALLBACK (accounts_dialog_account_added_cb), diff --git a/src/empathy-debug-dialog.c b/src/empathy-debug-dialog.c index cd0d925f9..9b420fd02 100644 --- a/src/empathy-debug-dialog.c +++ b/src/empathy-debug-dialog.c @@ -284,7 +284,6 @@ debug_dialog_cm_chooser_changed_cb (GtkComboBox *cm_chooser, EmpathyDebugDialog *debug_dialog) { EmpathyDebugDialogPriv *priv = GET_PRIV (debug_dialog); - MissionControl *mc; TpDBusDaemon *dbus; GError *error = NULL; gchar *bus_name; @@ -302,13 +301,11 @@ debug_dialog_cm_chooser_changed_cb (GtkComboBox *cm_chooser, return; } - mc = empathy_mission_control_dup_singleton (); dbus = tp_dbus_daemon_dup (&error); if (error != NULL) { DEBUG ("Failed at duping the dbus daemon: %s", error->message); - g_object_unref (mc); } gtk_tree_model_get (GTK_TREE_MODEL (priv->cms), &iter, @@ -344,7 +341,6 @@ debug_dialog_cm_chooser_changed_cb (GtkComboBox *cm_chooser, debug_dialog_get_messages_cb, debug_dialog, NULL, NULL); g_object_unref (dbus); - g_object_unref (mc); } typedef struct diff --git a/src/empathy-event-manager.c b/src/empathy-event-manager.c index 1a7ec09cb..1be3ff7ce 100644 --- a/src/empathy-event-manager.c +++ b/src/empathy-event-manager.c @@ -25,6 +25,7 @@ #include #include +#include #include #include diff --git a/src/empathy-main-window.c b/src/empathy-main-window.c index 0d04153a3..05eb0774e 100644 --- a/src/empathy-main-window.c +++ b/src/empathy-main-window.c @@ -79,7 +79,6 @@ typedef struct { EmpathyContactListView *list_view; EmpathyContactListStore *list_store; - MissionControl *mc; EmpathyAccountManager *account_manager; EmpathyChatroomManager *chatroom_manager; EmpathyEventManager *event_manager; @@ -646,7 +645,6 @@ main_window_destroy_cb (GtkWidget *widget, g_list_free (window->actions_connected); - g_object_unref (window->mc); g_object_unref (window->account_manager); g_object_unref (window->list_store); g_hash_table_destroy (window->errors); @@ -1175,7 +1173,6 @@ empathy_main_window_show (void) gtk_action_set_visible (show_map_widget, FALSE); #endif - window->mc = empathy_mission_control_dup_singleton (); window->account_manager = empathy_account_manager_dup_singleton (); g_signal_connect (window->account_manager, diff --git a/src/empathy-tube-dispatch.c b/src/empathy-tube-dispatch.c index 67db5a3a3..66efa217d 100644 --- a/src/empathy-tube-dispatch.c +++ b/src/empathy-tube-dispatch.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include diff --git a/src/empathy.c b/src/empathy.c index 6439eecfa..5e3d983aa 100644 --- a/src/empathy.c +++ b/src/empathy.c @@ -41,6 +41,7 @@ #include #include #include +#include #include #include @@ -145,68 +146,6 @@ dispatch_cb (EmpathyDispatcher *dispatcher, } } -static void -service_ended_cb (MissionControl *mc, - gpointer user_data) -{ - DEBUG ("Mission Control stopped"); -} - -static void -operation_error_cb (MissionControl *mc, - guint operation_id, - guint error_code, - gpointer user_data) -{ - const gchar *message; - - switch (error_code) { - case MC_DISCONNECTED_ERROR: - message = "Disconnected"; - break; - case MC_INVALID_HANDLE_ERROR: - message = "Invalid handle"; - break; - case MC_NO_MATCHING_CONNECTION_ERROR: - message = "No matching connection"; - break; - case MC_INVALID_ACCOUNT_ERROR: - message = "Invalid account"; - break; - case MC_PRESENCE_FAILURE_ERROR: - message = "Presence failure"; - break; - case MC_NO_ACCOUNTS_ERROR: - message = "No accounts"; - break; - case MC_NETWORK_ERROR: - message = "Network error"; - break; - case MC_CONTACT_DOES_NOT_SUPPORT_VOICE_ERROR: - message = "Contact does not support voice"; - break; - case MC_LOWMEM_ERROR: - message = "Lowmem"; - break; - case MC_CHANNEL_REQUEST_GENERIC_ERROR: - message = "Channel request generic error"; - break; - case MC_CHANNEL_BANNED_ERROR: - message = "Channel banned"; - break; - case MC_CHANNEL_FULL_ERROR: - message = "Channel full"; - break; - case MC_CHANNEL_INVITE_ONLY_ERROR: - message = "Channel invite only"; - break; - default: - message = "Unknown error code"; - } - - DEBUG ("Error during operation %d: %s", operation_id, message); -} - static void use_nm_notify_cb (EmpathyConf *conf, const gchar *key, @@ -529,7 +468,6 @@ main (int argc, char *argv[]) EmpathyCallFactory *call_factory; EmpathyFTFactory *ft_factory; GtkWidget *window; - MissionControl *mc; EmpathyIdle *idle; gboolean autoconnect = TRUE; gboolean no_connect = FALSE; @@ -636,15 +574,6 @@ main (int argc, char *argv[]) g_clear_error (&error); } - /* Setting up MC */ - mc = empathy_mission_control_dup_singleton (); - g_signal_connect (mc, "ServiceEnded", - G_CALLBACK (service_ended_cb), - NULL); - g_signal_connect (mc, "Error", - G_CALLBACK (operation_error_cb), - NULL); - if (accounts_dialog) { GtkWidget *dialog; @@ -671,7 +600,7 @@ main (int argc, char *argv[]) if (autoconnect && ! no_connect && tp_connection_presence_type_cmp_availability (empathy_idle_get_state (idle), TP_CONNECTION_PRESENCE_TYPE_OFFLINE) <= 0) { - empathy_idle_set_state (idle, MC_PRESENCE_AVAILABLE); + empathy_idle_set_state (idle, TP_CONNECTION_PRESENCE_TYPE_AVAILABLE); } /* account management */ @@ -722,7 +651,6 @@ main (int argc, char *argv[]) empathy_idle_set_state (idle, TP_CONNECTION_PRESENCE_TYPE_OFFLINE); - g_object_unref (mc); g_object_unref (idle); g_object_unref (icon); g_object_unref (account_manager); -- cgit v1.2.3