Assigned
Status Update
Comments
ra...@google.com <ra...@google.com>
no...@gmail.com <no...@gmail.com> #2
Seems a duplicate of
ar...@gmail.com <ar...@gmail.com> #3
Any update on this?
ar...@gmail.com <ar...@gmail.com> #4
Also, based on the recent
var isInputEnabled by remember { mutableStateOf(true) }
val scope = rememberCoroutineScope()
SomeWidget(modifier = Modifier.ignoreInput(isIgnored = !isInputEnabled)) {
Button(
onClick = {
isInputEnabled = false
scope.launch {
// Load data
isInputEnabled = true
}
},
)
// More widgets here
}
Description
As described in this slack convo (among other similar convos prior to that one), sometimes a developer wants to disable touch input for an entire part of the UI, even if it includes children that actively try to handle touch events.
For example, this could be a modifier:
Such a feature would probably need to ignore not only touch events, but also any semantics actions coming from the ignored node, and hardware keyboard events, and maybe also disable focus as well.