mirror of
https://github.com/GopeedLab/gopeed.git
synced 2026-11-07 00:50:27 +00:00
feat: include Japanese
This commit is contained in:
1 parent
15d0296307
commit
adc7c7766d
6 files changed
+66
-17
No files matched your search
@@ -16,7 +16,7 @@ import '../../../../api/api.dart';
|
||||
import '../../../../api/model/downloader_config.dart';
|
||||
import '../../../../core/common/start_config.dart';
|
||||
import '../../../../generated/locales.g.dart';
|
||||
import '../../../../util/localeManager.dart';
|
||||
import '../../../../util/locale_manager.dart';
|
||||
import '../../../../util/log_util.dart';
|
||||
import '../../../../util/package_info.dart';
|
||||
import '../../../../util/util.dart';
|
||||
|
||||
@@ -4,7 +4,7 @@ import 'package:get/get.dart';
|
||||
|
||||
import '../../../../generated/locales.g.dart';
|
||||
import '../../../../theme/theme.dart';
|
||||
import '../../../../util/localeManager.dart';
|
||||
import '../../../../util/locale_manager.dart';
|
||||
import '../../../routes/app_pages.dart';
|
||||
import '../controllers/app_controller.dart';
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ import 'package:intl/intl.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
import '../../../../generated/locales.g.dart';
|
||||
import '../../../../util/localeManager.dart';
|
||||
import '../../../../util/locale_manager.dart';
|
||||
import '../../../../util/message.dart';
|
||||
import '../../../../util/package_info.dart';
|
||||
import '../../../../util/util.dart';
|
||||
|
||||
@@ -6,6 +6,7 @@ class AppTranslation {
|
||||
static Map<String, Map<String, String>> translations = {
|
||||
'en_US': Locales.en_US,
|
||||
'fa_IR': Locales.fa_IR,
|
||||
'ja_JP': Locales.ja_JP,
|
||||
'ru_RU': Locales.ru_RU,
|
||||
'zh_CN': Locales.zh_CN,
|
||||
};
|
||||
@@ -197,6 +198,67 @@ class Locales {
|
||||
'newVersionUpdate': 'دریافت اکنون',
|
||||
'newVersionLater': 'بعداً',
|
||||
};
|
||||
static const ja_JP = {
|
||||
'label': '日本語',
|
||||
'error': 'エラー',
|
||||
'tip': 'ヒント',
|
||||
'confirm': '確認',
|
||||
'cancel': 'キャンセル',
|
||||
'selectAll': 'すべてを選択',
|
||||
'task': 'タスク',
|
||||
'downloading': 'ダウンロード中',
|
||||
'downloaded': 'ダウンロード済',
|
||||
'setting': 'セッティング',
|
||||
'donate': '寄付する',
|
||||
'exit': '終了',
|
||||
'create': 'タスクを作成',
|
||||
'downloadLink': 'ダウンロードリンク',
|
||||
'downloadLinkValid': 'ダウンロードリンクを入力してください',
|
||||
'downloadLinkHit': 'ダウンロード リンクを入力してください、HTTP/HTTPS/MAGNET support@append',
|
||||
'downloadLinkHitDesktop': 'または、torrent ファイルを直接ここにドラッグします',
|
||||
'download': 'ダウンロード',
|
||||
'noFileSelected': '続行するには少なくとも 1 つのファイルを選択してください。',
|
||||
'noStoragePermission': 'ストレージのパーミッションが必要',
|
||||
'selectFile': 'ファイルを選択',
|
||||
'basic': 'ベーシック',
|
||||
'advanced': 'アドバンスド',
|
||||
'general': 'ジェネラル',
|
||||
'downloadDir': 'ディレクトリのダウンロード',
|
||||
'downloadDirValid': 'ダウンロードディレクトリを選択してください',
|
||||
'connections': '接続',
|
||||
'maxRunning': '最大実行タスク',
|
||||
'items': '@count アイテム',
|
||||
'subscribeTracker': 'トラッカーを購読',
|
||||
'subscribeFail': '登録に失敗しました。ネットワークを確認するか、後でもう一度お試しください',
|
||||
'update': 'アップデート',
|
||||
'updateDaily': '毎日アップデート',
|
||||
'lastUpdate': '最終アップデート: @time',
|
||||
'addTracker': 'トラッカーを追加',
|
||||
'addTrackerHit': 'トラッカーサーバーの URL を 1 行に 1 つずつ入力してください',
|
||||
'ui': 'UI',
|
||||
'theme': 'テーマ',
|
||||
'themeSystem': 'システム',
|
||||
'themeLight': 'ライト',
|
||||
'themeDark': 'ダーク',
|
||||
'locale': '言語',
|
||||
'about': '概要',
|
||||
'homepage': 'ホームページ',
|
||||
'version': 'バージョン',
|
||||
'protocol': 'プロトコル',
|
||||
'port': 'ポート',
|
||||
'apiToken': 'API トークン',
|
||||
'notSet': '未設置',
|
||||
'set': '設置',
|
||||
'effectAfterRestart': '再起動後の効果',
|
||||
'startAll': 'すべてを開始',
|
||||
'pauseAll': 'すべてを一時停止',
|
||||
'deleteTask': 'タスクを削除',
|
||||
'deleteTaskTip': 'ダウンロードしたファイルを保持',
|
||||
'delete': '削除',
|
||||
'newVersionTitle': '新しいバージョン @version を発見する',
|
||||
'newVersionUpdate': '今すぐダウンロード',
|
||||
'newVersionLater': '後で',
|
||||
};
|
||||
static const ru_RU = {
|
||||
'label': 'Русский(Россия)',
|
||||
'error': 'Ошибка',
|
||||
|
||||
@@ -8,7 +8,7 @@ import 'app/modules/app/controllers/app_controller.dart';
|
||||
import 'app/modules/app/views/app_view.dart';
|
||||
import 'core/libgopeed_boot.dart';
|
||||
import 'generated/locales.g.dart';
|
||||
import 'util/localeManager.dart';
|
||||
import 'util/locale_manager.dart';
|
||||
import 'util/log_util.dart';
|
||||
import 'util/mac_secure_util.dart';
|
||||
import 'util/package_info.dart';
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
Locale toLocale(String key) {
|
||||
final arr = key.split('_');
|
||||
return Locale(arr[0], arr[1]);
|
||||
}
|
||||
|
||||
String getLocaleKey(Locale locale) {
|
||||
return '${locale.languageCode}_${locale.countryCode}';
|
||||
}
|
||||
|
||||
const debugLocale = Locale('zh', 'CN');
|
||||
const fallbackLocale = Locale('en', 'US');
|
||||
Reference in new issue
Block a user