Loading android/app/src/com/android/bluetooth/avrcp/MediaPlayerList.java +2 −0 Original line number Diff line number Diff line Loading @@ -197,6 +197,8 @@ public class MediaPlayerList { void cleanup() { mContext.unregisterReceiver(mPackageChangedBroadcastReceiver); mActivePlayerId = NO_ACTIVE_PLAYER; mMediaSessionManager.removeOnActiveSessionsChangedListener(mActiveSessionsChangedListener); mMediaSessionManager.setCallback(null, null); mMediaSessionManager = null; Loading android/app/src/com/android/bluetooth/btservice/Config.java +14 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.content.ContentResolver; import android.content.Context; import android.content.res.Resources; import android.provider.Settings; import android.util.ArrayMap; import android.util.FeatureFlagUtils; import android.util.Log; Loading @@ -42,6 +43,7 @@ import com.android.bluetooth.pan.PanService; import com.android.bluetooth.pbap.BluetoothPbapService; import com.android.bluetooth.pbapclient.PbapClientService; import com.android.bluetooth.sap.SapService; import com.android.server.SystemConfig; import java.util.ArrayList; Loading Loading @@ -112,6 +114,11 @@ public class Config { if (resources == null) { return; } SystemConfig systemConfig = SystemConfig.getInstance(); ArrayMap<String, Boolean> componentEnabledStates = null; if (systemConfig != null) { componentEnabledStates = systemConfig.getComponentsEnabledStates(ctx.getPackageName()); } ArrayList<Class> profiles = new ArrayList<>(PROFILE_SERVICES_AND_FLAGS.length); for (ProfileConfig config : PROFILE_SERVICES_AND_FLAGS) { Loading @@ -123,6 +130,13 @@ public class Config { supported = true; } if (componentEnabledStates != null && componentEnabledStates.containsKey(config.mClass.getName())) { supported = componentEnabledStates.get(config.mClass.getName()); Log.v(TAG, config.mClass.getSimpleName() + " Feature Flag set to " + supported + " by components configuration"); } if (supported && !isProfileDisabled(ctx, config.mMask)) { Log.v(TAG, "Adding " + config.mClass.getSimpleName()); profiles.add(config.mClass); Loading Loading
android/app/src/com/android/bluetooth/avrcp/MediaPlayerList.java +2 −0 Original line number Diff line number Diff line Loading @@ -197,6 +197,8 @@ public class MediaPlayerList { void cleanup() { mContext.unregisterReceiver(mPackageChangedBroadcastReceiver); mActivePlayerId = NO_ACTIVE_PLAYER; mMediaSessionManager.removeOnActiveSessionsChangedListener(mActiveSessionsChangedListener); mMediaSessionManager.setCallback(null, null); mMediaSessionManager = null; Loading
android/app/src/com/android/bluetooth/btservice/Config.java +14 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.content.ContentResolver; import android.content.Context; import android.content.res.Resources; import android.provider.Settings; import android.util.ArrayMap; import android.util.FeatureFlagUtils; import android.util.Log; Loading @@ -42,6 +43,7 @@ import com.android.bluetooth.pan.PanService; import com.android.bluetooth.pbap.BluetoothPbapService; import com.android.bluetooth.pbapclient.PbapClientService; import com.android.bluetooth.sap.SapService; import com.android.server.SystemConfig; import java.util.ArrayList; Loading Loading @@ -112,6 +114,11 @@ public class Config { if (resources == null) { return; } SystemConfig systemConfig = SystemConfig.getInstance(); ArrayMap<String, Boolean> componentEnabledStates = null; if (systemConfig != null) { componentEnabledStates = systemConfig.getComponentsEnabledStates(ctx.getPackageName()); } ArrayList<Class> profiles = new ArrayList<>(PROFILE_SERVICES_AND_FLAGS.length); for (ProfileConfig config : PROFILE_SERVICES_AND_FLAGS) { Loading @@ -123,6 +130,13 @@ public class Config { supported = true; } if (componentEnabledStates != null && componentEnabledStates.containsKey(config.mClass.getName())) { supported = componentEnabledStates.get(config.mClass.getName()); Log.v(TAG, config.mClass.getSimpleName() + " Feature Flag set to " + supported + " by components configuration"); } if (supported && !isProfileDisabled(ctx, config.mMask)) { Log.v(TAG, "Adding " + config.mClass.getSimpleName()); profiles.add(config.mClass); Loading