summaryrefslogtreecommitdiffstats
path: root/packages/PrintSpooler/src
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2015-02-03 18:13:40 -0800
committerDianne Hackborn <hackbod@google.com>2015-02-06 10:42:44 -0800
commita7bb6fbeab933326d58aa806d8194b7b13239d34 (patch)
treef56d4455b6eec18420a982573b800fb0b6220ce1 /packages/PrintSpooler/src
parentb989c5561ea10e623d73e7bb89b37ac38ccdd908 (diff)
downloadframeworks_base-a7bb6fbeab933326d58aa806d8194b7b13239d34.zip
frameworks_base-a7bb6fbeab933326d58aa806d8194b7b13239d34.tar.gz
frameworks_base-a7bb6fbeab933326d58aa806d8194b7b13239d34.tar.bz2
First quick implementation of auto assist data.
Introduce new AssistData class that contains all data the framework automatically generates for assist. Currently populated with a very simple tree structure representing the app's view hierarchy. Reworked how we populate the class name for accessibility info, so this is provided through a new method call on View that subclasses can override. This method is also used to populate the class name in AssistData. Change-Id: Ibd0acdc8354727d4291473283b5e4b70894905dc
Diffstat (limited to 'packages/PrintSpooler/src')
-rw-r--r--packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java
index feb0316..6a6f1d3 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java
@@ -48,16 +48,19 @@ public final class PreviewPageFrame extends LinearLayout {
}
@Override
+ public CharSequence getAccessibilityClassName() {
+ return CompoundButton.class.getName();
+ }
+
+ @Override
public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
super.onInitializeAccessibilityEvent(event);
- event.setClassName(CompoundButton.class.getName());
event.setChecked(isSelected());
}
@Override
public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
super.onInitializeAccessibilityNodeInfo(info);
- info.setClassName(CompoundButton.class.getName());
info.setSelected(false);
info.setCheckable(true);
info.setChecked(isSelected());