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:
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user