mirror of
https://github.com/oxen-io/session-android.git
synced 2025-12-09 22:52:56 +00:00
Add legacy and pre-release ui updates
This commit is contained in:
@@ -75,7 +75,12 @@ class ExpirationSettingsActivity: PassphraseRequiredActionBarActivity() {
|
||||
}
|
||||
|
||||
val deleteTypeOptions = listOf(
|
||||
RadioOption("off", getString(R.string.expiration_off)),
|
||||
RadioOption(value = "-1", title = getString(R.string.expiration_off)),
|
||||
RadioOption(
|
||||
value = "0",
|
||||
title = getString(R.string.expiration_type_disappear_legacy),
|
||||
subtitle = getString(R.string.expiration_type_disappear_legacy_description)
|
||||
),
|
||||
RadioOption(
|
||||
value = ExpirationType.DELETE_AFTER_READ_VALUE.toString(),
|
||||
title = getString(R.string.expiration_type_disappear_after_read),
|
||||
|
||||
@@ -362,6 +362,7 @@ class ConversationActivityV2 : PassphraseRequiredActionBarActivity(), InputBarDe
|
||||
setUpRecipientObserver()
|
||||
getLatestOpenGroupInfoIfNeeded()
|
||||
setUpBlockedBanner()
|
||||
setUpOutdatedClientBanner();
|
||||
binding!!.searchBottomBar.setEventListener(this)
|
||||
setUpSearchResultObserver()
|
||||
scrollToFirstUnreadMessageIfNeeded()
|
||||
@@ -567,6 +568,13 @@ class ConversationActivityV2 : PassphraseRequiredActionBarActivity(), InputBarDe
|
||||
binding?.blockedBanner?.setOnClickListener { viewModel.unblock() }
|
||||
}
|
||||
|
||||
private fun setUpOutdatedClientBanner() {
|
||||
val recipient = viewModel.recipient ?: return
|
||||
if (recipient.expireMessages == 0) { return }
|
||||
binding?.outdatedBannerTextView?.text = resources.getString(R.string.activity_conversation_outdated_client_banner_text)
|
||||
binding?.outdatedBanner?.isVisible = true
|
||||
}
|
||||
|
||||
private fun setUpLinkPreviewObserver() {
|
||||
if (!textSecurePreferences.isLinkPreviewsEnabled()) {
|
||||
linkPreviewViewModel.onUserCancel(); return
|
||||
|
||||
Reference in New Issue
Block a user