[evolution-data-server/wip/mcrha/libical-glib] Revert "Rename AddressBookView/CalendarView D-Bus members for backward compatibility"



commit f9d600919a37ae95c9104307be639f252546ae15
Author: Milan Crha <mcrha redhat com>
Date:   Thu Apr 11 12:33:13 2019 +0200

    Revert "Rename AddressBookView/CalendarView D-Bus members for backward compatibility"
    
    This reverts commit 93a186595a462da1d4dd4bc5c1032d6d00573808.
    The API changed and the D-Bus services has bumped their version as well,
    thus this backward compatibility patch can be reverted.

 src/addressbook/libebook/e-book-client-view.c      |  7 ++++---
 src/addressbook/libedata-book/e-data-book-view.c   |  8 ++------
 src/calendar/libecal/e-cal-client-view.c           |  7 ++++---
 src/calendar/libedata-cal/e-data-cal-view.c        |  8 ++------
 ....gnome.evolution.dataserver.AddressBookView.xml | 23 +++++++++++-----------
 ...org.gnome.evolution.dataserver.CalendarView.xml | 23 +++++++++++-----------
 6 files changed, 36 insertions(+), 40 deletions(-)
---
diff --git a/src/addressbook/libebook/e-book-client-view.c b/src/addressbook/libebook/e-book-client-view.c
index f96fbea8b..dc4796c2d 100644
--- a/src/addressbook/libebook/e-book-client-view.c
+++ b/src/addressbook/libebook/e-book-client-view.c
@@ -624,7 +624,8 @@ book_client_view_progress_cb (EDBusAddressBookView *object,
 
 static void
 book_client_view_complete_cb (EDBusAddressBookView *object,
-                             const gchar * const *arg_error,
+                             const gchar *arg_error_name,
+                             const gchar *arg_error_message,
                               GWeakRef *client_view_weak_ref)
 {
        EBookClientView *client_view;
@@ -643,8 +644,8 @@ book_client_view_complete_cb (EDBusAddressBookView *object,
 
                signal_closure = g_slice_new0 (SignalClosure);
                g_weak_ref_init (&signal_closure->client_view, client_view);
-               if (arg_error && arg_error[0] && *arg_error[0] && arg_error[1])
-                       signal_closure->error = g_dbus_error_new_for_dbus_error (arg_error[0], arg_error[1]);
+               if (arg_error_name && *arg_error_name && arg_error_message)
+                       signal_closure->error = g_dbus_error_new_for_dbus_error (arg_error_name, 
arg_error_message);
                else
                        signal_closure->error = NULL;
 
diff --git a/src/addressbook/libedata-book/e-data-book-view.c 
b/src/addressbook/libedata-book/e-data-book-view.c
index 391cdad32..ddaa5bdb5 100644
--- a/src/addressbook/libedata-book/e-data-book-view.c
+++ b/src/addressbook/libedata-book/e-data-book-view.c
@@ -1073,7 +1073,6 @@ e_data_book_view_notify_complete (EDataBookView *view,
                                   const GError *error)
 {
        gchar *error_name, *error_message;
-       const gchar *arg_error[3];
 
        g_return_if_fail (E_IS_DATA_BOOK_VIEW (view));
 
@@ -1103,13 +1102,10 @@ e_data_book_view_notify_complete (EDataBookView *view,
                error_message = g_strdup ("");
        }
 
-       arg_error[0] = error_name;
-       arg_error[1] = error_message;
-       arg_error[2] = NULL;
-
        e_dbus_address_book_view_emit_complete (
                view->priv->dbus_object,
-               arg_error);
+               error_name,
+               error_message);
 
        g_free (error_name);
        g_free (error_message);
diff --git a/src/calendar/libecal/e-cal-client-view.c b/src/calendar/libecal/e-cal-client-view.c
index e51286b4f..9da88897f 100644
--- a/src/calendar/libecal/e-cal-client-view.c
+++ b/src/calendar/libecal/e-cal-client-view.c
@@ -456,7 +456,8 @@ cal_client_view_progress_cb (EDBusCalendarView *dbus_proxy,
 
 static void
 cal_client_view_complete_cb (EDBusCalendarView *dbus_proxy,
-                            const gchar * const *arg_error,
+                            const gchar *arg_error_name,
+                            const gchar *arg_error_message,
                              GWeakRef *client_view_weak_ref)
 {
        ECalClientView *client_view;
@@ -475,8 +476,8 @@ cal_client_view_complete_cb (EDBusCalendarView *dbus_proxy,
 
                signal_closure = g_slice_new0 (SignalClosure);
                g_weak_ref_init (&signal_closure->client_view, client_view);
-               if (arg_error && arg_error[0] && *arg_error[0] && arg_error[1])
-                       signal_closure->error = g_dbus_error_new_for_dbus_error (arg_error[0], arg_error[1]);
+               if (arg_error_name && *arg_error_name && arg_error_message)
+                       signal_closure->error = g_dbus_error_new_for_dbus_error (arg_error_name, 
arg_error_message);
                else
                        signal_closure->error = NULL;
 
diff --git a/src/calendar/libedata-cal/e-data-cal-view.c b/src/calendar/libedata-cal/e-data-cal-view.c
index 8ece57fcf..0cb1bcb36 100644
--- a/src/calendar/libedata-cal/e-data-cal-view.c
+++ b/src/calendar/libedata-cal/e-data-cal-view.c
@@ -1364,7 +1364,6 @@ e_data_cal_view_notify_complete (EDataCalView *view,
                                  const GError *error)
 {
        gchar *error_name, *error_message;
-       const gchar *arg_error[3];
 
        g_return_if_fail (E_IS_DATA_CAL_VIEW (view));
 
@@ -1391,13 +1390,10 @@ e_data_cal_view_notify_complete (EDataCalView *view,
                error_message = g_strdup ("");
        }
 
-       arg_error[0] = error_name;
-       arg_error[1] = error_message;
-       arg_error[2] = NULL;
-
        e_dbus_calendar_view_emit_complete (
                view->priv->dbus_object,
-               arg_error);
+               error_name,
+               error_message);
 
        g_free (error_name);
        g_free (error_message);
diff --git a/src/private/org.gnome.evolution.dataserver.AddressBookView.xml 
b/src/private/org.gnome.evolution.dataserver.AddressBookView.xml
index 5629f3751..bf481a464 100644
--- a/src/private/org.gnome.evolution.dataserver.AddressBookView.xml
+++ b/src/private/org.gnome.evolution.dataserver.AddressBookView.xml
@@ -12,39 +12,40 @@
 -->
 <interface name="org.gnome.evolution.dataserver.AddressBookView">
 
-  <signal name="objects_added">
+  <signal name="ObjectsAdded">
     <arg name="objects" type="as"/>
   </signal>
 
-  <signal name="objects_modified">
+  <signal name="ObjectsModified">
     <arg name="objects" type="as"/>
   </signal>
 
-  <signal name="objects_removed">
+  <signal name="ObjectsRemoved">
     <arg name="uids" type="as"/>
   </signal>
 
-  <signal name="progress">
+  <signal name="Progress">
     <arg name="percent" type="u"/>
     <arg name="message" type="s"/>
   </signal>
 
-  <signal name="complete">
-    <arg name="error" type="as"/>
+  <signal name="Complete">
+    <arg name="error_name" type="s"/>
+    <arg name="error_message" type="s"/>
   </signal>
 
-  <method name="start"/>
+  <method name="Start"/>
 
-  <method name="stop"/>
+  <method name="Stop"/>
 
-  <method name="set_flags">
+  <method name="SetFlags">
     <arg name="flags" type="u"/>
   </method>
 
-  <method name="set_fields_of_interest">
+  <method name="SetFieldsOfInterest">
     <arg name="only_fields" direction="in" type="as"/>
   </method>
 
-  <method name="dispose"/>
+  <method name="Dispose"/>
 
 </interface>
diff --git a/src/private/org.gnome.evolution.dataserver.CalendarView.xml 
b/src/private/org.gnome.evolution.dataserver.CalendarView.xml
index 729bebbe8..805902938 100644
--- a/src/private/org.gnome.evolution.dataserver.CalendarView.xml
+++ b/src/private/org.gnome.evolution.dataserver.CalendarView.xml
@@ -12,39 +12,40 @@
 -->
 <interface name="org.gnome.evolution.dataserver.CalendarView">
 
-  <signal name="objects_added">
+  <signal name="ObjectsAdded">
     <arg name="objects" type="as"/>
   </signal>
 
-  <signal name="objects_modified">
+  <signal name="ObjectsModified">
     <arg name="objects" type="as"/>
   </signal>
 
-  <signal name="objects_removed">
+  <signal name="ObjectsRemoved">
     <arg name="uids" type="as"/>
   </signal>
 
-  <signal name="progress">
+  <signal name="Progress">
     <arg name="percent" type="u"/>
     <arg name="message" type="s"/>
   </signal>
 
-  <signal name="complete">
-    <arg name="error" type="as"/>
+  <signal name="Complete">
+    <arg name="error_name" type="s"/>
+    <arg name="error_message" type="s"/>
   </signal>
 
-  <method name="start"/>
+  <method name="Start"/>
 
-  <method name="stop"/>
+  <method name="Stop"/>
 
-  <method name="set_flags">
+  <method name="SetFlags">
     <arg name="flags" type="u"/>
   </method>
 
-  <method name="set_fields_of_interest">
+  <method name="SetFieldsOfInterest">
     <arg name="only_fields" direction="in" type="as"/>
   </method>
 
-  <method name="dispose"/>
+  <method name="Dispose"/>
 
 </interface>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]