summaryrefslogtreecommitdiff
path: root/app/src
diff options
context:
space:
mode:
Diffstat (limited to 'app/src')
-rw-r--r--app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt4
-rw-r--r--app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/ToggleTrackersAdapter.kt4
2 files changed, 4 insertions, 4 deletions
diff --git a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt
index 2fab8cf..4ccdc59 100644
--- a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt
+++ b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt
@@ -93,8 +93,8 @@ class AppTrackersFragment :
binding = ApptrackersFragmentBinding.bind(view)
// TODO: crash sqlite ?
- // binding.blockAllToggle.setOnCheckedChangeListener { _, isChecked ->
- // viewModel.submitAction(Action.BlockAllToggleAction(isChecked))
+ // binding.blockAllToggle.setOnClickListener {
+ // viewModel.submitAction(Action.BlockAllToggleAction(binding.blockAllToggle.isChecked))
// }
binding.trackers.apply {
diff --git a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/ToggleTrackersAdapter.kt b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/ToggleTrackersAdapter.kt
index b1b3ed6..95ea094 100644
--- a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/ToggleTrackersAdapter.kt
+++ b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/ToggleTrackersAdapter.kt
@@ -58,8 +58,8 @@ class ToggleTrackersAdapter(
val view = LayoutInflater.from(parent.context)
.inflate(itemsLayout, parent, false)
val holder = ViewHolder(view)
- holder.toggle.setOnCheckedChangeListener { _, isChecked ->
- listener(dataSet[holder.adapterPosition].first, isChecked)
+ holder.toggle.setOnClickListener {
+ listener(dataSet[holder.adapterPosition].first, holder.toggle.isChecked)
}
return holder
}