Closed edenman closed 2 months ago
heh, it is. It's this
/** Clears the current click listener and sets `isClickable` to false. */
@SuppressLint("DenyListedApi") // This is the one place we allow it
fun View.clearOnClickListener() {
setOnClickListener(null)
isClickable = false
}
/** Clears the current long click listener and sets `isLongClickable` to false. */
@SuppressLint("DenyListedApi") // This is the one place we allow it
fun View.clearOnLongClickListener() {
setOnLongClickListener(null)
isLongClickable = false
}
Another internal thing that leaked is #plz-localization 😂 https://github.com/slackhq/slack-lints/blob/b90f36da013953656f88ecbf163d8021082bcae8/slack-lint-checks/src/main/java/slack/lint/ArgInFormattedQuantityStringResDetector.kt#L32
This fails to also set View#isClickable. Use View#clearOnClickListener() instead
https://github.com/slackhq/slack-lints/blob/main/slack-lint-checks/src/main/java/slack/lint/denylistedapis/DenyListedApiDetector.kt#L301
Is this some internal thing that leaked out?