1
0
Fork 0

For #7753: Increases touch target of crash page

master
Sawyer Blatz 3 years ago committed by Jeff Boek
parent f9b05e7d5a
commit 453231b5fd
  1. 20
      app/src/main/java/org/mozilla/fenix/crashes/CrashReporterFragment.kt

@ -13,6 +13,7 @@ import kotlinx.android.synthetic.main.fragment_crash_reporter.*
import mozilla.components.lib.crash.Crash
import org.mozilla.fenix.R
import org.mozilla.fenix.ext.hideToolbar
import org.mozilla.fenix.ext.increaseTapArea
import org.mozilla.fenix.ext.requireComponents
import org.mozilla.fenix.ext.settings
@ -37,11 +38,18 @@ class CrashReporterFragment : Fragment(R.layout.fragment_crash_reporter) {
settings = requireContext().settings()
)
restoreTabButton.setOnClickListener {
controller.handleCloseAndRestore(sendCrashCheckbox.isChecked)
restoreTabButton.apply {
increaseTapArea(TAP_INCREASE_DP)
setOnClickListener {
controller.handleCloseAndRestore(sendCrashCheckbox.isChecked)
}
}
closeTabButton.setOnClickListener {
controller.handleCloseAndRemove(sendCrashCheckbox.isChecked)
closeTabButton.apply {
increaseTapArea(TAP_INCREASE_DP)
setOnClickListener {
controller.handleCloseAndRemove(sendCrashCheckbox.isChecked)
}
}
}
@ -49,4 +57,8 @@ class CrashReporterFragment : Fragment(R.layout.fragment_crash_reporter) {
super.onResume()
hideToolbar()
}
companion object {
private const val TAP_INCREASE_DP = 12
}
}

Loading…
Cancel
Save