use SystemClock.elapsedRealtime() everywhere

Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
This commit is contained in:
tobiasKaminsky 2019-12-05 11:05:47 +01:00
parent 664727b2a6
commit 1584de9769
No known key found for this signature in database
GPG key ID: 0E00D4D47D0C5AF7

View file

@ -125,7 +125,7 @@ public final class PassCodeManager {
}
private boolean passCodeShouldBeRequested(Long timestamp) {
return (System.currentTimeMillis() - timestamp) > PASS_CODE_TIMEOUT &&
return (SystemClock.elapsedRealtime() - timestamp) > PASS_CODE_TIMEOUT &&
visibleActivitiesCounter <= 0 && isPassCodeEnabled();
}
@ -134,7 +134,7 @@ public final class PassCodeManager {
}
private boolean deviceCredentialsShouldBeRequested(Long timestamp, Activity activity) {
return (System.currentTimeMillis() - timestamp) > PASS_CODE_TIMEOUT && visibleActivitiesCounter <= 0 &&
return (SystemClock.elapsedRealtime() - timestamp) > PASS_CODE_TIMEOUT && visibleActivitiesCounter <= 0 &&
deviceCredentialsAreEnabled(activity);
}