Skip to content

Commit 3408542

Browse files
committed
Merge branch 'crash-in-devicelistscreen-on-googletv-droid-1236'
2 parents 733c212 + 84933cb commit 3408542

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

android/app/src/androidTest/kotlin/net/mullvad/mullvadvpn/compose/screen/VpnSettingsScreenTest.kt

+1-4
Original file line numberDiff line numberDiff line change
@@ -271,10 +271,7 @@ class VpnSettingsScreenTest {
271271
)
272272

273273
// Assert
274-
onNodeWithTagAndText(
275-
testTag = String.format(LAZY_LIST_UDP_OVER_TCP_PORT_ITEM_X_TEST_TAG, 5001),
276-
text = "5001"
277-
)
274+
onNodeWithTag(String.format(LAZY_LIST_UDP_OVER_TCP_PORT_ITEM_X_TEST_TAG, 5001))
278275
.assertExists()
279276
.performClick()
280277

android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/BaseCell.kt

+9-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,15 @@ internal fun BaseCell(
7373
horizontalArrangement = Arrangement.Start,
7474
modifier =
7575
modifier
76-
.clickable(isRowEnabled, onClick = onCellClicked)
76+
// This is to avoid a crash when a child view is focused and clickable is set to
77+
// false on the parent view
78+
.then(
79+
if (isRowEnabled) {
80+
Modifier.clickable(onClick = onCellClicked)
81+
} else {
82+
Modifier
83+
}
84+
)
7785
.wrapContentHeight()
7886
.defaultMinSize(minHeight = minHeight)
7987
.fillMaxWidth()

0 commit comments

Comments
 (0)