Skip to content

Commit

Permalink
Add l10n
Browse files Browse the repository at this point in the history
  • Loading branch information
3003h committed Oct 31, 2024
1 parent 2efde83 commit fad960b
Show file tree
Hide file tree
Showing 15 changed files with 115 additions and 27 deletions.
6 changes: 6 additions & 0 deletions lib/generated/intl/messages_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,8 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("Enter date or offset or gid"),
"expand": MessageLookupByLibrary.simpleMessage("Expand"),
"experimental_feature":
MessageLookupByLibrary.simpleMessage("Experimental feature"),
"export": MessageLookupByLibrary.simpleMessage("Export"),
"export_app_data":
MessageLookupByLibrary.simpleMessage("Export App Data"),
Expand Down Expand Up @@ -299,6 +301,8 @@ class MessageLookup extends MessageLookupByLibrary {
"page_range": MessageLookupByLibrary.simpleMessage("Page range"),
"page_range_error":
MessageLookupByLibrary.simpleMessage("Page range error"),
"page_view_type":
MessageLookupByLibrary.simpleMessage("Page View Type"),
"passwd": MessageLookupByLibrary.simpleMessage("Password"),
"paused": MessageLookupByLibrary.simpleMessage("Paused"),
"phash_block_list":
Expand Down Expand Up @@ -409,6 +413,8 @@ class MessageLookup extends MessageLookupByLibrary {
"show_page_interval":
MessageLookupByLibrary.simpleMessage("Show page interval"),
"skip": MessageLookupByLibrary.simpleMessage("Skip"),
"slide_out_page":
MessageLookupByLibrary.simpleMessage("Slide Out Page"),
"sync_group": MessageLookupByLibrary.simpleMessage("Sync group"),
"sync_history": MessageLookupByLibrary.simpleMessage("Sync history"),
"sync_quick_search":
Expand Down
6 changes: 6 additions & 0 deletions lib/generated/intl/messages_ja.dart
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,8 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("特定の日付やオフセット/GIDを入力"),
"expand": MessageLookupByLibrary.simpleMessage("表示"),
"experimental_feature":
MessageLookupByLibrary.simpleMessage("Experimental feature"),
"export": MessageLookupByLibrary.simpleMessage("エクスポート"),
"export_app_data": MessageLookupByLibrary.simpleMessage("データをエクスポート"),
"export_app_data_summary":
Expand Down Expand Up @@ -264,6 +266,8 @@ class MessageLookup extends MessageLookupByLibrary {
"p_Torrent": MessageLookupByLibrary.simpleMessage("トレント"),
"page_range": MessageLookupByLibrary.simpleMessage("ページ範囲"),
"page_range_error": MessageLookupByLibrary.simpleMessage("入力範囲エラー"),
"page_view_type":
MessageLookupByLibrary.simpleMessage("Page View Type"),
"passwd": MessageLookupByLibrary.simpleMessage("パスワード"),
"paused": MessageLookupByLibrary.simpleMessage("一時停止"),
"phash_block_list": MessageLookupByLibrary.simpleMessage("ブロックリスト"),
Expand Down Expand Up @@ -356,6 +360,8 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage("アップローダのコメントのみ"),
"show_page_interval": MessageLookupByLibrary.simpleMessage("間紙"),
"skip": MessageLookupByLibrary.simpleMessage("スキップ"),
"slide_out_page":
MessageLookupByLibrary.simpleMessage("Slide Out Page"),
"sync_group": MessageLookupByLibrary.simpleMessage("グループ同期"),
"sync_history": MessageLookupByLibrary.simpleMessage("履歴同期"),
"sync_quick_search": MessageLookupByLibrary.simpleMessage("クイック検索同期"),
Expand Down
6 changes: 6 additions & 0 deletions lib/generated/intl/messages_ko_KR.dart
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,8 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("Enter date or offset or gid"),
"expand": MessageLookupByLibrary.simpleMessage("펼치기"),
"experimental_feature":
MessageLookupByLibrary.simpleMessage("Experimental feature"),
"export": MessageLookupByLibrary.simpleMessage("Export"),
"export_app_data":
MessageLookupByLibrary.simpleMessage("Export App Data"),
Expand Down Expand Up @@ -277,6 +279,8 @@ class MessageLookup extends MessageLookupByLibrary {
"p_Torrent": MessageLookupByLibrary.simpleMessage("토렌트"),
"page_range": MessageLookupByLibrary.simpleMessage("페이지 범위"),
"page_range_error": MessageLookupByLibrary.simpleMessage("페이지 범위 오류"),
"page_view_type":
MessageLookupByLibrary.simpleMessage("Page View Type"),
"passwd": MessageLookupByLibrary.simpleMessage("비밀번호"),
"paused": MessageLookupByLibrary.simpleMessage("Paused"),
"phash_block_list":
Expand Down Expand Up @@ -373,6 +377,8 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage("Show Only Uploader Comment"),
"show_page_interval": MessageLookupByLibrary.simpleMessage("페이지 간격 표시"),
"skip": MessageLookupByLibrary.simpleMessage("Skip"),
"slide_out_page":
MessageLookupByLibrary.simpleMessage("Slide Out Page"),
"sync_group": MessageLookupByLibrary.simpleMessage("Sync group"),
"sync_history": MessageLookupByLibrary.simpleMessage("Sync history"),
"sync_quick_search":
Expand Down
6 changes: 6 additions & 0 deletions lib/generated/intl/messages_ru.dart
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("Enter date or offset or gid"),
"expand": MessageLookupByLibrary.simpleMessage("Показать"),
"experimental_feature":
MessageLookupByLibrary.simpleMessage("Experimental feature"),
"export": MessageLookupByLibrary.simpleMessage("Экспортировать"),
"export_app_data":
MessageLookupByLibrary.simpleMessage("Export App Data"),
Expand Down Expand Up @@ -310,6 +312,8 @@ class MessageLookup extends MessageLookupByLibrary {
"page_range": MessageLookupByLibrary.simpleMessage("Диапазон страниц"),
"page_range_error":
MessageLookupByLibrary.simpleMessage("Ошибка в диапазоне страниц"),
"page_view_type":
MessageLookupByLibrary.simpleMessage("Page View Type"),
"passwd": MessageLookupByLibrary.simpleMessage("Пароль"),
"paused": MessageLookupByLibrary.simpleMessage("На паузе"),
"phash_block_list":
Expand Down Expand Up @@ -425,6 +429,8 @@ class MessageLookup extends MessageLookupByLibrary {
"show_page_interval": MessageLookupByLibrary.simpleMessage(
"Показывать интервал между страницами"),
"skip": MessageLookupByLibrary.simpleMessage("Пропустить"),
"slide_out_page":
MessageLookupByLibrary.simpleMessage("Slide Out Page"),
"sync_group":
MessageLookupByLibrary.simpleMessage("Синхронизация группы"),
"sync_history":
Expand Down
3 changes: 3 additions & 0 deletions lib/generated/intl/messages_zh_CN.dart
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("输入具体日期或偏移量 / GID"),
"expand": MessageLookupByLibrary.simpleMessage("展开"),
"experimental_feature": MessageLookupByLibrary.simpleMessage("实验性功能"),
"export": MessageLookupByLibrary.simpleMessage("导出"),
"export_app_data": MessageLookupByLibrary.simpleMessage("导出应用数据"),
"export_app_data_summary":
Expand Down Expand Up @@ -249,6 +250,7 @@ class MessageLookup extends MessageLookupByLibrary {
"p_Torrent": MessageLookupByLibrary.simpleMessage("种子"),
"page_range": MessageLookupByLibrary.simpleMessage("跳转范围"),
"page_range_error": MessageLookupByLibrary.simpleMessage("输入范围有误"),
"page_view_type": MessageLookupByLibrary.simpleMessage("页面视图类型"),
"passwd": MessageLookupByLibrary.simpleMessage("密码"),
"paused": MessageLookupByLibrary.simpleMessage("已暂停"),
"phash_block_list": MessageLookupByLibrary.simpleMessage("感知哈希屏蔽列表"),
Expand Down Expand Up @@ -332,6 +334,7 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage("仅显示上传者评论"),
"show_page_interval": MessageLookupByLibrary.simpleMessage("显示页面间隔"),
"skip": MessageLookupByLibrary.simpleMessage("跳过"),
"slide_out_page": MessageLookupByLibrary.simpleMessage("拖动返回"),
"sync_group": MessageLookupByLibrary.simpleMessage("同步分组"),
"sync_history": MessageLookupByLibrary.simpleMessage("同步历史记录"),
"sync_quick_search": MessageLookupByLibrary.simpleMessage("同步快速搜索"),
Expand Down
6 changes: 6 additions & 0 deletions lib/generated/intl/messages_zh_TW.dart
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,8 @@ class MessageLookup extends MessageLookupByLibrary {
"enter_date_or_offset_or_gid":
MessageLookupByLibrary.simpleMessage("輸入具體日期或偏移量 / GID"),
"expand": MessageLookupByLibrary.simpleMessage("Expand"),
"experimental_feature":
MessageLookupByLibrary.simpleMessage("Experimental feature"),
"export": MessageLookupByLibrary.simpleMessage("導出"),
"export_app_data": MessageLookupByLibrary.simpleMessage("導出應用數據"),
"export_app_data_summary":
Expand Down Expand Up @@ -264,6 +266,8 @@ class MessageLookup extends MessageLookupByLibrary {
"p_Torrent": MessageLookupByLibrary.simpleMessage("種子"),
"page_range": MessageLookupByLibrary.simpleMessage("頁數範圍"),
"page_range_error": MessageLookupByLibrary.simpleMessage("頁數範圍錯誤"),
"page_view_type":
MessageLookupByLibrary.simpleMessage("Page View Type"),
"passwd": MessageLookupByLibrary.simpleMessage("密碼"),
"paused": MessageLookupByLibrary.simpleMessage("暫停"),
"phash_block_list": MessageLookupByLibrary.simpleMessage("感知哈希屏蔽列表"),
Expand Down Expand Up @@ -352,6 +356,8 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage("Show Only Uploader Comment"),
"show_page_interval": MessageLookupByLibrary.simpleMessage("顯示頁面間隔"),
"skip": MessageLookupByLibrary.simpleMessage("跳過"),
"slide_out_page":
MessageLookupByLibrary.simpleMessage("Slide Out Page"),
"sync_group": MessageLookupByLibrary.simpleMessage("同步分组"),
"sync_history": MessageLookupByLibrary.simpleMessage("同步紀錄"),
"sync_quick_search": MessageLookupByLibrary.simpleMessage("同步快速搜索"),
Expand Down
31 changes: 31 additions & 0 deletions lib/generated/l10n.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion lib/l10n/intl_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "Title",
"comment": "Comment",
"commentator": "Commentator",
"regex_format_error": "Regex format error"
"regex_format_error": "Regex format error",
"experimental_feature": "Experimental feature",
"page_view_type": "Page View Type",
"slide_out_page": "Slide Out Page"
}
5 changes: 4 additions & 1 deletion lib/l10n/intl_ja.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "タイトル",
"comment": "コメント",
"commentator": "コメンター",
"regex_format_error": "Regexフォーマットエラー"
"regex_format_error": "Regexフォーマットエラー",
"experimental_feature": "Experimental feature",
"page_view_type": "Page View Type",
"slide_out_page": "Slide Out Page"
}
5 changes: 4 additions & 1 deletion lib/l10n/intl_ko_KR.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "Title",
"comment": "Comment",
"commentator": "Commentator",
"regex_format_error": "Regex format error"
"regex_format_error": "Regex format error",
"experimental_feature": "Experimental feature",
"page_view_type": "Page View Type",
"slide_out_page": "Slide Out Page"
}
5 changes: 4 additions & 1 deletion lib/l10n/intl_ru.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "Title",
"comment": "Comment",
"commentator": "Commentator",
"regex_format_error": "Regex format error"
"regex_format_error": "Regex format error",
"experimental_feature": "Experimental feature",
"page_view_type": "Page View Type",
"slide_out_page": "Slide Out Page"
}
5 changes: 4 additions & 1 deletion lib/l10n/intl_zh_CN.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "标题",
"comment": "评论",
"commentator": "评论者",
"regex_format_error": "正则表达式格式错误"
"regex_format_error": "正则表达式格式错误",
"experimental_feature": "实验性功能",
"page_view_type": "页面视图类型",
"slide_out_page": "拖动返回"
}
5 changes: 4 additions & 1 deletion lib/l10n/intl_zh_TW.arb
Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,8 @@
"title": "标题",
"comment": "评论",
"commentator": "评论者",
"regex_format_error": "Regex format error"
"regex_format_error": "Regex format error",
"experimental_feature": "Experimental feature",
"page_view_type": "Page View Type",
"slide_out_page": "Slide Out Page"
}
15 changes: 6 additions & 9 deletions lib/pages/image_view/view/view_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -661,13 +661,10 @@ class _ViewLoadingLine extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Container(
// constraints: BoxConstraints(
// maxHeight: context.mediaQueryShortestSide,
// minWidth: context.width / 2 - kPageViewPadding,
// ),
// width: context.width / 2 - kPageViewPadding,
// height: 90,
// width: 90,
constraints: BoxConstraints(
maxHeight: context.mediaQueryShortestSide,
minWidth: context.width / 2 - kPageViewPadding,
),
alignment: Alignment.center,
child: SizedBox(
width: (context.width * 0.5) + 100 - kPageViewPadding,
Expand Down Expand Up @@ -945,10 +942,10 @@ class ViewTopBar extends GetView<ViewExtController> {
onTap: () {
controller.tapShare(context);
},
child: SizedBox(
child: const SizedBox(
width: 40,
height: kBottomBarButtonHeight,
child: const Icon(
child: Icon(
FontAwesomeIcons.share,
color: CupertinoColors.systemGrey6,
size: 22,
Expand Down
33 changes: 21 additions & 12 deletions lib/pages/setting/read_setting_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ class ReadSettingList extends StatelessWidget {
),

SliverCupertinoListSection.listInsetGrouped(
footer: const Text('Experimental feature'),
footer: Text(L10n.of(context).experimental_feature),
children: [
_buildPageTypeItem(context),
_buildEnableSlideOutPageItem(context),
Expand Down Expand Up @@ -157,19 +157,23 @@ Widget _buildPageTypeItem(
PageViewType.preloadPageView: 'PreloadPageView',
};

// final EhSettingService ehSettingService = Get.find();
final ViewExtController viewExtController = Get.find();
final EhSettingService ehSettingService = Get.find();
// final ViewExtController viewExtController = Get.find();

return Obx(() {
return SelectorCupertinoListTile<PageViewType>(
// key: UniqueKey(),
title: 'PageViewType',
title: L10n.of(context).page_view_type,
actionMap: actionMap,
simpleActionMap: simpleActionMap,
initVal: viewExtController.pageViewType,
initVal: ehSettingService.pageViewType,
onValueChanged: (val) {
viewExtController.pageViewType = val;
viewExtController.update([idSlidePage]);
ehSettingService.pageViewType = val;
// viewExtController.update([idSlidePage]);
if (Get.isRegistered<ViewExtController>()) {
Get.find<ViewExtController>().resetPageController();
Get.find<ViewExtController>().update([idSlidePage]);
}
},
);
});
Expand All @@ -178,16 +182,21 @@ Widget _buildPageTypeItem(
Widget _buildEnableSlideOutPageItem(
BuildContext context,
) {
final ViewExtController viewExtController = Get.find();
// final ViewExtController viewExtController = Get.find();
final EhSettingService ehSettingService = Get.find();

return EhCupertinoListTile(
title: Text('Slide Out Page'),
title: Text(L10n.of(context).slide_out_page),
trailing: Obx(() {
return CupertinoSwitch(
value: viewExtController.enableSlideOutPage,
value: ehSettingService.enableSlideOutPage,
onChanged: (val) {
viewExtController.enableSlideOutPage = val;
viewExtController.update([idSlidePage]);
ehSettingService.enableSlideOutPage = val;
if (Get.isRegistered<ViewExtController>()) {
Get.find<ViewExtController>().resetPageController();
Get.find<ViewExtController>()
.update([idSlidePage, idImagePageView]);
}
},
);
}),
Expand Down

0 comments on commit fad960b

Please sign in to comment.