Added BIP39 traditional Chinese

pull/207/head
M66B 4 years ago
parent eb9f9554b6
commit 19452fb6e6

File diff suppressed because it is too large Load Diff

@ -15,7 +15,10 @@ public class BIP39 {
// https://github.com/bitcoin/bips/tree/master/bip-0039 // https://github.com/bitcoin/bips/tree/master/bip-0039
// https://github.com/bitcoin/bips/pull/1129 // https://github.com/bitcoin/bips/pull/1129
static String getWord(@NonNull Locale locale, int index, Context context) { static String getWord(@NonNull Locale locale, int index, Context context) {
try (InputStream is = context.getAssets().open("bip39/" + locale.getLanguage() + ".txt")) { String lang = locale.getLanguage();
if ("zh".equals(lang) && "CN".equals(locale.getCountry()))
lang = "zh_cn";
try (InputStream is = context.getAssets().open("bip39/" + lang + ".txt")) {
return getWord(is, index); return getWord(is, index);
} catch (Throwable ex) { } catch (Throwable ex) {
Log.w(ex); Log.w(ex);

Loading…
Cancel
Save