Use allowed/disallowed value for bluetooth policy status 07/71207/2 accepted/tizen/common/20160525.155818 accepted/tizen/ivi/20160525.062044 accepted/tizen/mobile/20160525.062031 accepted/tizen/tv/20160525.062041 accepted/tizen/wearable/20160525.062037 submit/tizen/20160524.113632
authorJaemin Ryu <jm77.ryu@samsung.com>
Tue, 24 May 2016 11:30:57 +0000 (20:30 +0900)
committerJaemin Ryu <jm77.ryu@samsung.com>
Tue, 24 May 2016 11:34:14 +0000 (04:34 -0700)
Change-Id: Iab1a3b6aa1e327b2bcf06eaea3784ffb0d7f514f
Signed-off-by: Jaemin Ryu <jm77.ryu@samsung.com>
server/bluetooth.cpp

index 750aa6b..1af3ba0 100644 (file)
@@ -54,11 +54,11 @@ void bluetoothAdapterStateChangedCb(int result, bt_adapter_state_e state, void *
         // TODO(seok85.hong): "re-enforce-policy" : we can notify to admin client with this notification,
         //                    when we should be re-enforced again for the policy that we were failed to set into Bluetooth
         int ret = BLUETOOTH_DPM_RESULT_SUCCESS;
-        ret = policy.setModeChangeState(IsPolicyEnabled(context, "bluetooth"));
+        ret = policy.setModeChangeState(IsPolicyAllowed(context, "bluetooth"));
         if (ret != BLUETOOTH_DPM_RESULT_SUCCESS) {
             // TODO(seok85.hong): we can notify to admin client with this notification.
         }
-        ret = policy.setDesktopConnectivityState(IsPolicyEnabled(context, "bluetooth-desktop-connectivity"));
+        ret = policy.setDesktopConnectivityState(IsPolicyAllowed(context, "bluetooth-desktop-connectivity"));
         if (ret != BLUETOOTH_DPM_RESULT_SUCCESS) {
             // TODO(seok85.hong): we can notify to admin client with this notification.
         }
@@ -126,14 +126,14 @@ int BluetoothPolicy::setModeChangeState(const bool enable)
         return -1;
     }
 
-    SetPolicyEnabled(context, "bluetooth", enable);
+    SetPolicyAllowed(context, "bluetooth", enable);
 
     return 0;
 }
 
 bool BluetoothPolicy::getModeChangeState()
 {
-    return IsPolicyEnabled(context, "bluetooth");
+    return IsPolicyAllowed(context, "bluetooth");
 }
 
 int BluetoothPolicy::setDesktopConnectivityState(const bool enable)
@@ -145,14 +145,14 @@ int BluetoothPolicy::setDesktopConnectivityState(const bool enable)
         return -1;
     }
 
-    SetPolicyEnabled(context, "bluetooth-desktop-connectivity", enable);
+    SetPolicyAllowed(context, "bluetooth-desktop-connectivity", enable);
 
     return 0;
 }
 
 bool BluetoothPolicy::getDesktopConnectivityState()
 {
-    return IsPolicyEnabled(context, "bluetooth-desktop-connectivity");
+    return IsPolicyAllowed(context, "bluetooth-desktop-connectivity");
 }
 
 int BluetoothPolicy::addDeviceToBlacklist(const std::string& mac)