Forced to focus the EditText field and show the keyboard in the PINSecurityLockDialog as soon as it opens.
This commit is contained in:
parent
2a869d7fe8
commit
d20183e36f
1 changed files with 5 additions and 0 deletions
|
@ -5,6 +5,7 @@ import android.preference.PreferenceManager
|
|||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.view.WindowManager
|
||||
import android.view.inputmethod.EditorInfo
|
||||
import com.jakewharton.rxbinding3.widget.textChanges
|
||||
import cy.agorise.bitsybitshareswallet.R
|
||||
|
@ -33,6 +34,10 @@ class PINSecurityLockDialog : BaseSecurityLockDialog() {
|
|||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
||||
super.onViewCreated(view, savedInstanceState)
|
||||
|
||||
// Request focus to the PIN EditText and automatically show the keyboard when the dialog appears.
|
||||
tietPIN.requestFocus()
|
||||
dialog.window?.setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_VISIBLE)
|
||||
|
||||
setupScreen()
|
||||
|
||||
// Listens to the event when the user clicks the 'Enter' button in the keyboard and acts accordingly
|
||||
|
|
Loading…
Reference in a new issue