mirror of
https://github.com/nextcloud/android.git
synced 2024-11-25 06:35:48 +03:00
Merge pull request #4947 from nextcloud/fixTime
use SystemClock.elapsedRealtime() everywhere
This commit is contained in:
commit
eb74b5230f
1 changed files with 2 additions and 2 deletions
|
@ -125,7 +125,7 @@ public final class PassCodeManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean passCodeShouldBeRequested(Long timestamp) {
|
private boolean passCodeShouldBeRequested(Long timestamp) {
|
||||||
return (System.currentTimeMillis() - timestamp) > PASS_CODE_TIMEOUT &&
|
return (SystemClock.elapsedRealtime() - timestamp) > PASS_CODE_TIMEOUT &&
|
||||||
visibleActivitiesCounter <= 0 && isPassCodeEnabled();
|
visibleActivitiesCounter <= 0 && isPassCodeEnabled();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -134,7 +134,7 @@ public final class PassCodeManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean deviceCredentialsShouldBeRequested(Long timestamp, Activity activity) {
|
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);
|
deviceCredentialsAreEnabled(activity);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue