Indeed, the AccessibilityManager
class has no method called getInstance()
. From the docs:
To obtain a handle to the accessibility manager do the following:
AccessibilityManager accessibilityManager = (AccessibilityManager) context.getSystemService(Context.ACCESSIBILITY_SERVICE);
So really all you need is a Context
. Lucky, you've got a View
, which itself is a Context
, and holds references to it's parent contexts.