Fix app locking even if app lock is disabled
Hide fingerprint view if fingerprint is disabled
This commit is contained in:
parent
d03c49db58
commit
e7c48a98df
@ -158,15 +158,16 @@ class MainActivity : BaseActivity() {
|
||||
// --> EH
|
||||
//Hook long press hamburger menu to lock
|
||||
getToolbarNavigationIcon(toolbar)?.setOnLongClickListener {
|
||||
if(lockEnabled(preferences)) {
|
||||
doLock(true)
|
||||
vibrate(50) // Notify user of lock
|
||||
true
|
||||
} else false
|
||||
}
|
||||
|
||||
//Show lock
|
||||
if (savedInstanceState == null) {
|
||||
val lockEnabled = lockEnabled(preferences)
|
||||
if (lockEnabled) {
|
||||
if (lockEnabled(preferences)) {
|
||||
//Special case first lock
|
||||
doLock()
|
||||
|
||||
|
@ -74,6 +74,7 @@ class LockController : NucleusController<LockPresenter>() {
|
||||
with(view) {
|
||||
//Fingerprint
|
||||
if (presenter.useFingerprint) {
|
||||
swirl_container.visibility = View.VISIBLE
|
||||
swirl_container.removeAllViews()
|
||||
val icon = SwirlView(context).apply {
|
||||
val size = dpToPx(context, 60)
|
||||
@ -114,6 +115,8 @@ class LockController : NucleusController<LockPresenter>() {
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
swirl_container.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user