summaryrefslogtreecommitdiffstats
path: root/services/accessibility
diff options
context:
space:
mode:
authorSvetoslav <svetoslavganov@google.com>2015-01-23 23:31:38 +0000
committerandroid-build-merger <android-build-merger@google.com>2015-01-23 23:31:38 +0000
commitcd2ed4e64c501a5dbf73941a4a1f1e4bc639ebf3 (patch)
tree9d4544829834c96ed3a899e89b4f49d0eb3898c3 /services/accessibility
parent9027d7355e8e804307902fb5ec88cf54e23cdcb4 (diff)
parentdb1983b3f43e86acbf188961f53af794cce05219 (diff)
downloadframeworks_base-cd2ed4e64c501a5dbf73941a4a1f1e4bc639ebf3.zip
frameworks_base-cd2ed4e64c501a5dbf73941a4a1f1e4bc639ebf3.tar.gz
frameworks_base-cd2ed4e64c501a5dbf73941a4a1f1e4bc639ebf3.tar.bz2
Accessibility: Sometimes cannot interact with nav bar items. automerge: 10a053e
automerge: db1983b * commit 'db1983b3f43e86acbf188961f53af794cce05219': Accessibility: Sometimes cannot interact with nav bar items.
Diffstat (limited to 'services/accessibility')
-rw-r--r--services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java b/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
index 5ae26ef..bbf3644 100644
--- a/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
+++ b/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
@@ -765,16 +765,13 @@ public class AccessibilityManagerService extends IAccessibilityManager.Stub {
}
/**
- * Gets the bounds of the active window.
+ * Gets the bounds of a window.
*
* @param outBounds The output to which to write the bounds.
*/
- boolean getActiveWindowBounds(Rect outBounds) {
- // TODO: This should be refactored to work with accessibility
- // focus in multiple windows.
+ boolean getWindowBounds(int windowId, Rect outBounds) {
IBinder token;
synchronized (mLock) {
- final int windowId = mSecurityPolicy.mActiveWindowId;
token = mGlobalWindowTokens.get(windowId);
if (token == null) {
token = getCurrentUserStateLocked().mWindowTokens.get(windowId);
@@ -3255,7 +3252,7 @@ public class AccessibilityManagerService extends IAccessibilityManager.Stub {
// Make sure the point is within the window.
Rect windowBounds = mTempRect;
- getActiveWindowBounds(windowBounds);
+ getWindowBounds(focus.getWindowId(), windowBounds);
if (!windowBounds.contains(point.x, point.y)) {
return false;
}