From 53e74f510be255b00d06da44f8a91c61608ffade Mon Sep 17 00:00:00 2001 From: Sanket Padawe Date: Mon, 22 Jun 2015 12:33:53 -0700 Subject: [PATCH] Fix display of "Contact sharing" option in Car kit for BT Settings. Bug: 21879473 Change-Id: I0d2f839c525d2a5179f9ef59ab12a94f1aab9b6f --- res/layout/device_profiles_settings.xml | 1 + .../settings/bluetooth/DeviceProfilesSettings.java | 11 +---------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/res/layout/device_profiles_settings.xml b/res/layout/device_profiles_settings.xml index 0f8438500f7..87b85000d53 100644 --- a/res/layout/device_profiles_settings.xml +++ b/res/layout/device_profiles_settings.xml @@ -53,6 +53,7 @@ diff --git a/src/com/android/settings/bluetooth/DeviceProfilesSettings.java b/src/com/android/settings/bluetooth/DeviceProfilesSettings.java index 5dd70980b46..ae42e3d0c2f 100755 --- a/src/com/android/settings/bluetooth/DeviceProfilesSettings.java +++ b/src/com/android/settings/bluetooth/DeviceProfilesSettings.java @@ -154,6 +154,7 @@ public final class DeviceProfilesSettings extends DialogFragment implements dismiss(); return; } + addPreferencesForProfiles(); refresh(); } } @@ -169,16 +170,6 @@ public final class DeviceProfilesSettings extends DialogFragment implements mManager.setForegroundActivity(null); } - public void setDevice(CachedBluetoothDevice cachedDevice) { - mCachedDevice = cachedDevice; - - if (isResumed()) { - mCachedDevice.registerCallback(this); - addPreferencesForProfiles(); - refresh(); - } - } - private void addPreferencesForProfiles() { mProfileContainer.removeAllViews(); for (LocalBluetoothProfile profile : mCachedDevice.getConnectableProfiles()) {