Stay organized with collections
Save and categorize content based on your preferences.
AccessibilityStateChangeListener
interface AccessibilityStateChangeListener
Listener for the system accessibility state. To listen for changes to the accessibility state on the device, implement this interface and register it with the system by calling #addAccessibilityStateChangeListener.
Summary
Public methods |
abstract Unit |
Called when the accessibility enabled state changes.
|
Public methods
onAccessibilityStateChanged
abstract fun onAccessibilityStateChanged(enabled: Boolean): Unit
Called when the accessibility enabled state changes.
Parameters |
enabled |
Boolean: Whether accessibility is enabled. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[null,null,["Last updated 2025-02-10 UTC."],[],[],null,["# AccessibilityManager.AccessibilityStateChangeListener\n\nAdded in [API level 14](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nAccessibilityStateChangeListener\n================================\n\n*** ** * ** ***\n\nKotlin \\|[Java](/reference/android/view/accessibility/AccessibilityManager.AccessibilityStateChangeListener \"View this page in Java\") \n\n```\ninterface AccessibilityStateChangeListener\n```\n\n|---------------------------------------------------------------------------------------|\n| [android.view.accessibility.AccessibilityManager.AccessibilityStateChangeListener](#) |\n\nListener for the system accessibility state. To listen for changes to the accessibility state on the device, implement this interface and register it with the system by calling #addAccessibilityStateChangeListener.\n\nSummary\n-------\n\n| Public methods ||\n|---------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| abstract [Unit](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) | [onAccessibilityStateChanged](#onAccessibilityStateChanged(kotlin.Boolean))`(`enabled:` `[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`)` Called when the accessibility enabled state changes. |\n\nPublic methods\n--------------\n\n### onAccessibilityStateChanged\n\nAdded in [API level 14](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nabstract fun onAccessibilityStateChanged(enabled: Boolean): Unit\n```\n\nCalled when the accessibility enabled state changes.\n\n| Parameters ||\n|-----------|-----------------------------------------------------------------------------------------------------------------------|\n| `enabled` | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html): Whether accessibility is enabled. |"]]