1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-08-06 21:48:30 -04:00

feat(bluetooth): built in audio codec support - another dep bites the dust

- Updated the codec logic to utilize WirePlumber, bye pactl
- Improved UI to display media and call codec sections
This commit is contained in:
purian23
2026-07-18 14:16:49 -04:00
parent 4a90bd3fb1
commit 2114ece0df
4 changed files with 699 additions and 310 deletions
@@ -92,15 +92,7 @@ Rectangle {
}
function updateDeviceCodecDisplay(deviceAddress, codecName) {
for (let i = 0; i < pairedRepeater.count; i++) {
const item = pairedRepeater.itemAt(i);
if (!item?.modelData)
continue;
if (item.modelData.address !== deviceAddress)
continue;
item.currentCodec = codecName;
break;
}
BluetoothService.updateDeviceCodec(deviceAddress, codecName);
}
function normalizePinList(value) {
@@ -255,7 +247,10 @@ Rectangle {
required property var modelData
required property int index
readonly property string currentCodec: BluetoothService.deviceCodecs[modelData.address] || ""
readonly property string currentCodec: {
const codecs = BluetoothService.deviceCodecs;
return codecs[modelData.address] || "";
}
readonly property bool isConnecting: modelData.state === BluetoothDeviceState.Connecting
readonly property bool isConnected: modelData.connected
readonly property bool isPinned: root.getPinnedDevices().includes(modelData.address)