-
Notifications
You must be signed in to change notification settings - Fork 822
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve accessibility autofill performance
- Loading branch information
1 parent
016d0f8
commit 5645ab3
Showing
4 changed files
with
143 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 8 additions & 2 deletions
10
.../x8bit/bitwarden/data/autofill/accessibility/processor/BitwardenAccessibilityProcessor.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,19 @@ | ||
package com.x8bit.bitwarden.data.autofill.accessibility.processor | ||
|
||
import android.view.accessibility.AccessibilityEvent | ||
import android.view.accessibility.AccessibilityNodeInfo | ||
|
||
/** | ||
* A class to handle accessibility event processing. This only includes fill requests. | ||
*/ | ||
interface BitwardenAccessibilityProcessor { | ||
/** | ||
* Processes the [AccessibilityNodeInfo] for autofill options. | ||
* Processes the [AccessibilityEvent] for autofill options and grant access to the current | ||
* [AccessibilityNodeInfo] via the [rootAccessibilityNodeInfoProvider] (note that calling the | ||
* `rootAccessibilityNodeInfoProvider` is expensive). | ||
*/ | ||
fun processAccessibilityEvent(rootAccessibilityNodeInfo: AccessibilityNodeInfo?) | ||
fun processAccessibilityEvent( | ||
event: AccessibilityEvent, | ||
rootAccessibilityNodeInfoProvider: () -> AccessibilityNodeInfo?, | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.