fix: blocked contacts click handler being overridden by something

This commit is contained in:
0x330a 2023-07-04 11:23:55 +10:00
parent 7ff45cde86
commit 608572fc42
3 changed files with 5 additions and 4 deletions

View File

@ -3,9 +3,9 @@ package org.thoughtcrime.securesms.preferences
import android.content.Context
import android.content.Intent
import android.util.AttributeSet
import android.view.View
import androidx.preference.PreferenceCategory
import androidx.preference.PreferenceViewHolder
import network.loki.messenger.databinding.BlockedContactsPreferenceBinding
class BlockedContactsPreference @JvmOverloads constructor(
context: Context,
@ -14,8 +14,8 @@ class BlockedContactsPreference @JvmOverloads constructor(
override fun onBindViewHolder(holder: PreferenceViewHolder) {
super.onBindViewHolder(holder)
holder.itemView.setOnClickListener {
val binding = BlockedContactsPreferenceBinding.bind(holder.itemView)
binding.blockedContactButton.setOnClickListener {
val intent = Intent(context, BlockedContactsActivity::class.java)
context.startActivity(intent)
}

View File

@ -5,6 +5,7 @@
android:layout_marginVertical="@dimen/medium_spacing"
android:layout_height="wrap_content">
<Button
android:id="@+id/blockedContactButton"
android:contentDescription="@string/AccessibilityId_blocked_contacts"
style="@style/Widget.Session.Button.Common.Borderless"
android:layout_width="wrap_content"

View File

@ -81,7 +81,7 @@ class ClosedGroupPollerV2 {
val groupID = GroupUtil.doubleEncodeGroupID(groupPublicKey)
val threadID = storage.getThreadId(groupID)
if (threadID == null) {
Log.d("Loki", "Stopping group poller due to missing thread for closed group: $groupPublicKey.")
Log.d("Loki", "Stopping group poller due to missing thread for closed group: ${groupPublicKey.take(4)}...${groupPublicKey.takeLast(4)}.")
stopPolling(groupPublicKey)
return
}