summaryrefslogtreecommitdiff
path: root/framework/java/android/bluetooth/BluetoothHeadsetClient.java
diff options
context:
space:
mode:
Diffstat (limited to 'framework/java/android/bluetooth/BluetoothHeadsetClient.java')
-rw-r--r--framework/java/android/bluetooth/BluetoothHeadsetClient.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/framework/java/android/bluetooth/BluetoothHeadsetClient.java b/framework/java/android/bluetooth/BluetoothHeadsetClient.java
index 0059cdb9fb..83108d22e0 100644
--- a/framework/java/android/bluetooth/BluetoothHeadsetClient.java
+++ b/framework/java/android/bluetooth/BluetoothHeadsetClient.java
@@ -23,6 +23,7 @@ import android.annotation.SdkConstant.SdkConstantType;
import android.bluetooth.annotations.RequiresBluetoothConnectPermission;
import android.bluetooth.annotations.RequiresLegacyBluetoothPermission;
import android.compat.annotation.UnsupportedAppUsage;
+import android.content.Attributable;
import android.content.AttributionSource;
import android.content.Context;
import android.os.Binder;
@@ -535,7 +536,7 @@ public final class BluetoothHeadsetClient implements BluetoothProfile {
getService();
if (service != null && isEnabled()) {
try {
- return BluetoothDevice.setAttributionSource(
+ return Attributable.setAttributionSource(
service.getConnectedDevices(mAttributionSource), mAttributionSource);
} catch (RemoteException e) {
Log.e(TAG, Log.getStackTraceString(new Throwable()));
@@ -562,7 +563,7 @@ public final class BluetoothHeadsetClient implements BluetoothProfile {
getService();
if (service != null && isEnabled()) {
try {
- return BluetoothDevice.setAttributionSource(
+ return Attributable.setAttributionSource(
service.getDevicesMatchingConnectionStates(states, mAttributionSource),
mAttributionSource);
} catch (RemoteException e) {
@@ -797,7 +798,8 @@ public final class BluetoothHeadsetClient implements BluetoothProfile {
getService();
if (service != null && isEnabled() && isValidDevice(device)) {
try {
- return service.getCurrentCalls(device, mAttributionSource);
+ return Attributable.setAttributionSource(
+ service.getCurrentCalls(device, mAttributionSource), mAttributionSource);
} catch (RemoteException e) {
Log.e(TAG, Log.getStackTraceString(new Throwable()));
}
@@ -1020,7 +1022,8 @@ public final class BluetoothHeadsetClient implements BluetoothProfile {
getService();
if (service != null && isEnabled() && isValidDevice(device)) {
try {
- return service.dial(device, number, mAttributionSource);
+ return Attributable.setAttributionSource(
+ service.dial(device, number, mAttributionSource), mAttributionSource);
} catch (RemoteException e) {
Log.e(TAG, Log.getStackTraceString(new Throwable()));
}