disable Ledger
This commit is contained in:
parent
818b16f654
commit
c21dc53186
|
@ -60,9 +60,6 @@
|
||||||
<category android:name="android.intent.category.BROWSABLE" />
|
<category android:name="android.intent.category.BROWSABLE" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
<meta-data
|
|
||||||
android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED"
|
|
||||||
android:resource="@xml/usb_device_filter" />
|
|
||||||
</activity>
|
</activity>
|
||||||
<activity
|
<activity
|
||||||
android:name=".onboarding.OnBoardingActivity"
|
android:name=".onboarding.OnBoardingActivity"
|
||||||
|
|
|
@ -36,7 +36,7 @@ import java.nio.charset.StandardCharsets;
|
||||||
import timber.log.Timber;
|
import timber.log.Timber;
|
||||||
|
|
||||||
public class Ledger {
|
public class Ledger {
|
||||||
static final public boolean ENABLED = true;
|
static final public boolean ENABLED = false;
|
||||||
// 5:20 is same as wallet2.cpp::restore()
|
// 5:20 is same as wallet2.cpp::restore()
|
||||||
static public final int LOOKAHEAD_ACCOUNTS = 5;
|
static public final int LOOKAHEAD_ACCOUNTS = 5;
|
||||||
static public final int LOOKAHEAD_SUBADDRESSES = 20;
|
static public final int LOOKAHEAD_SUBADDRESSES = 20;
|
||||||
|
|
|
@ -53,6 +53,7 @@ public class LegacyStorageHelper {
|
||||||
public void migrate() {
|
public void migrate() {
|
||||||
String addressPrefix = WalletManager.getInstance().addressPrefix();
|
String addressPrefix = WalletManager.getInstance().addressPrefix();
|
||||||
File[] wallets = srcDir.listFiles((dir, filename) -> filename.endsWith(".keys"));
|
File[] wallets = srcDir.listFiles((dir, filename) -> filename.endsWith(".keys"));
|
||||||
|
if (wallets == null) return;
|
||||||
for (File wallet : wallets) {
|
for (File wallet : wallets) {
|
||||||
final String walletName = wallet.getName().substring(0, wallet.getName().length() - ".keys".length());
|
final String walletName = wallet.getName().substring(0, wallet.getName().length() - ".keys".length());
|
||||||
if (addressPrefix.indexOf(getAddress(walletName).charAt(0)) < 0) {
|
if (addressPrefix.indexOf(getAddress(walletName).charAt(0)) < 0) {
|
||||||
|
|
|
@ -30,6 +30,7 @@ import androidx.fragment.app.FragmentManager;
|
||||||
|
|
||||||
import com.m2049r.xmrwallet.R;
|
import com.m2049r.xmrwallet.R;
|
||||||
import com.m2049r.xmrwallet.dialog.HelpFragment;
|
import com.m2049r.xmrwallet.dialog.HelpFragment;
|
||||||
|
import com.m2049r.xmrwallet.ledger.Ledger;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -52,6 +53,7 @@ public class Notice {
|
||||||
R.string.help_xmrto,
|
R.string.help_xmrto,
|
||||||
1)
|
1)
|
||||||
);
|
);
|
||||||
|
if (Ledger.ENABLED)
|
||||||
notices.add(
|
notices.add(
|
||||||
new Notice(NOTICE_SHOW_LEDGER,
|
new Notice(NOTICE_SHOW_LEDGER,
|
||||||
R.string.info_ledger_enabled,
|
R.string.info_ledger_enabled,
|
||||||
|
|
Loading…
Reference in New Issue