]> git.0d.be Git - empathy.git/commitdiff
Use TP_ERROR instead of TP_ERRORS
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Mon, 7 May 2012 09:10:17 +0000 (11:10 +0200)
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Mon, 7 May 2012 09:10:17 +0000 (11:10 +0200)
The latter has been deprecated in tp-glib master.

libempathy-gtk/empathy-chat.c
libempathy-gtk/empathy-contact-blocking-dialog.c
libempathy/empathy-tp-chat.c
libempathy/empathy-tp-contact-factory.c
src/empathy-call-factory.c
src/empathy-call-observer.c
src/empathy-event-manager.c

index 4067a3e4f649b69d1c3f2aaad86b299fd3d7fce9..b2224c2dba52489227b1aa22e6c5cc25aabf21ef 100644 (file)
@@ -3699,7 +3699,7 @@ provide_password_cb (GObject *tp_chat,
                DEBUG ("error: %s", error->message);
                /* FIXME: what should we do if that's another error? Close the channel?
                 * Display the raw D-Bus error to the user isn't very useful */
-               if (g_error_matches (error, TP_ERRORS, TP_ERROR_AUTHENTICATION_FAILED)) {
+               if (g_error_matches (error, TP_ERROR, TP_ERROR_AUTHENTICATION_FAILED)) {
                        /* entry */
                        gtk_entry_set_text (GTK_ENTRY (data->entry), "");
                        gtk_widget_set_sensitive (data->entry, TRUE);
@@ -3926,7 +3926,7 @@ provide_saved_password_cb (GObject *tp_chat,
                DEBUG ("error: %s", error->message);
                /* FIXME: what should we do if that's another error? Close the channel?
                 * Display the raw D-Bus error to the user isn't very useful */
-               if (g_error_matches (error, TP_ERRORS, TP_ERROR_AUTHENTICATION_FAILED)) {
+               if (g_error_matches (error, TP_ERROR, TP_ERROR_AUTHENTICATION_FAILED)) {
                        display_password_info_bar (self);
                        gtk_widget_set_sensitive (priv->hpaned, FALSE);
                }
index 415aee0b2d812219a3c528525d10d72eccbc211d..f22da44d705f9ad65306b8f3833ae902e65c8309 100644 (file)
@@ -256,7 +256,7 @@ contact_blocking_dialog_set_error (EmpathyContactBlockingDialog *self,
 {
   const char *msg = NULL;
 
-  if (error->domain == TP_ERRORS)
+  if (error->domain == TP_ERROR)
     {
       if (error->code == TP_ERROR_INVALID_HANDLE)
         msg = _("Unknown or invalid identifier");
index 390f9a533279b4575fec92354607090e41697f6d..b35290cde80cd290de9e40c561926cefd9032424 100644 (file)
@@ -494,7 +494,7 @@ message_sent_cb (TpTextChannel *channel,
 static TpChannelTextSendError
 error_to_text_send_error (GError *error)
 {
-  if (error->domain != TP_ERRORS)
+  if (error->domain != TP_ERROR)
     return TP_CHANNEL_TEXT_SEND_ERROR_UNKNOWN;
 
   switch (error->code)
index 681c882eec72e6753eba8af23c6824bb7bf62a59..111e3190a34b38e38236a067a7761f80e2f345a9 100644 (file)
@@ -298,7 +298,7 @@ get_contact_by_handle_cb (TpConnection *connection,
                         * so the caller of empathy_tp_contact_factory_get_from_handle can
                         * rely on the error to check if the operation succeeded or not. */
 
-                       err = g_error_new_literal (TP_ERRORS, TP_ERROR_INVALID_HANDLE,
+                       err = g_error_new_literal (TP_ERROR, TP_ERROR_INVALID_HANDLE,
                                                      "handle is invalid");
                }
                else {
index 95c828d94d43fddcfbd8be4c0171152123eb03b4..783c44e951933ef33e2a50ae1f32702c9f906116 100644 (file)
@@ -268,7 +268,7 @@ approve_channels (TpBaseClient *client,
   EmpathyCallFactory *self = EMPATHY_CALL_FACTORY (client);
   TpCallChannel *channel;
   guint handle;
-  GError error = { TP_ERRORS, TP_ERROR_INVALID_ARGUMENT, "" };
+  GError error = { TP_ERROR, TP_ERROR_INVALID_ARGUMENT, "" };
   gboolean handled = FALSE;
 
   channel = find_call_channel (channels);
index 2019cd02f60433cc3df53bc9db78d00f3b4ba8f4..35ceeb046ee8d91a53ed55e0dfe3a73f9681f979 100644 (file)
@@ -252,7 +252,7 @@ observe_channels (TpSimpleObserver *observer,
   channel = find_main_channel (channels);
   if (channel == NULL)
     {
-      GError err = { TP_ERRORS, TP_ERROR_INVALID_ARGUMENT,
+      GError err = { TP_ERROR, TP_ERROR_INVALID_ARGUMENT,
           "Unknown channel type" };
 
       DEBUG ("Didn't find any Call or StreamedMedia channel; ignoring");
index b3465cea19e414b8876260a0491ed6ea8d15e2bf..935941de3181522fe37396ffa04dad7d2b6f5217 100644 (file)
@@ -293,7 +293,7 @@ handle_with_time_cb (GObject *source,
   if (!tp_channel_dispatch_operation_handle_with_time_finish (cdo, result,
         &error))
     {
-      if (g_error_matches (error, TP_ERRORS, TP_ERROR_NOT_IMPLEMENTED))
+      if (g_error_matches (error, TP_ERROR, TP_ERROR_NOT_IMPLEMENTED))
         {
           EventManagerApproval *approval = user_data;
 
@@ -931,7 +931,7 @@ approve_channels (TpSimpleApprover *approver,
   channel = find_main_channel (channels);
   if (channel == NULL)
     {
-      GError error = { TP_ERRORS, TP_ERROR_INVALID_ARGUMENT,
+      GError error = { TP_ERROR, TP_ERROR_INVALID_ARGUMENT,
           "Unknown channel type" };
 
       DEBUG ("Failed to find the main channel; ignoring");
@@ -1041,7 +1041,7 @@ approve_channels (TpSimpleApprover *approver,
         }
       else
         {
-          GError error = { TP_ERRORS, TP_ERROR_NOT_IMPLEMENTED,
+          GError error = { TP_ERROR, TP_ERROR_NOT_IMPLEMENTED,
               "Support only X-TELEPATHY-PASSWORD auth method" };
 
           tp_add_dispatch_operation_context_fail (context, &error);
@@ -1050,7 +1050,7 @@ approve_channels (TpSimpleApprover *approver,
     }
   else
     {
-      GError error = { TP_ERRORS, TP_ERROR_INVALID_ARGUMENT,
+      GError error = { TP_ERROR, TP_ERROR_INVALID_ARGUMENT,
           "Invalid channel type" };
 
       DEBUG ("Unknown channel type (%s), ignoring..",