123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141 |
- // GENERATED CODE - DO NOT MODIFY BY HAND
- import 'package:flutter/material.dart';
- import 'package:intl/intl.dart';
- import 'intl/messages_all.dart';
- // **************************************************************************
- // Generator: Flutter Intl IDE plugin
- // Made by Localizely
- // **************************************************************************
- // ignore_for_file: non_constant_identifier_names, lines_longer_than_80_chars
- // ignore_for_file: join_return_with_assignment, prefer_final_in_for_each
- // ignore_for_file: avoid_redundant_argument_values, avoid_escaping_inner_quotes
- class S {
- S();
- static S? _current;
- static S get current {
- assert(_current != null,
- 'No instance of S was loaded. Try to initialize the S delegate before accessing S.current.');
- return _current!;
- }
- static const AppLocalizationDelegate delegate = AppLocalizationDelegate();
- static Future<S> load(Locale locale) {
- final name = (locale.countryCode?.isEmpty ?? false)
- ? locale.languageCode
- : locale.toString();
- final localeName = Intl.canonicalizedLocale(name);
- return initializeMessages(localeName).then((_) {
- Intl.defaultLocale = localeName;
- final instance = S();
- S._current = instance;
- return instance;
- });
- }
- static S of(BuildContext context) {
- final instance = S.maybeOf(context);
- assert(instance != null,
- 'No instance of S present in the widget tree. Did you add S.delegate in localizationsDelegates?');
- return instance!;
- }
- static S? maybeOf(BuildContext context) {
- return Localizations.of<S>(context, S);
- }
- /// `Payment`
- String get payment {
- return Intl.message(
- 'Payment',
- name: 'payment',
- desc: '',
- args: [],
- );
- }
- /// `Rewards`
- String get rewards {
- return Intl.message(
- 'Rewards',
- name: 'rewards',
- desc: '',
- args: [],
- );
- }
- /// `Notification`
- String get notification {
- return Intl.message(
- 'Notification',
- name: 'notification',
- desc: '',
- args: [],
- );
- }
- /// `Facility`
- String get facility {
- return Intl.message(
- 'Facility',
- name: 'facility',
- desc: '',
- args: [],
- );
- }
- /// `Form`
- String get form {
- return Intl.message(
- 'Form',
- name: 'form',
- desc: '',
- args: [],
- );
- }
- /// `Notice Board`
- String get notice_board {
- return Intl.message(
- 'Notice Board',
- name: 'notice_board',
- desc: '',
- args: [],
- );
- }
- }
- class AppLocalizationDelegate extends LocalizationsDelegate<S> {
- const AppLocalizationDelegate();
- List<Locale> get supportedLocales {
- return const <Locale>[
- Locale.fromSubtags(languageCode: 'en'),
- Locale.fromSubtags(languageCode: 'zh', countryCode: 'CN'),
- Locale.fromSubtags(languageCode: 'zh', countryCode: 'HK'),
- ];
- }
- @override
- bool isSupported(Locale locale) => _isSupported(locale);
- @override
- Future<S> load(Locale locale) => S.load(locale);
- @override
- bool shouldReload(AppLocalizationDelegate old) => false;
- bool _isSupported(Locale locale) {
- for (var supportedLocale in supportedLocales) {
- if (supportedLocale.languageCode == locale.languageCode) {
- return true;
- }
- }
- return false;
- }
- }
|