This repository was archived by the owner on Apr 29, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +15
-4
lines changed
mifos-passcode/src/main/java/com/mifos/mobile/passcode Expand file tree Collapse file tree 2 files changed +15
-4
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,5 @@ dependencies {
2424 testImplementation ' junit:junit:4.12'
2525 androidTestImplementation ' com.android.support.test:runner:1.0.1'
2626 androidTestImplementation ' com.android.support.test.espresso:espresso-core:3.0.1'
27- // implementation project(':mifos-passcode')
28- implementation ' com.mifos.mobile:mifos-passcode:0.3.0'
27+ implementation project(' :mifos-passcode' )
2928}
Original file line number Diff line number Diff line change 33import android .content .Context ;
44import android .content .Intent ;
55import android .os .Bundle ;
6+ import android .os .CountDownTimer ;
67import android .support .v4 .content .ContextCompat ;
78import android .support .v4 .widget .NestedScrollView ;
89import android .support .v7 .app .AppCompatActivity ;
@@ -37,6 +38,7 @@ public abstract class MifosPassCodeActivity extends AppCompatActivity implements
3738 private boolean isPassCodeVerified ;
3839 private String strPassCodeEntered ;
3940 private PasscodePreferencesHelper passcodePreferencesHelper ;
41+ private final long TIME_DELAY = 100 ;
4042
4143 public abstract int getLogo ();
4244
@@ -166,8 +168,18 @@ public void passCodeEntered(String passcode) {
166168 } else {
167169 mifosPassCodeView .startAnimation (shakeAnimation );
168170 counter ++;
169- mifosPassCodeView .clearPasscodeField ();
170- showToaster (clRootview , R .string .incorrect_passcode );
171+ new CountDownTimer (TIME_DELAY ,TIME_DELAY ) {
172+ @ Override
173+ public void onTick (long millisUntilFinished ) {
174+
175+ }
176+
177+ @ Override
178+ public void onFinish () {
179+ mifosPassCodeView .clearPasscodeField ();
180+ showToaster (clRootview , R .string .incorrect_passcode );
181+ }
182+ }.start ();
171183 }
172184 }
173185 }
You can’t perform that action at this time.
0 commit comments