diff options
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/view/accessibility/AccessibilityNodeInfo.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/java/android/view/accessibility/AccessibilityNodeInfo.java b/core/java/android/view/accessibility/AccessibilityNodeInfo.java index 0daf78b..3834fd6 100644 --- a/core/java/android/view/accessibility/AccessibilityNodeInfo.java +++ b/core/java/android/view/accessibility/AccessibilityNodeInfo.java @@ -432,8 +432,10 @@ public class AccessibilityNodeInfo implements Parcelable { final int rootAccessibilityViewId = (root != null) ? root.getAccessibilityViewId() : UNDEFINED; mSourceNodeId = makeNodeId(rootAccessibilityViewId, virtualDescendantId); - mActualAndReportedWindowLeftDelta = root.getActualAndReportedWindowLeftDelta(); - mActualAndReportedWindowTopDelta = root.getActualAndReportedWindowTopDelta(); + if (root != null) { + mActualAndReportedWindowLeftDelta = root.getActualAndReportedWindowLeftDelta(); + mActualAndReportedWindowTopDelta = root.getActualAndReportedWindowTopDelta(); + } } /** |
