BT_EXPORT_API int bluetooth_check_adapter(void)
{
- int value = VCONFKEY_BT_STATUS_OFF;
+#ifndef TIZEN_BLUEDROID_PORTING
int ret;
-
ret = _bt_get_adapter_path(_bt_get_system_common_conn(), NULL);
-
- if (ret != BLUETOOTH_ERROR_NONE)
- return BLUETOOTH_ADAPTER_DISABLED;
+ return ret == BLUETOOTH_ERROR_NONE ? BLUETOOTH_ADAPTER_ENABLED :
+ BLUETOOTH_ADAPTER_DISABLED;
+#else
+ int value = VCONFKEY_BT_STATUS_OFF;
/* check VCONFKEY_BT_STATUS */
if (vconf_get_int(VCONFKEY_BT_STATUS, &value) != 0) {
return value == VCONFKEY_BT_STATUS_OFF ? BLUETOOTH_ADAPTER_DISABLED :
BLUETOOTH_ADAPTER_ENABLED;
+#endif
}
BT_EXPORT_API int bluetooth_enable_adapter(void)