Inline the call links feature flag.

This commit is contained in:
Greyson Parrelli
2024-10-16 15:41:08 -04:00
parent 69b506db1c
commit 262b359c3f
4 changed files with 3 additions and 32 deletions

View File

@@ -412,10 +412,6 @@ public class WebRtcCallActivity extends BaseActivity implements SafetyNumberChan
}
private void initializePendingParticipantFragmentListener() {
if (!RemoteConfig.adHocCalling()) {
return;
}
getSupportFragmentManager().setFragmentResultListener(
PendingParticipantsBottomSheet.REQUEST_KEY,
this,

View File

@@ -63,7 +63,6 @@ import org.thoughtcrime.securesms.recipients.Recipient
import org.thoughtcrime.securesms.stories.tabs.ConversationListTab
import org.thoughtcrime.securesms.stories.tabs.ConversationListTabsViewModel
import org.thoughtcrime.securesms.util.CommunicationActions
import org.thoughtcrime.securesms.util.RemoteConfig
import org.thoughtcrime.securesms.util.ViewUtil
import org.thoughtcrime.securesms.util.doAfterNextLayout
import org.thoughtcrime.securesms.util.fragments.requireListener
@@ -259,13 +258,7 @@ class CallLogFragment : Fragment(R.layout.call_log_fragment), CallLogAdapter.Cal
val count = callLogActionMode.getCount()
MaterialAlertDialogBuilder(requireContext())
.setTitle(resources.getQuantityString(R.plurals.CallLogFragment__delete_d_calls, count, count))
.setMessage(
if (RemoteConfig.adHocCalling) {
getString(R.string.CallLogFragment__call_links_youve_created)
} else {
null
}
)
.setMessage(getString(R.string.CallLogFragment__call_links_youve_created))
.setPositiveButton(R.string.CallLogFragment__delete) { _, _ ->
performDeletion(count, viewModel.stageSelectionDeletion())
callLogActionMode.end()
@@ -416,13 +409,7 @@ class CallLogFragment : Fragment(R.layout.call_log_fragment), CallLogAdapter.Cal
override fun deleteCall(call: CallLogRow) {
MaterialAlertDialogBuilder(requireContext())
.setTitle(resources.getQuantityString(R.plurals.CallLogFragment__delete_d_calls, 1, 1))
.setMessage(
if (RemoteConfig.adHocCalling) {
getString(R.string.CallLogFragment__call_links_youve_created)
} else {
null
}
)
.setMessage(getString(R.string.CallLogFragment__call_links_youve_created))
.setPositiveButton(R.string.CallLogFragment__delete) { _, _ ->
performDeletion(1, viewModel.stageCallDeletion(call))
}

View File

@@ -1,7 +1,6 @@
package org.thoughtcrime.securesms.calls.log
import org.signal.paging.PagedDataSource
import org.thoughtcrime.securesms.util.RemoteConfig
class CallLogPagedDataSource(
private val query: String?,
@@ -10,7 +9,7 @@ class CallLogPagedDataSource(
) : PagedDataSource<CallLogRow.Id, CallLogRow> {
private val hasFilter = filter == CallLogFilter.MISSED
private val hasCallLinkRow = RemoteConfig.adHocCalling && filter == CallLogFilter.ALL && query.isNullOrEmpty()
private val hasCallLinkRow = filter == CallLogFilter.ALL && query.isNullOrEmpty()
private var callEventsCount = 0
private var callLinksCount = 0

View File

@@ -846,17 +846,6 @@ object RemoteConfig {
sticky = true
)
/**
* Whether or not ad-hoc calling is enabled
*/
@JvmStatic
@get:JvmName("adHocCalling")
val adHocCalling: Boolean by remoteBoolean(
key = "android.calling.ad.hoc.3",
defaultValue = false,
hotSwappable = false
)
/** Maximum number of attachments allowed to be sent/received. */
val maxAttachmentCount: Int by remoteInt(
key = "android.attachments.maxCount",