feat(flutter): persist voice settings and per-user volume (TODO-039,040)
Add SharedPreferences persistence for transmit mode, release tail, input/output device. Per-user volume/mute persisted across sessions.
This commit is contained in:
@@ -47,6 +47,8 @@ class VoiceSettingsDialog extends StatefulWidget {
|
||||
this.talkPower,
|
||||
this.neededTalkPower,
|
||||
this.talkPowerGranted,
|
||||
this.onInputDeviceChanged,
|
||||
this.onOutputDeviceChanged,
|
||||
});
|
||||
|
||||
final rust.BridgeTransmitMode initialMode;
|
||||
@@ -58,6 +60,8 @@ class VoiceSettingsDialog extends StatefulWidget {
|
||||
final int? talkPower;
|
||||
final int? neededTalkPower;
|
||||
final bool? talkPowerGranted;
|
||||
final ValueChanged<String?>? onInputDeviceChanged;
|
||||
final ValueChanged<String?>? onOutputDeviceChanged;
|
||||
|
||||
@override
|
||||
State<VoiceSettingsDialog> createState() => _VoiceSettingsDialogState();
|
||||
@@ -207,13 +211,15 @@ class _VoiceSettingsDialogState extends State<VoiceSettingsDialog> {
|
||||
if (!isAndroidHost && !isIosHost) ...[
|
||||
const Divider(height: 24),
|
||||
const VoiceSectionHeader('Audio devices'),
|
||||
const AudioDeviceListTile(
|
||||
AudioDeviceListTile(
|
||||
label: 'Input',
|
||||
kind: AudioDeviceKind.input,
|
||||
onDeviceChanged: widget.onInputDeviceChanged,
|
||||
),
|
||||
const AudioDeviceListTile(
|
||||
AudioDeviceListTile(
|
||||
label: 'Output',
|
||||
kind: AudioDeviceKind.output,
|
||||
onDeviceChanged: widget.onOutputDeviceChanged,
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user