From 534cee187b73783e065488037799335b64af101f Mon Sep 17 00:00:00 2001 From: Javier Varona Date: Wed, 21 Nov 2018 22:27:09 -0400 Subject: [PATCH] - Fixed send button doing nothing when there's no pin or pattern configured --- .../cy/agorise/crystalwallet/activities/IntroActivity.java | 4 ++++ .../crystalwallet/application/CrystalSecurityMonitor.java | 2 ++ 2 files changed, 6 insertions(+) diff --git a/app/src/main/java/cy/agorise/crystalwallet/activities/IntroActivity.java b/app/src/main/java/cy/agorise/crystalwallet/activities/IntroActivity.java index d8bfc68..704354f 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/activities/IntroActivity.java +++ b/app/src/main/java/cy/agorise/crystalwallet/activities/IntroActivity.java @@ -17,6 +17,7 @@ import butterknife.BindView; import butterknife.ButterKnife; import butterknife.OnClick; import cy.agorise.crystalwallet.R; +import cy.agorise.crystalwallet.application.CrystalSecurityMonitor; import cy.agorise.crystalwallet.fragments.ImportAccountOptionsFragment; import cy.agorise.crystalwallet.viewmodels.AccountSeedListViewModel; @@ -69,6 +70,9 @@ public class IntroActivity extends CustomActivity { } } ); + + this.getApplication().registerActivityLifecycleCallbacks(CrystalSecurityMonitor.getInstance(this)); + //Checks if the user has any seed created AccountSeedListViewModel accountSeedListViewModel = ViewModelProviders.of(this).get(AccountSeedListViewModel.class); diff --git a/app/src/main/java/cy/agorise/crystalwallet/application/CrystalSecurityMonitor.java b/app/src/main/java/cy/agorise/crystalwallet/application/CrystalSecurityMonitor.java index 9f6297b..b0fa597 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/application/CrystalSecurityMonitor.java +++ b/app/src/main/java/cy/agorise/crystalwallet/application/CrystalSecurityMonitor.java @@ -175,6 +175,8 @@ public class CrystalSecurityMonitor implements Application.ActivityLifecycleCall if(onResponsePattern != null){ PatternRequestActivity.setOnResponse(onResponsePattern); } + } else { + onResponsePattern.onSuccess(); } if (intent != null) { intent.putExtra("ACTIVITY_TYPE", "PASSWORD_REQUEST");