_bt_dpm_get_bluetooth_limited_discoverable_state(&discoverable_state);
if (discoverable_mode != BLUETOOTH_DISCOVERABLE_MODE_CONNECTABLE &&
discoverable_state == DPM_RESTRICTED) {
- if (headed_plugin_info->plugin_headed_enabled) // TODO: There is no definition headed_plugin_info
+ if (headed_plugin_info->plugin_headed_enabled)
headed_plugin_info->headed_plugin->bt_launch_dpmpopup("DPM_POLICY_DISABLE_BT_HANDSFREE");
return BLUETOOTH_ERROR_ACCESS_DENIED;
}
if (discoverable_mode == BLUETOOTH_DISCOVERABLE_MODE_GENERAL_DISCOVERABLE) {
ret = _bt_stop_visibility_timer();
+ if (BLUETOOTH_ERROR_NONE != ret)
+ BT_ERR("_bt_stop_visibility_timer failed");
if (!TIZEN_PROFILE_WEARABLE) {
if (vconf_set_int(BT_FILE_VISIBLE_TIME, -1) != 0)
BT_ERR("Set vconf failed");
}
} else if (discoverable_mode == BLUETOOTH_DISCOVERABLE_MODE_TIME_LIMITED_DISCOVERABLE) {
ret = _bt_start_visibility_timer(timeout);
+ if (BLUETOOTH_ERROR_NONE != ret)
+ BT_ERR("_bt_start_visibility_timer failed");
} else {
ret = _bt_stop_visibility_timer();
+ if (BLUETOOTH_ERROR_NONE != ret)
+ BT_ERR("_bt_stop_visibility_timer failed");
}
BT_DBG("-");
{
BT_INFO("__bt_adapter_post_set_enabled>>");
- if (TIZEN_PROFILE_TV || !headed_plugin_info->plugin_headed_enabled) {
- if (BLUETOOTH_ERROR_NONE != _bt_set_discoverable_mode(
- BLUETOOTH_DISCOVERABLE_MODE_GENERAL_DISCOVERABLE, 0))
- BT_ERR("Fail to set discoverable mode");
- } else {
+ if (!TIZEN_PROFILE_TV) {
__bt_set_visible_mode();
/* add the vconf noti handler */
BT_ERR("DEVICE_NAME key changed notification registration failed");
__bt_set_local_name();
+ } else {
+ if (BLUETOOTH_ERROR_NONE != _bt_set_discoverable_mode(
+ BLUETOOTH_DISCOVERABLE_MODE_GENERAL_DISCOVERABLE, 0))
+ BT_ERR("Fail to set discoverable mode");
}
/* Get All properties */
if (vconf_set_int(VCONFKEY_BT_DEVICE, VCONFKEY_BT_DEVICE_NONE) != 0)
BT_ERR("Set vconf failed\n");
- _bt_cancel_queued_transfers();
_bt_adapter_set_status(BT_DEACTIVATED);
__bt_adapter_update_discovery_status(ADAPTER_DISCOVERY_STOPPED);