mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-03-02 15:36:32 +00:00
Add recaptcha triggers to CFV2.
This commit is contained in:
@@ -257,6 +257,7 @@ import org.thoughtcrime.securesms.permissions.Permissions
|
||||
import org.thoughtcrime.securesms.profiles.spoofing.ReviewCardDialogFragment
|
||||
import org.thoughtcrime.securesms.providers.BlobProvider
|
||||
import org.thoughtcrime.securesms.ratelimit.RecaptchaProofBottomSheetFragment
|
||||
import org.thoughtcrime.securesms.ratelimit.RecaptchaRequiredEvent
|
||||
import org.thoughtcrime.securesms.reactions.ReactionsBottomSheetDialogFragment
|
||||
import org.thoughtcrime.securesms.reactions.any.ReactWithAnyEmojiBottomSheetDialogFragment
|
||||
import org.thoughtcrime.securesms.recipients.Recipient
|
||||
@@ -613,6 +614,10 @@ class ConversationFragment :
|
||||
}
|
||||
|
||||
ConversationUtil.refreshRecipientShortcuts()
|
||||
|
||||
if (SignalStore.rateLimit().needsRecaptcha()) {
|
||||
RecaptchaProofBottomSheetFragment.show(childFragmentManager)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onPause() {
|
||||
@@ -3967,6 +3972,11 @@ class ConversationFragment :
|
||||
viewModel.refreshReminder()
|
||||
}
|
||||
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
fun onRecaptchaRequiredEvent(recaptchaRequiredEvent: RecaptchaRequiredEvent) {
|
||||
RecaptchaProofBottomSheetFragment.show(childFragmentManager)
|
||||
}
|
||||
|
||||
//endregion
|
||||
|
||||
private inner class SearchEventListener : ConversationSearchBottomBar.EventListener {
|
||||
|
||||
Reference in New Issue
Block a user