Change dbus function name 60/255560/1 accepted/tizen/6.5/unified/20211028.114650 accepted/tizen/unified/20210321.225748 submit/tizen/20210319.090004 submit/tizen_6.5/20211028.162501 tizen_6.5.m2_release
authortaemin.yeom <taemin.yeom@samsung.com>
Fri, 19 Mar 2021 07:37:47 +0000 (16:37 +0900)
committertaemin.yeom <taemin.yeom@samsung.com>
Fri, 19 Mar 2021 07:37:47 +0000 (16:37 +0900)
Change-Id: Icc25271e356bd4284b6162a4514740b17a54cefd
Signed-off-by: taemin.yeom <taemin.yeom@samsung.com>
src/auto-test/haptic.c
src/auto-test/test.h
src/core/haptic.c
src/core/main.c

index 944f622..101f8da 100644 (file)
@@ -33,7 +33,7 @@ static bool request_haptic_method(const char *method, GVariant *param, int *out_
        int reply_val, ret_dbus;
        bool ret = FALSE;
 
-       ret_dbus = dbus_handle_method_sync_with_reply_var(VIBRATOR_BUS_NAME,
+       ret_dbus = gdbus_call_sync_with_reply(VIBRATOR_BUS_NAME,
                VIBRATOR_PATH_HAPTIC,
                VIBRATOR_INTERFACE_HAPTIC,
                method, param, &reply);
index e0b93ec..2bd0130 100644 (file)
@@ -21,7 +21,7 @@
 #define FEEDBACKD__TEST_H__
 #include <stdio.h>
 #include <errno.h>
-#include <libsyscommon/dbus-system.h>
+#include <libsyscommon/libgdbus.h>
 
 #include "shared/log.h"
 #include "shared/common.h"
index 3f955ea..e644f1c 100644 (file)
@@ -24,7 +24,7 @@
 #include <vconf.h>
 #include <time.h>
 #include <string.h>
-#include <libsyscommon/dbus-system.h>
+#include <libsyscommon/libgdbus.h>
 #include <libsyscommon/list.h>
 #include <libsyscommon/ini-parser.h>
 #include <hal/device/hal-haptic.h>
@@ -609,7 +609,7 @@ static struct haptic_info *add_haptic_info(const char *sender)
 
        SYS_G_LIST_APPEND(haptic_handle_list, info);
 
-       info->id_watch = dbus_handle_watch_name(sender, NULL, haptic_name_owner_changed, info, NULL);
+       info->id_watch = gdbus_watch_name(sender, NULL, haptic_name_owner_changed, info, NULL);
 
        return info;
 }
@@ -618,7 +618,7 @@ static int remove_haptic_info(struct haptic_info *info)
 {
        assert(info);
 
-       dbus_handle_unwatch_name(info->id_watch);
+       gdbus_unwatch_name(info->id_watch);
 
        SYS_G_LIST_REMOVE(haptic_handle_list, info);
        SYS_G_LIST_FREE_LIST(info->handle_list);
@@ -1315,11 +1315,11 @@ void haptic_init(void)
        }
 
        /* init dbus interface */
-       r = dbus_handle_register_dbus_object(NULL, VIBRATOR_PATH_HAPTIC, &dbus_interface);
+       r = gdbus_register_object(NULL, VIBRATOR_PATH_HAPTIC, &dbus_interface);
        if (r < 0)
                _E("Failed to init hdbus interface and method: %d", r);
 
-       id_sig_pwr_off_state = subscribe_dbus_signal(NULL,
+       id_sig_pwr_off_state = gdbus_signal_subscribe(NULL,
                        DEVICED_PATH_POWEROFF,
                        DEVICED_INTERFACE_POWEROFF,
                        SIGNAL_POWEROFF_STATE,
@@ -1331,7 +1331,7 @@ void haptic_init(void)
                return;
        }
 
-       dbus_handle_emit_dbus_signal(NULL,
+       gdbus_signal_emit(NULL,
                        VIBRATOR_PATH_HAPTIC,
                        VIBRATOR_INTERFACE_HAPTIC,
                        SIGNAL_VIBRATOR_INITIATED,
@@ -1361,7 +1361,7 @@ void haptic_exit(void)
        }
 
        /* unregister notifier for below each event */
-       unsubscribe_dbus_signal(NULL, id_sig_pwr_off_state);
+       gdbus_signal_unsubscribe(NULL, id_sig_pwr_off_state);
 
        /* release haptic data memory */
        safe_free(haptic_conf.level_arr);
index a6760e9..c3efc39 100644 (file)
@@ -24,7 +24,7 @@
 
 #include <system_info.h>
 #include <systemd/sd-daemon.h>
-#include <libsyscommon/dbus-system.h>
+#include <libsyscommon/libgdbus.h>
 
 #include "shared/log.h"
 #include "shared/common.h"
@@ -70,7 +70,7 @@ int main(int argc, char **argv)
 
        mainloop = g_main_loop_new(NULL, FALSE);
 
-       handle = dbus_handle_get_connection(G_BUS_TYPE_SYSTEM, FALSE);
+       handle = gdbus_get_connection(G_BUS_TYPE_SYSTEM, FALSE);
        if (!handle)
                _E("Failed to get dbus connection.");;
 
@@ -82,10 +82,10 @@ int main(int argc, char **argv)
        }
        haptic_init();
 
-       ret = dbus_handle_request_bus_name(handle, VIBRATOR_BUS_NAME, dbus_name_acquired, NULL);
+       ret = gdbus_request_name(handle, VIBRATOR_BUS_NAME, dbus_name_acquired, NULL);
        if (ret <= 0) {
                _E("Failed to request bus name.");
-               dbus_handle_check_owner_name(NULL, VIBRATOR_BUS_NAME);
+               gdbus_check_name_owner(NULL, VIBRATOR_BUS_NAME);
        }
 
        signal(SIGTERM, sig_quit);