mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-02-24 07:28:07 +01:00
Merge pull request #3522 from BlueWallet/Unable-to-Browse-Past-First-Wallet-(Among-Other-Issues)-#3496
FIX: #3496 Unable to Browse Past First Wallet (Among Other Issues) #3496
This commit is contained in:
commit
1dcfda9a59
3 changed files with 19 additions and 9 deletions
|
@ -55,6 +55,7 @@ static void InitializeFlipper(UIApplication *application) {
|
|||
} else {
|
||||
rootView.backgroundColor = [UIColor clearColor];
|
||||
}
|
||||
[[RCTI18nUtil sharedInstance] allowRTL:YES];
|
||||
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
|
||||
UIViewController *rootViewController = [UIViewController new];
|
||||
rootViewController.view = rootView;
|
||||
|
@ -66,7 +67,6 @@ static void InitializeFlipper(UIApplication *application) {
|
|||
// Define UNUserNotificationCenter
|
||||
UNUserNotificationCenter *center = [UNUserNotificationCenter currentNotificationCenter];
|
||||
center.delegate = self;
|
||||
[[RCTI18nUtil sharedInstance] allowRTL:YES];
|
||||
return YES;
|
||||
}
|
||||
|
||||
|
|
|
@ -360,7 +360,7 @@ PODS:
|
|||
- React-cxxreact (= 0.64.2)
|
||||
- React-jsi (= 0.64.2)
|
||||
- React-perflogger (= 0.64.2)
|
||||
- RealmJS (10.6.0):
|
||||
- RealmJS (10.6.1):
|
||||
- GCDWebServer
|
||||
- React
|
||||
- RemobileReactNativeQrcodeLocalImage (1.0.4):
|
||||
|
@ -771,7 +771,7 @@ SPEC CHECKSUMS:
|
|||
React-RCTVibration: 24600e3b1aaa77126989bc58b6747509a1ba14f3
|
||||
React-runtimeexecutor: a9904c6d0218fb9f8b19d6dd88607225927668f9
|
||||
ReactCommon: 149906e01aa51142707a10665185db879898e966
|
||||
RealmJS: c903034b0d767fcef11dc8207e91b6f07e60d7b8
|
||||
RealmJS: 550ecbe8a0d55bd0e2abb79a63313d4da08bcf25
|
||||
RemobileReactNativeQrcodeLocalImage: 57aadc12896b148fb5e04bc7c6805f3565f5c3fa
|
||||
RNCAsyncStorage: 8324611026e8dc3706f829953aa6e3899f581589
|
||||
RNCClipboard: 5df122bc31f95f2b37de9bbadc1dbef5a79cb1b0
|
||||
|
|
22
loc/index.js
22
loc/index.js
|
@ -165,21 +165,31 @@ const setLanguageLocale = async () => {
|
|||
// finding out whether lang preference was saved
|
||||
const lang = await AsyncStorage.getItem(LANG);
|
||||
if (lang) {
|
||||
strings.setLanguage(lang);
|
||||
await strings.saveLanguage(lang);
|
||||
await strings.setLanguage(lang);
|
||||
if (process.env.JEST_WORKER_ID === undefined) {
|
||||
I18nManager.allowRTL(lang.isRTL ?? false);
|
||||
I18nManager.forceRTL(lang.isRTL ?? false);
|
||||
}
|
||||
await setDateTimeLocale();
|
||||
} else {
|
||||
const locales = RNLocalize.getLocales();
|
||||
if (Object.keys(AvailableLanguages).some(language => language === locales[0])) {
|
||||
strings.saveLanguage(locales[0].languageCode);
|
||||
strings.setLanguage(locales[0].languageCode);
|
||||
if (Object.values(AvailableLanguages).some(language => language.value === locales[0].languageCode)) {
|
||||
await strings.saveLanguage(locales[0].languageCode);
|
||||
await strings.setLanguage(locales[0].languageCode);
|
||||
if (process.env.JEST_WORKER_ID === undefined) {
|
||||
I18nManager.allowRTL(locales[0].isRTL ?? false);
|
||||
I18nManager.forceRTL(locales[0].isRTL ?? false);
|
||||
}
|
||||
} else {
|
||||
strings.saveLanguage('en');
|
||||
strings.setLanguage('en');
|
||||
await strings.saveLanguage('en');
|
||||
await strings.setLanguage('en');
|
||||
if (process.env.JEST_WORKER_ID === undefined) {
|
||||
I18nManager.allowRTL(false);
|
||||
I18nManager.forceRTL(false);
|
||||
}
|
||||
}
|
||||
await setDateTimeLocale();
|
||||
}
|
||||
};
|
||||
setLanguageLocale();
|
||||
|
|
Loading…
Add table
Reference in a new issue