mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-05-31 16:18:22 +08:00
opt: select dialog & feat: select subtitle if muted (#564)
* opt: select dialog * opt: subtitle * feat: select subtitle if muted
This commit is contained in:
committed by
GitHub
parent
2ddfea5cf3
commit
82f9f48a8e
@@ -1,16 +1,17 @@
|
||||
enum SubtitlePreference { off, on, withoutAi }
|
||||
enum SubtitlePreference { off, on, withoutAi, auto }
|
||||
|
||||
extension SubtitlePreferenceDesc on SubtitlePreference {
|
||||
static final List<String> _descList = [
|
||||
'默认不显示字幕',
|
||||
'选择第一个可用字幕',
|
||||
'跳过自动生成(ai)字幕,选择第一个可用字幕'
|
||||
'优先选择非自动生成(ai)字幕',
|
||||
'跳过自动生成(ai)字幕,选择第一个可用字幕',
|
||||
'静音时等同第二项,非静音时等同第三项'
|
||||
];
|
||||
get description => _descList[index];
|
||||
String get description => _descList[index];
|
||||
}
|
||||
|
||||
extension SubtitlePreferenceCode on SubtitlePreference {
|
||||
static final List<String> _codeList = ['off', 'on', 'withoutAi'];
|
||||
static const List<String> _codeList = ['off', 'on', 'withoutAi', 'auto'];
|
||||
String get code => _codeList[index];
|
||||
|
||||
static SubtitlePreference? fromCode(String code) {
|
||||
|
||||
Reference in New Issue
Block a user