更新样式
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:ui';
|
||||
|
||||
import 'package:ef/ef.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
@@ -13,7 +14,7 @@ class LanguageModel {
|
||||
String? filename; // 语言文件名称
|
||||
String? language_name; // 语言名称
|
||||
bool? selected; // 是否选中
|
||||
String? language_code;//语言简称
|
||||
String? language_code; //语言简称
|
||||
|
||||
LanguageModel();
|
||||
|
||||
@@ -36,6 +37,11 @@ class LanguageController extends GetControllerEx<LanguageModel> {
|
||||
RxList languageList = [].obs;
|
||||
var selectLanguage = Rx<LanguageModel?>(null);
|
||||
|
||||
// final appLocale = Rx<Locale>(Locale('zh', 'CN'));
|
||||
final appLocale = Rx<Locale>(
|
||||
AppLanguage().isChinese() ? const Locale('zh', 'CN') : const Locale('en', 'US'),
|
||||
);
|
||||
|
||||
|
||||
Future<void> initLanuageList() async {
|
||||
try {
|
||||
@@ -91,5 +97,4 @@ class LanguageController extends GetControllerEx<LanguageModel> {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user