Fixed voice selector colors
This commit is contained in:
parent
feab8d65a8
commit
666aff0a2a
|
@ -8,7 +8,7 @@ import 'package:ollama_app/worker/setter.dart';
|
|||
import 'package:speech_to_text/speech_to_text.dart' as stt;
|
||||
import 'package:ollama_dart/ollama_dart.dart' as llama;
|
||||
import 'package:datetime_loop/datetime_loop.dart';
|
||||
import 'package:volume_controller/volume_controller.dart';
|
||||
// import 'package:volume_controller/volume_controller.dart';
|
||||
|
||||
import 'main.dart';
|
||||
import 'worker/sender.dart';
|
||||
|
|
|
@ -277,26 +277,25 @@ class _ScreenSettingsVoiceState extends State<ScreenSettingsVoice> {
|
|||
: (voiceLanguageOptionsAvailable.contains(languageOptionIds.elementAt(index)))
|
||||
? const Icon(Icons.spatial_tracking_rounded)
|
||||
: null,
|
||||
checkmarkColor: (usedIndex ==
|
||||
index)
|
||||
checkmarkColor: (usedIndex == index &&
|
||||
!(prefs?.getBool("useDeviceTheme") ??
|
||||
false))
|
||||
? ((MediaQuery.of(context).platformBrightness == Brightness.light)
|
||||
? (theme ?? ThemeData()).colorScheme.secondary
|
||||
: (themeDark ?? ThemeData.dark()).colorScheme.secondary)
|
||||
: null,
|
||||
labelStyle: (usedIndex ==
|
||||
index)
|
||||
labelStyle: (usedIndex == index &&
|
||||
!(prefs?.getBool("useDeviceTheme") ??
|
||||
false))
|
||||
? TextStyle(
|
||||
color: (MediaQuery.of(context).platformBrightness == Brightness.light) ? (theme ?? ThemeData()).colorScheme.secondary : (themeDark ?? ThemeData.dark()).colorScheme.secondary)
|
||||
: null,
|
||||
selectedColor: (MediaQuery.of(context).platformBrightness ==
|
||||
Brightness
|
||||
.light)
|
||||
? (theme ?? ThemeData())
|
||||
.colorScheme
|
||||
.primary
|
||||
: (themeDark ?? ThemeData.dark())
|
||||
.colorScheme
|
||||
.primary,
|
||||
selectedColor: (prefs?.getBool("useDeviceTheme") ??
|
||||
false)
|
||||
? null
|
||||
: (MediaQuery.of(context).platformBrightness == Brightness.light)
|
||||
? (theme ?? ThemeData()).colorScheme.primary
|
||||
: (themeDark ?? ThemeData.dark()).colorScheme.primary,
|
||||
onSelected:
|
||||
(bool
|
||||
selected) {
|
||||
|
|
Loading…
Reference in New Issue