mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2024-12-14 18:34:30 -05:00
b5bc269743
Signed-off-by: Tad <tad@spotco.us>
68 lines
3.2 KiB
Diff
68 lines
3.2 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: ValdikSS <iam@valdikss.org.ru>
|
|
Date: Mon, 10 Sep 2018 14:01:25 +0300
|
|
Subject: [PATCH] Add Dual Channel into Bluetooth Audio Channel Mode developer
|
|
options menu
|
|
|
|
Change-Id: Icd3179ac63310355547fd58060e75f25b4a8210d
|
|
---
|
|
res/xml/development_settings.xml | 4 ++--
|
|
.../BluetoothAudioChannelModePreferenceController.java | 10 ++++++++--
|
|
2 files changed, 10 insertions(+), 4 deletions(-)
|
|
|
|
diff --git a/res/xml/development_settings.xml b/res/xml/development_settings.xml
|
|
index 0262556d09..f02301d51b 100644
|
|
--- a/res/xml/development_settings.xml
|
|
+++ b/res/xml/development_settings.xml
|
|
@@ -356,8 +356,8 @@
|
|
android:key="bluetooth_select_a2dp_channel_mode"
|
|
android:title="@string/bluetooth_select_a2dp_codec_channel_mode"
|
|
android:dialogTitle="@string/bluetooth_select_a2dp_codec_channel_mode_dialog_title"
|
|
- android:entries="@array/bluetooth_a2dp_codec_channel_mode_titles"
|
|
- android:entryValues="@array/bluetooth_a2dp_codec_channel_mode_values" />
|
|
+ android:entries="@array/lineage_bluetooth_a2dp_codec_channel_mode_titles"
|
|
+ android:entryValues="@array/lineage_bluetooth_a2dp_codec_channel_mode_values" />
|
|
|
|
<ListPreference
|
|
android:key="bluetooth_select_a2dp_ldac_playback_quality"
|
|
diff --git a/src/com/android/settings/development/BluetoothAudioChannelModePreferenceController.java b/src/com/android/settings/development/BluetoothAudioChannelModePreferenceController.java
|
|
index a58c675516..50fcdd42af 100644
|
|
--- a/src/com/android/settings/development/BluetoothAudioChannelModePreferenceController.java
|
|
+++ b/src/com/android/settings/development/BluetoothAudioChannelModePreferenceController.java
|
|
@@ -42,13 +42,13 @@ public class BluetoothAudioChannelModePreferenceController extends
|
|
@Override
|
|
protected String[] getListValues() {
|
|
return mContext.getResources().getStringArray(
|
|
- R.array.bluetooth_a2dp_codec_channel_mode_values);
|
|
+ R.array.lineage_bluetooth_a2dp_codec_channel_mode_values);
|
|
}
|
|
|
|
@Override
|
|
protected String[] getListSummaries() {
|
|
return mContext.getResources().getStringArray(
|
|
- R.array.bluetooth_a2dp_codec_channel_mode_summaries);
|
|
+ R.array.lineage_bluetooth_a2dp_codec_channel_mode_summaries);
|
|
}
|
|
|
|
@Override
|
|
@@ -70,6 +70,9 @@ public class BluetoothAudioChannelModePreferenceController extends
|
|
case 2:
|
|
channelModeValue = BluetoothCodecConfig.CHANNEL_MODE_STEREO;
|
|
break;
|
|
+ case 3:
|
|
+ channelModeValue = BluetoothCodecConfig.CHANNEL_MODE_DUAL_CHANNEL;
|
|
+ break;
|
|
default:
|
|
break;
|
|
}
|
|
@@ -87,6 +90,9 @@ public class BluetoothAudioChannelModePreferenceController extends
|
|
case BluetoothCodecConfig.CHANNEL_MODE_STEREO:
|
|
index = 2;
|
|
break;
|
|
+ case BluetoothCodecConfig.CHANNEL_MODE_DUAL_CHANNEL:
|
|
+ index = 3;
|
|
+ break;
|
|
case BluetoothCodecConfig.CHANNEL_MODE_NONE:
|
|
default:
|
|
break;
|