# KeyEvent.Callback

Added in[API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  
Summary:[Methods](https://developer.android.com/reference/android/view/KeyEvent.Callback#pubmethods)  

# KeyEvent.Callback

*** ** * ** ***

[Kotlin](https://developer.android.com/reference/kotlin/android/view/KeyEvent.Callback "View this page in Kotlin")\|Java

`
public
static


interface
KeyEvent.Callback
`  
`


`

|--------------------------------|
| android.view.KeyEvent.Callback |

|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Known indirect subclasses [AbsListView](https://developer.android.com/reference/android/widget/AbsListView),[AbsSeekBar](https://developer.android.com/reference/android/widget/AbsSeekBar),[AbsSpinner](https://developer.android.com/reference/android/widget/AbsSpinner),[AbsoluteLayout](https://developer.android.com/reference/android/widget/AbsoluteLayout),[AbstractInputMethodService](https://developer.android.com/reference/android/inputmethodservice/AbstractInputMethodService),[AccountAuthenticatorActivity](https://developer.android.com/reference/android/accounts/AccountAuthenticatorActivity),[ActionMenuView](https://developer.android.com/reference/android/widget/ActionMenuView),[Activity](https://developer.android.com/reference/android/app/Activity),[ActivityGroup](https://developer.android.com/reference/android/app/ActivityGroup),[AdapterView](https://developer.android.com/reference/android/widget/AdapterView)\<T extends[Adapter](https://developer.android.com/reference/android/widget/Adapter)\>,[AdapterViewAnimator](https://developer.android.com/reference/android/widget/AdapterViewAnimator),[AdapterViewFlipper](https://developer.android.com/reference/android/widget/AdapterViewFlipper),[AlertDialog](https://developer.android.com/reference/android/app/AlertDialog),[AliasActivity](https://developer.android.com/reference/android/app/AliasActivity),[AnalogClock](https://developer.android.com/reference/android/widget/AnalogClock), and 92 others. |-------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [AbsListView](https://developer.android.com/reference/android/widget/AbsListView)                                                                                       | Base class that can be used to implement virtualized lists of items.                                                                                                                                                                                                                                                                                                                                                                                                                              | | [AbsSeekBar](https://developer.android.com/reference/android/widget/AbsSeekBar)                                                                                         | AbsSeekBar extends the capabilities of ProgressBar by adding a draggable thumb.                                                                                                                                                                                                                                                                                                                                                                                                                   | | [AbsSpinner](https://developer.android.com/reference/android/widget/AbsSpinner)                                                                                         | An abstract base class for spinner widgets.                                                                                                                                                                                                                                                                                                                                                                                                                                                       | | [AbsoluteLayout](https://developer.android.com/reference/android/widget/AbsoluteLayout)                                                                                 | *This class was deprecated in API level 3. Use[FrameLayout](https://developer.android.com/reference/android/widget/FrameLayout),[RelativeLayout](https://developer.android.com/reference/android/widget/RelativeLayout)or a custom layout instead.*                                                                                                                                                                                                                                               | | [AbstractInputMethodService](https://developer.android.com/reference/android/inputmethodservice/AbstractInputMethodService)                                             | AbstractInputMethodService provides a abstract base class for input methods.                                                                                                                                                                                                                                                                                                                                                                                                                      | | [AccountAuthenticatorActivity](https://developer.android.com/reference/android/accounts/AccountAuthenticatorActivity)                                                   | *This class was deprecated in API level 30. Applications should extend Activity themselves. This class is not compatible with AppCompat, and the functionality it provides is not complex.*                                                                                                                                                                                                                                                                                                       | | [ActionMenuView](https://developer.android.com/reference/android/widget/ActionMenuView)                                                                                 | ActionMenuView is a presentation of a series of menu options as a View.                                                                                                                                                                                                                                                                                                                                                                                                                           | | [Activity](https://developer.android.com/reference/android/app/Activity)                                                                                                | An activity is a single, focused thing that the user can do.                                                                                                                                                                                                                                                                                                                                                                                                                                      | | [ActivityGroup](https://developer.android.com/reference/android/app/ActivityGroup)                                                                                      | *This class was deprecated in API level 13. Use the new[Fragment](https://developer.android.com/reference/android/app/Fragment)and[FragmentManager](https://developer.android.com/reference/android/app/FragmentManager)APIs instead; these are also available on older platforms through the Android compatibility package.*                                                                                                                                                                     | | [AdapterView](https://developer.android.com/reference/android/widget/AdapterView)\<T extends[Adapter](https://developer.android.com/reference/android/widget/Adapter)\> | An AdapterView is a view whose children are determined by an[Adapter](https://developer.android.com/reference/android/widget/Adapter).                                                                                                                                                                                                                                                                                                                                                            | | [AdapterViewAnimator](https://developer.android.com/reference/android/widget/AdapterViewAnimator)                                                                       | Base class for a[AdapterView](https://developer.android.com/reference/android/widget/AdapterView)that will perform animations when switching between its views.                                                                                                                                                                                                                                                                                                                                   | | [AdapterViewFlipper](https://developer.android.com/reference/android/widget/AdapterViewFlipper)                                                                         | Simple[ViewAnimator](https://developer.android.com/reference/android/widget/ViewAnimator)that will animate between two or more views that have been added to it.                                                                                                                                                                                                                                                                                                                                  | | [AlertDialog](https://developer.android.com/reference/android/app/AlertDialog)                                                                                          | A subclass of Dialog that can display one, two or three buttons.                                                                                                                                                                                                                                                                                                                                                                                                                                  | | [AliasActivity](https://developer.android.com/reference/android/app/AliasActivity)                                                                                      | *This class was deprecated in API level 30. Use`<activity-alias>`or subclass Activity directly.*                                                                                                                                                                                                                                                                                                                                                                                                  | | [AnalogClock](https://developer.android.com/reference/android/widget/AnalogClock)                                                                                       | *This class was deprecated in API level 23. This widget is no longer supported; except for[RemoteViews](https://developer.android.com/reference/android/widget/RemoteViews)use cases like[app widgets](https://developer.android.com/develop/ui/views/appwidgets/overview).*                                                                                                                                                                                                                      | | [AppWidgetHostView](https://developer.android.com/reference/android/appwidget/AppWidgetHostView)                                                                        | Provides the glue to show AppWidget views.                                                                                                                                                                                                                                                                                                                                                                                                                                                        | | [AutoCompleteTextView](https://developer.android.com/reference/android/widget/AutoCompleteTextView)                                                                     | An editable text view that shows completion suggestions automatically while the user is typing.                                                                                                                                                                                                                                                                                                                                                                                                   | | [Button](https://developer.android.com/reference/android/widget/Button)                                                                                                 | A user interface element the user can tap or click to perform an action.                                                                                                                                                                                                                                                                                                                                                                                                                          | | [CalendarView](https://developer.android.com/reference/android/widget/CalendarView)                                                                                     | This class is a calendar widget for displaying and selecting dates.                                                                                                                                                                                                                                                                                                                                                                                                                               | | [CharacterPickerDialog](https://developer.android.com/reference/android/text/method/CharacterPickerDialog)                                                              | Dialog for choosing accented characters related to a base character.                                                                                                                                                                                                                                                                                                                                                                                                                              | | [CheckBox](https://developer.android.com/reference/android/widget/CheckBox)                                                                                             | A checkbox is a specific type of two-states button that can be either checked or unchecked.                                                                                                                                                                                                                                                                                                                                                                                                       | | [CheckedTextView](https://developer.android.com/reference/android/widget/CheckedTextView)                                                                               | An extension to[TextView](https://developer.android.com/reference/android/widget/TextView)that supports the[Checkable](https://developer.android.com/reference/android/widget/Checkable)interface and displays.                                                                                                                                                                                                                                                                                   | | [Chronometer](https://developer.android.com/reference/android/widget/Chronometer)                                                                                       | Class that implements a simple timer.                                                                                                                                                                                                                                                                                                                                                                                                                                                             | | [CompoundButton](https://developer.android.com/reference/android/widget/CompoundButton)                                                                                 | A button with two states, checked and unchecked.                                                                                                                                                                                                                                                                                                                                                                                                                                                  | | [DatePicker](https://developer.android.com/reference/android/widget/DatePicker)                                                                                         | Provides a widget for selecting a date.                                                                                                                                                                                                                                                                                                                                                                                                                                                           | | [DatePickerDialog](https://developer.android.com/reference/android/app/DatePickerDialog)                                                                                | A simple dialog containing an[DatePicker](https://developer.android.com/reference/android/widget/DatePicker).                                                                                                                                                                                                                                                                                                                                                                                     | | [DialerFilter](https://developer.android.com/reference/android/widget/DialerFilter)                                                                                     | *This class was deprecated in API level 26. Use a custom view or layout to handle this functionality instead*                                                                                                                                                                                                                                                                                                                                                                                     | | [Dialog](https://developer.android.com/reference/android/app/Dialog)                                                                                                    | Base class for Dialogs.                                                                                                                                                                                                                                                                                                                                                                                                                                                                           | | [DigitalClock](https://developer.android.com/reference/android/widget/DigitalClock)                                                                                     | *This class was deprecated in API level 17. It is recommended you use[TextClock](https://developer.android.com/reference/android/widget/TextClock)instead.*                                                                                                                                                                                                                                                                                                                                       | | [EditText](https://developer.android.com/reference/android/widget/EditText)                                                                                             | A user interface element for entering and modifying text.                                                                                                                                                                                                                                                                                                                                                                                                                                         | | [ExpandableListActivity](https://developer.android.com/reference/android/app/ExpandableListActivity)                                                                    | *This class was deprecated in API level 30. Use[RecyclerView](https://developer.android.com/reference/androidx/recyclerview/widget/RecyclerView.html)or use[ExpandableListView](https://developer.android.com/reference/android/widget/ExpandableListView)directly*                                                                                                                                                                                                                               | | [ExpandableListView](https://developer.android.com/reference/android/widget/ExpandableListView)                                                                         | A view that shows items in a vertically scrolling two-level list.                                                                                                                                                                                                                                                                                                                                                                                                                                 | | [ExtractEditText](https://developer.android.com/reference/android/inputmethodservice/ExtractEditText)                                                                   | Specialization of[EditText](https://developer.android.com/reference/android/widget/EditText)for showing and interacting with the extracted text in a full-screen input method.                                                                                                                                                                                                                                                                                                                    | | [FragmentBreadCrumbs](https://developer.android.com/reference/android/app/FragmentBreadCrumbs)                                                                          | *This class was deprecated in API level 21. This widget is no longer supported.*                                                                                                                                                                                                                                                                                                                                                                                                                  | | [FrameLayout](https://developer.android.com/reference/android/widget/FrameLayout)                                                                                       | FrameLayout is designed to block out an area on the screen to display a single item.                                                                                                                                                                                                                                                                                                                                                                                                              | | [GLSurfaceView](https://developer.android.com/reference/android/opengl/GLSurfaceView)                                                                                   | An implementation of SurfaceView that uses the dedicated surface for displaying OpenGL rendering.                                                                                                                                                                                                                                                                                                                                                                                                 | | [Gallery](https://developer.android.com/reference/android/widget/Gallery)                                                                                               | *This class was deprecated in API level 16. This widget is no longer supported. Other horizontally scrolling widgets include[HorizontalScrollView](https://developer.android.com/reference/android/widget/HorizontalScrollView)and[ViewPager](https://developer.android.com/reference/androidx/viewpager/widget/ViewPager.html)from the support library.*                                                                                                                                         | | [GestureOverlayView](https://developer.android.com/reference/android/gesture/GestureOverlayView)                                                                        | A transparent overlay for gesture input that can be placed on top of other widgets or contain other widgets.                                                                                                                                                                                                                                                                                                                                                                                      | | [GridLayout](https://developer.android.com/reference/android/widget/GridLayout)                                                                                         | A layout that places its children in a rectangular*grid*.                                                                                                                                                                                                                                                                                                                                                                                                                                         | | [GridView](https://developer.android.com/reference/android/widget/GridView)                                                                                             | A view that shows items in two-dimensional scrolling grid.                                                                                                                                                                                                                                                                                                                                                                                                                                        | | [HorizontalScrollView](https://developer.android.com/reference/android/widget/HorizontalScrollView)                                                                     | Layout container for a view hierarchy that can be scrolled by the user, allowing it to be larger than the physical display.                                                                                                                                                                                                                                                                                                                                                                       | | [ImageButton](https://developer.android.com/reference/android/widget/ImageButton)                                                                                       | Displays a button with an image (instead of text) that can be pressed or clicked by the user.                                                                                                                                                                                                                                                                                                                                                                                                     | | [ImageSwitcher](https://developer.android.com/reference/android/widget/ImageSwitcher)                                                                                   | [ViewSwitcher](https://developer.android.com/reference/android/widget/ViewSwitcher)that switches between two ImageViews when a new image is set on it.                                                                                                                                                                                                                                                                                                                                            | | [ImageView](https://developer.android.com/reference/android/widget/ImageView)                                                                                           | Displays image resources, for example[Bitmap](https://developer.android.com/reference/android/graphics/Bitmap)or[Drawable](https://developer.android.com/reference/android/graphics/drawable/Drawable)resources.                                                                                                                                                                                                                                                                                  | | [InlineContentView](https://developer.android.com/reference/android/widget/inline/InlineContentView)                                                                    | This class represents a view that holds opaque content from another app that you can inline in your UI.                                                                                                                                                                                                                                                                                                                                                                                           | | [InputMethodService](https://developer.android.com/reference/android/inputmethodservice/InputMethodService)                                                             | InputMethodService provides a standard implementation of an InputMethod, which final implementations can derive from and customize.                                                                                                                                                                                                                                                                                                                                                               | | [KeyboardView](https://developer.android.com/reference/android/inputmethodservice/KeyboardView)                                                                         | *This class was deprecated in API level 29. This class is deprecated because this is just a convenient UI widget class that application developers can re-implement on top of existing public APIs. If you have already depended on this class, consider copying the implementation from AOSP into your project or re-implementing a similar widget by yourselves*                                                                                                                                | | [LauncherActivity](https://developer.android.com/reference/android/app/LauncherActivity)                                                                                | *This class was deprecated in API level 30. Applications can implement this UI themselves using[RecyclerView](https://developer.android.com/reference/androidx/recyclerview/widget/RecyclerView.html)and[PackageManager.queryIntentActivities(Intent, int)](https://developer.android.com/reference/android/content/pm/PackageManager#queryIntentActivities(android.content.Intent,%20int))*                                                                                                      | | [LinearLayout](https://developer.android.com/reference/android/widget/LinearLayout)                                                                                     | A layout that arranges other views either horizontally in a single column or vertically in a single row.                                                                                                                                                                                                                                                                                                                                                                                          | | [ListActivity](https://developer.android.com/reference/android/app/ListActivity)                                                                                        | *This class was deprecated in API level 30. Use[ListFragment](https://developer.android.com/reference/androidx/fragment/app/ListFragment.html)or[RecyclerView](https://developer.android.com/reference/androidx/recyclerview/widget/RecyclerView.html)to implement your Activity instead.*                                                                                                                                                                                                        | | [ListView](https://developer.android.com/reference/android/widget/ListView)                                                                                             | Displays a vertically-scrollable collection of views, where each view is positioned immediately below the previous view in the list.                                                                                                                                                                                                                                                                                                                                                              | | [MediaController](https://developer.android.com/reference/android/widget/MediaController)                                                                               | A view containing controls for a MediaPlayer.                                                                                                                                                                                                                                                                                                                                                                                                                                                     | | [MediaRouteButton](https://developer.android.com/reference/android/app/MediaRouteButton)                                                                                |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   | | [MultiAutoCompleteTextView](https://developer.android.com/reference/android/widget/MultiAutoCompleteTextView)                                                           | An editable text view, extending[AutoCompleteTextView](https://developer.android.com/reference/android/widget/AutoCompleteTextView), that can show completion suggestions for the substring of the text where the user is typing instead of necessarily for the entire thing.                                                                                                                                                                                                                     | | [NativeActivity](https://developer.android.com/reference/android/app/NativeActivity)                                                                                    | Convenience for implementing an activity that will be implemented purely in native code.                                                                                                                                                                                                                                                                                                                                                                                                          | | [NumberPicker](https://developer.android.com/reference/android/widget/NumberPicker)                                                                                     | A widget that enables the user to select a number from a predefined range.                                                                                                                                                                                                                                                                                                                                                                                                                        | | [PreferenceActivity](https://developer.android.com/reference/android/preference/PreferenceActivity)                                                                     | *This class was deprecated in API level 29. Use the[AndroidX](https://developer.android.com/jetpack/androidx)[Preference Library](https://developer.android.com/reference/androidx/preference/package-summary)for consistent behavior across all devices. For more information on using the AndroidX Preference Library see[Settings](https://developer.android.com/guide/topics/ui/settings).*                                                                                                   | | [Presentation](https://developer.android.com/reference/android/app/Presentation)                                                                                        | Base class for presentations.                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | | [ProgressBar](https://developer.android.com/reference/android/widget/ProgressBar)                                                                                       | A user interface element that indicates the progress of an operation.                                                                                                                                                                                                                                                                                                                                                                                                                             | | [ProgressDialog](https://developer.android.com/reference/android/app/ProgressDialog)                                                                                    | *This class was deprecated in API level 26.`ProgressDialog`is a modal dialog, which prevents the user from interacting with the app. Instead of using this class, you should use a progress indicator like[ProgressBar](https://developer.android.com/reference/android/widget/ProgressBar), which can be embedded in your app's UI. Alternatively, you can use a[notification](https://developer.android.com/guide/topics/ui/notifiers/notifications)to inform the user of the task's progress.* | | [QuickContactBadge](https://developer.android.com/reference/android/widget/QuickContactBadge)                                                                           | Widget used to show an image with the standard QuickContact badge and on-click behavior.                                                                                                                                                                                                                                                                                                                                                                                                          | | [RadioButton](https://developer.android.com/reference/android/widget/RadioButton)                                                                                       | A radio button is a two-states button that can be either checked or unchecked.                                                                                                                                                                                                                                                                                                                                                                                                                    | | [RadioGroup](https://developer.android.com/reference/android/widget/RadioGroup)                                                                                         | This class is used to create a multiple-exclusion scope for a set of radio buttons.                                                                                                                                                                                                                                                                                                                                                                                                               | | [RatingBar](https://developer.android.com/reference/android/widget/RatingBar)                                                                                           | A RatingBar is an extension of SeekBar and ProgressBar that shows a rating in stars.                                                                                                                                                                                                                                                                                                                                                                                                              | | [RelativeLayout](https://developer.android.com/reference/android/widget/RelativeLayout)                                                                                 | A Layout where the positions of the children can be described in relation to each other or to the parent.                                                                                                                                                                                                                                                                                                                                                                                         | | [ScrollView](https://developer.android.com/reference/android/widget/ScrollView)                                                                                         | A view group that allows the view hierarchy placed within it to be scrolled.                                                                                                                                                                                                                                                                                                                                                                                                                      | | [SearchView](https://developer.android.com/reference/android/widget/SearchView)                                                                                         | A widget that provides a user interface for the user to enter a search query and submit a request to a search provider.                                                                                                                                                                                                                                                                                                                                                                           | | [SeekBar](https://developer.android.com/reference/android/widget/SeekBar)                                                                                               | A SeekBar is an extension of ProgressBar that adds a draggable thumb.                                                                                                                                                                                                                                                                                                                                                                                                                             | | [SlidingDrawer](https://developer.android.com/reference/android/widget/SlidingDrawer)                                                                                   | *This class was deprecated in API level 17. This class is not supported anymore. It is recommended you base your own implementation on the source code for the Android Open Source Project if you must use it in your application.*                                                                                                                                                                                                                                                               | | [Space](https://developer.android.com/reference/android/widget/Space)                                                                                                   | Space is a lightweight View subclass that may be used to create gaps between components in general purpose layouts.                                                                                                                                                                                                                                                                                                                                                                               | | [Spinner](https://developer.android.com/reference/android/widget/Spinner)                                                                                               | A view that displays one child at a time and lets the user pick among them.                                                                                                                                                                                                                                                                                                                                                                                                                       | | [SplashScreenView](https://developer.android.com/reference/android/window/SplashScreenView)                                                                             | The view which allows an activity to customize its splash screen exit animation.                                                                                                                                                                                                                                                                                                                                                                                                                  | | [StackView](https://developer.android.com/reference/android/widget/StackView)                                                                                           |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   | | [SurfaceView](https://developer.android.com/reference/android/view/SurfaceView)                                                                                         | Provides a dedicated drawing surface embedded inside of a view hierarchy.                                                                                                                                                                                                                                                                                                                                                                                                                         | | [Switch](https://developer.android.com/reference/android/widget/Switch)                                                                                                 | A Switch is a two-state toggle widget.                                                                                                                                                                                                                                                                                                                                                                                                                                                            | | [TabActivity](https://developer.android.com/reference/android/app/TabActivity)                                                                                          | *This class was deprecated in API level 13. New applications should use Fragments instead of this class; to continue to run on older devices, you can use the v4 support library which provides a version of the Fragment API that is compatible down to[Build.VERSION_CODES.DONUT](https://developer.android.com/reference/android/os/Build.VERSION_CODES#DONUT).*                                                                                                                               | | [TabHost](https://developer.android.com/reference/android/widget/TabHost)                                                                                               | *This class was deprecated in API level 30. new applications should use fragment APIs instead of this class: Use[TabLayout and ViewPager](https://developer.android.com/guide/navigation/navigation-swipe-view)instead.*                                                                                                                                                                                                                                                                          | | [TabWidget](https://developer.android.com/reference/android/widget/TabWidget)                                                                                           | *This class was deprecated in API level 30. new applications should use fragment APIs instead of this class: Use[TabLayout and ViewPager](https://developer.android.com/guide/navigation/navigation-swipe-view)instead.*                                                                                                                                                                                                                                                                          | | [TableLayout](https://developer.android.com/reference/android/widget/TableLayout)                                                                                       | A layout that arranges its children into rows and columns.                                                                                                                                                                                                                                                                                                                                                                                                                                        | | [TableRow](https://developer.android.com/reference/android/widget/TableRow)                                                                                             | A layout that arranges its children horizontally.                                                                                                                                                                                                                                                                                                                                                                                                                                                 | | [TextClock](https://developer.android.com/reference/android/widget/TextClock)                                                                                           | `TextClock`can display the current date and/or time as a formatted string.                                                                                                                                                                                                                                                                                                                                                                                                                        | | [TextSwitcher](https://developer.android.com/reference/android/widget/TextSwitcher)                                                                                     | Specialized[ViewSwitcher](https://developer.android.com/reference/android/widget/ViewSwitcher)that contains only children of type[TextView](https://developer.android.com/reference/android/widget/TextView).                                                                                                                                                                                                                                                                                     | | [TextView](https://developer.android.com/reference/android/widget/TextView)                                                                                             | A user interface element that displays text to the user.                                                                                                                                                                                                                                                                                                                                                                                                                                          | | [TextureView](https://developer.android.com/reference/android/view/TextureView)                                                                                         | A TextureView can be used to display a content stream, such as that coming from a camera preview, a video, or an OpenGL scene.                                                                                                                                                                                                                                                                                                                                                                    | | [TimePicker](https://developer.android.com/reference/android/widget/TimePicker)                                                                                         | A widget for selecting the time of day, in either 24-hour or AM/PM mode.                                                                                                                                                                                                                                                                                                                                                                                                                          | | [TimePickerDialog](https://developer.android.com/reference/android/app/TimePickerDialog)                                                                                | A dialog that prompts the user for the time of day using a[TimePicker](https://developer.android.com/reference/android/widget/TimePicker).                                                                                                                                                                                                                                                                                                                                                        | | [ToggleButton](https://developer.android.com/reference/android/widget/ToggleButton)                                                                                     | Displays checked/unchecked states as a button with a "light" indicator and by default accompanied with the text "ON" or "OFF".                                                                                                                                                                                                                                                                                                                                                                    | | [Toolbar](https://developer.android.com/reference/android/widget/Toolbar)                                                                                               | A standard toolbar for use within application content.                                                                                                                                                                                                                                                                                                                                                                                                                                            | | [TvAdService.Session](https://developer.android.com/reference/android/media/tv/ad/TvAdService.Session)                                                                  | Base class for derived classes to implement to provide a TV AD session.                                                                                                                                                                                                                                                                                                                                                                                                                           | | [TvAdView](https://developer.android.com/reference/android/media/tv/ad/TvAdView)                                                                                        | Displays contents of TV advertisement services.                                                                                                                                                                                                                                                                                                                                                                                                                                                   | | [TvInputService.HardwareSession](https://developer.android.com/reference/android/media/tv/TvInputService.HardwareSession)                                               | Base class for a TV input session which represents an external device connected to a hardware TV input.                                                                                                                                                                                                                                                                                                                                                                                           | | [TvInputService.Session](https://developer.android.com/reference/android/media/tv/TvInputService.Session)                                                               | Base class for derived classes to implement to provide a TV input session.                                                                                                                                                                                                                                                                                                                                                                                                                        | | [TvInteractiveAppService.Session](https://developer.android.com/reference/android/media/tv/interactive/TvInteractiveAppService.Session)                                 | Base class for derived classes to implement to provide a TV interactive app session.                                                                                                                                                                                                                                                                                                                                                                                                              | | [TvInteractiveAppView](https://developer.android.com/reference/android/media/tv/interactive/TvInteractiveAppView)                                                       | Displays contents of interactive TV applications.                                                                                                                                                                                                                                                                                                                                                                                                                                                 | | [TvView](https://developer.android.com/reference/android/media/tv/TvView)                                                                                               | Displays TV contents.                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | | [TwoLineListItem](https://developer.android.com/reference/android/widget/TwoLineListItem)                                                                               | *This class was deprecated in API level 17. This class can be implemented easily by apps using a[RelativeLayout](https://developer.android.com/reference/android/widget/RelativeLayout)or a[LinearLayout](https://developer.android.com/reference/android/widget/LinearLayout).*                                                                                                                                                                                                                  | | [VideoView](https://developer.android.com/reference/android/widget/VideoView)                                                                                           | Displays a video file.                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | | [View](https://developer.android.com/reference/android/view/View)                                                                                                       | This class represents the basic building block for user interface components.                                                                                                                                                                                                                                                                                                                                                                                                                     | | [ViewAnimator](https://developer.android.com/reference/android/widget/ViewAnimator)                                                                                     | Base class for a[FrameLayout](https://developer.android.com/reference/android/widget/FrameLayout)container that will perform animations when switching between its views.                                                                                                                                                                                                                                                                                                                         | | [ViewFlipper](https://developer.android.com/reference/android/widget/ViewFlipper)                                                                                       | Simple[ViewAnimator](https://developer.android.com/reference/android/widget/ViewAnimator)that will animate between two or more views that have been added to it.                                                                                                                                                                                                                                                                                                                                  | | [ViewGroup](https://developer.android.com/reference/android/view/ViewGroup)                                                                                             | A`ViewGroup`is a special view that can contain other views (called children.) The view group is the base class for layouts and views containers.                                                                                                                                                                                                                                                                                                                                                  | | [ViewStub](https://developer.android.com/reference/android/view/ViewStub)                                                                                               | A ViewStub is an invisible, zero-sized View that can be used to lazily inflate layout resources at runtime.                                                                                                                                                                                                                                                                                                                                                                                       | | [ViewSwitcher](https://developer.android.com/reference/android/widget/ViewSwitcher)                                                                                     | [ViewAnimator](https://developer.android.com/reference/android/widget/ViewAnimator)that switches between two views, and has a factory from which these views are created.                                                                                                                                                                                                                                                                                                                         | | [VoiceInteractionSession](https://developer.android.com/reference/android/service/voice/VoiceInteractionSession)                                                        | An active voice interaction session, providing a facility for the implementation to interact with the user in the voice interaction layer.                                                                                                                                                                                                                                                                                                                                                        | | [WebView](https://developer.android.com/reference/android/webkit/WebView)                                                                                               | A View that displays web pages.                                                                                                                                                                                                                                                                                                                                                                                                                                                                   | | [ZoomButton](https://developer.android.com/reference/android/widget/ZoomButton)                                                                                         | *This class was deprecated in API level 26. Use other means to handle this functionality. This widget is merely a simple wrapper around a long-press handler.*                                                                                                                                                                                                                                                                                                                                    | | [ZoomControls](https://developer.android.com/reference/android/widget/ZoomControls)                                                                                     | *This class was deprecated in API level 29. This functionality and UI is better handled with custom views and layouts rather than a dedicated zoom-control widget*                                                                                                                                                                                                                                                                                                                                | |

<br />

*** ** * ** ***

## Summary

|                                                                                                                                                                                                                       ### Public methods                                                                                                                                                                                                                        ||
|---------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` abstract boolean` | ` `[onKeyDown](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyDown(int,%20android.view.KeyEvent))`(int keyCode, `[KeyEvent](https://developer.android.com/reference/android/view/KeyEvent)` event) ` Called when a key down event has occurred.                                                                                                                                                               |
| ` abstract boolean` | ` `[onKeyLongPress](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyLongPress(int,%20android.view.KeyEvent))`(int keyCode, `[KeyEvent](https://developer.android.com/reference/android/view/KeyEvent)` event) ` Called when a long press has occurred.                                                                                                                                                         |
| ` abstract boolean` | ` `[onKeyMultiple](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyMultiple(int,%20int,%20android.view.KeyEvent))`(int keyCode, int count, `[KeyEvent](https://developer.android.com/reference/android/view/KeyEvent)` event) ` Called when a user's interaction with an analog control, such as flinging a trackball, generates simulated down/up events for the same key multiple times in quick succession. |
| ` abstract boolean` | ` `[onKeyUp](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyUp(int,%20android.view.KeyEvent))`(int keyCode, `[KeyEvent](https://developer.android.com/reference/android/view/KeyEvent)` event) ` Called when a key up event has occurred.                                                                                                                                                                     |

## Public methods

### onKeyDown

Added in[API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract boolean onKeyDown (int keyCode, 
                KeyEvent event)
```

Called when a key down event has occurred. If you return true, you can first call[KeyEvent.startTracking()](https://developer.android.com/reference/android/view/KeyEvent#startTracking())to have the framework track the event through its[onKeyUp(int, android.view.KeyEvent)](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyUp(int,%20android.view.KeyEvent))and also call your[onKeyLongPress(int, android.view.KeyEvent)](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyLongPress(int,%20android.view.KeyEvent))if it occurs.

<br />

|                         Parameters                          ||
|-----------|--------------------------------------------------|
| `keyCode` | `int`: The value in event.getKeyCode(). <br />   |
| `event`   | `KeyEvent`: Description of the key event. <br /> |

|                                                                  Returns                                                                  ||
|-----------|--------------------------------------------------------------------------------------------------------------------------------|
| `boolean` | If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false. <br /> |

### onKeyLongPress

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract boolean onKeyLongPress (int keyCode, 
                KeyEvent event)
```

Called when a long press has occurred. If you return true, the final key up will have[KeyEvent.FLAG_CANCELED](https://developer.android.com/reference/android/view/KeyEvent#FLAG_CANCELED)and[KeyEvent.FLAG_CANCELED_LONG_PRESS](https://developer.android.com/reference/android/view/KeyEvent#FLAG_CANCELED_LONG_PRESS)set. Note that in order to receive this callback, someone in the event change*must* return true from[onKeyDown(int, KeyEvent)](https://developer.android.com/reference/android/view/KeyEvent.Callback#onKeyDown(int,%20android.view.KeyEvent))*and* call[KeyEvent.startTracking()](https://developer.android.com/reference/android/view/KeyEvent#startTracking())on the event.

<br />

|                         Parameters                          ||
|-----------|--------------------------------------------------|
| `keyCode` | `int`: The value in event.getKeyCode(). <br />   |
| `event`   | `KeyEvent`: Description of the key event. <br /> |

|                                                                  Returns                                                                  ||
|-----------|--------------------------------------------------------------------------------------------------------------------------------|
| `boolean` | If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false. <br /> |

### onKeyMultiple

Added in[API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract boolean onKeyMultiple (int keyCode, 
                int count, 
                KeyEvent event)
```

Called when a user's interaction with an analog control, such as flinging a trackball, generates simulated down/up events for the same key multiple times in quick succession.

<br />

|                                   Parameters                                    ||
|-----------|----------------------------------------------------------------------|
| `keyCode` | `int`: The value in event.getKeyCode(). <br />                       |
| `count`   | `int`: Number of pairs as returned by event.getRepeatCount(). <br /> |
| `event`   | `KeyEvent`: Description of the key event. <br />                     |

|                                                                  Returns                                                                  ||
|-----------|--------------------------------------------------------------------------------------------------------------------------------|
| `boolean` | If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false. <br /> |

### onKeyUp

Added in[API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract boolean onKeyUp (int keyCode, 
                KeyEvent event)
```

Called when a key up event has occurred.

<br />

|                         Parameters                          ||
|-----------|--------------------------------------------------|
| `keyCode` | `int`: The value in event.getKeyCode(). <br />   |
| `event`   | `KeyEvent`: Description of the key event. <br /> |

|                                                                  Returns                                                                  ||
|-----------|--------------------------------------------------------------------------------------------------------------------------------|
| `boolean` | If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false. <br /> |