1. remove checkmarks fix

This commit is contained in:
vadym 2020-08-23 21:38:43 +03:00
parent fd8742f513
commit 0c5a3b0f82

View File

@ -57,15 +57,13 @@ class SelectPeerInfoListAdapter(
peerInfoHolder.peerInfoText.setTextColor(Color.WHITE) peerInfoHolder.peerInfoText.setTextColor(Color.WHITE)
} }
peerInfoHolder.checkbox.setOnCheckedChangeListener { _, isChecked -> peerInfoHolder.checkbox.setOnCheckedChangeListener { _, isChecked ->
if(!isLoading) { if (isChecked) {
if (isChecked) { if (!currentPeers.contains(currentPeer)) {
if (!currentPeers.contains(currentPeer)) { currentPeers.add(currentPeer)
currentPeers.add(currentPeer) }
} } else {
} else { if (currentPeers.contains(currentPeer)) {
if (currentPeers.contains(currentPeer)) { currentPeers.remove(currentPeer)
currentPeers.remove(currentPeer)
}
} }
} }
} }