feat: main framework complete.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
class SPKeys {
|
||||
static final String brightnessMode = 'BRIGHTNESS_MODE';
|
||||
static final String userLanguage = 'USER_LANGUAGE';
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
enum SupportedLocale {
|
||||
zh_CN,
|
||||
en,
|
||||
}
|
||||
|
||||
const zh_CN = Locale('zh', 'CN');
|
||||
const en = Locale('en');
|
||||
|
||||
const supportedLocales = [
|
||||
zh_CN,
|
||||
en,
|
||||
];
|
||||
|
||||
const supportedLocaleNames = {
|
||||
SupportedLocale.zh_CN: '简体中文',
|
||||
SupportedLocale.en: 'English',
|
||||
};
|
||||
|
||||
Locale getSupportedLocale(SupportedLocale supportedLocale) => supportedLocales[supportedLocale.index];
|
||||
|
||||
Reference in New Issue
Block a user