diff options
author | Sunny Goyal <sunnygoyal@google.com> | 2015-09-24 11:23:31 -0700 |
---|---|---|
committer | Sunny Goyal <sunnygoyal@google.com> | 2015-09-25 10:22:47 -0700 |
commit | e78e3d734b577c1ab6dc0738a83600374908ea52 (patch) | |
tree | faa3735d90f5e6ef472657edcbbde79f81f48d36 /src/com/android/launcher3/DeleteDropTarget.java | |
parent | 2949fb5b16a07259e221c5c04470e90c8afb4ea8 (diff) | |
download | android_packages_apps_Trebuchet-e78e3d734b577c1ab6dc0738a83600374908ea52.tar.gz android_packages_apps_Trebuchet-e78e3d734b577c1ab6dc0738a83600374908ea52.tar.bz2 android_packages_apps_Trebuchet-e78e3d734b577c1ab6dc0738a83600374908ea52.zip |
Accessibility fixes
1) Use a different content description for temporary new page
2) Use different accessibility description for add widget toast
3) Announce when an item is deleted
4) Announce when hovering over a drop target
5) Announce state during drag-n-drop and widget resize (similar to seekbar)
Bug: 23573321, 24057944
Change-Id: Icabb317625e70c78e11c0b4f99b9339172d93594
Diffstat (limited to 'src/com/android/launcher3/DeleteDropTarget.java')
-rw-r--r-- | src/com/android/launcher3/DeleteDropTarget.java | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/com/android/launcher3/DeleteDropTarget.java b/src/com/android/launcher3/DeleteDropTarget.java index 5b1e84efb..2a0e203e6 100644 --- a/src/com/android/launcher3/DeleteDropTarget.java +++ b/src/com/android/launcher3/DeleteDropTarget.java @@ -19,7 +19,6 @@ package com.android.launcher3; import android.animation.TimeInterpolator; import android.content.Context; import android.graphics.PointF; -import android.os.AsyncTask; import android.util.AttributeSet; import android.view.View; import android.view.animation.AnimationUtils; @@ -67,15 +66,14 @@ public class DeleteDropTarget extends ButtonDropTarget { /** * Removes the item from the workspace. If the view is not null, it also removes the view. - * @return true if the item was removed. */ - public static boolean removeWorkspaceOrFolderItem(Launcher launcher, ItemInfo item, View view) { + public static void removeWorkspaceOrFolderItem(Launcher launcher, ItemInfo item, View view) { // Remove the item from launcher and the db, we can ignore the containerInfo in this call // because we already remove the drag view from the folder (if the drag originated from // a folder) in Folder.beginDrag() launcher.removeItem(view, item, true /* deleteFromDb */); launcher.getWorkspace().stripEmptyScreens(); - return true; + launcher.getDragLayer().announceForAccessibility(launcher.getString(R.string.item_removed)); } @Override |