Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NEVISACCESSAPP-6111: Fix cooldown timer for last try #22

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* Nevis Mobile Authentication SDK Example App
*
* Copyright © 2023. Nevis Security AG. All rights reserved.
* Copyright © 2023-2024. Nevis Security AG. All rights reserved.
*/

package ch.nevis.exampleapp.ui.credential
Expand Down Expand Up @@ -232,6 +232,7 @@ class CredentialFragment : BaseFragment() {
override fun onFinish() {
setViewState(true)
updateMessage(credentialType, remainingRetries, 0)
timer = null
}
}.start()
}
Expand Down
8 changes: 3 additions & 5 deletions app/src/main/res/layout/item_account.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,14 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?android:selectableItemBackground"
android:padding="16dp"
android:onClick="@{() -> accountSelectedListener.onAccountSelected(account)}">

<TextView
android:id="@+id/usernameTextView"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp"
android:text="@{account.username()}"
android:textSize="16sp"
android:textStyle="bold"
Expand All @@ -34,4 +32,4 @@
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
</layout>
</layout>
10 changes: 3 additions & 7 deletions app/src/main/res/layout/item_authenticator.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,14 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?android:selectableItemBackground"
android:padding="16dp"
android:onClick="@{() -> authenticatorSelectedListener.onAuthenticatorSelected(aaid)}">

<TextView
android:id="@+id/titleTextView"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:layout_marginEnd="16dp"
android:enabled="@{isEnabled}"
android:text="@{titleResId}"
android:textSize="16sp"
Expand All @@ -50,10 +49,7 @@
android:id="@+id/messageTextView"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp"
android:enabled="@{isEnabled}"
android:text='@{message ?? ""}'
android:textSize="14sp"
Expand All @@ -64,4 +60,4 @@
app:layout_constraintTop_toBottomOf="@id/titleTextView" />

</androidx.constraintlayout.widget.ConstraintLayout>
</layout>
</layout>
Loading