From 895d35aae48f59275fc9e5680590edda76e28c90 Mon Sep 17 00:00:00 2001 From: Wootak Jung Date: Mon, 19 Mar 2018 14:14:53 +0900 Subject: [PATCH] Initialize VCONFKEY_BT_DEVICE to NONE when bt is enabled/disabled Change-Id: I44692c267963ddf68e5549d842f6b823eb9bccf6 --- bt-service-adaptation/services/adapter/bt-service-core-adapter.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/bt-service-adaptation/services/adapter/bt-service-core-adapter.c b/bt-service-adaptation/services/adapter/bt-service-core-adapter.c index e97f016..73131f7 100644 --- a/bt-service-adaptation/services/adapter/bt-service-core-adapter.c +++ b/bt-service-adaptation/services/adapter/bt-service-core-adapter.c @@ -1219,6 +1219,9 @@ static void __bt_adapter_update_bt_enabled(void) if (vconf_set_int(VCONFKEY_BT_STATUS, VCONFKEY_BT_STATUS_ON) != 0) BT_ERR("Set vconf failed\n"); + if (vconf_set_int(VCONFKEY_BT_DEVICE, VCONFKEY_BT_DEVICE_NONE) != 0) + BT_ERR("Set vconf failed\n"); + /* TODO:Add timer function to handle any further post processing */ g_idle_add((GSourceFunc)__bt_adapter_post_set_enabled, NULL); @@ -1248,6 +1251,9 @@ static void __bt_adapter_update_bt_disabled(void) if (vconf_set_int(VCONFKEY_BT_STATUS, VCONFKEY_BT_STATUS_OFF) != 0) BT_ERR("Set vconf failed"); + if (vconf_set_int(VCONFKEY_BT_DEVICE, VCONFKEY_BT_DEVICE_NONE) != 0) + BT_ERR("Set vconf failed\n"); + /* TODO:Add timer function to handle any further post processing */ g_idle_add((GSourceFunc)__bt_adapter_post_set_disabled, NULL); -- 2.7.4