summaryrefslogtreecommitdiffstats
path: root/core/java/android
diff options
context:
space:
mode:
authorAlan Viverette <alanv@google.com>2014-10-30 11:26:29 -0700
committerAlan Viverette <alanv@google.com>2014-10-30 11:26:29 -0700
commitf7dee54b62b02413fc6a0b8dc5666a7cd9758460 (patch)
tree5ad000be1bee65121f6f241c1154e640fae37cf5 /core/java/android
parentfc2b9039b87afd3067f563a9bf59504a8bdf8a87 (diff)
downloadframeworks_base-f7dee54b62b02413fc6a0b8dc5666a7cd9758460.zip
frameworks_base-f7dee54b62b02413fc6a0b8dc5666a7cd9758460.tar.gz
frameworks_base-f7dee54b62b02413fc6a0b8dc5666a7cd9758460.tar.bz2
Only draw AbsListView selector when focused or pressed
BUG: 18176135 Change-Id: Ibd9d9c0f439e5daa8eba606abc5ff055a3d8ff0c
Diffstat (limited to 'core/java/android')
-rw-r--r--core/java/android/widget/AbsListView.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/java/android/widget/AbsListView.java b/core/java/android/widget/AbsListView.java
index 6c107a2..6927660 100644
--- a/core/java/android/widget/AbsListView.java
+++ b/core/java/android/widget/AbsListView.java
@@ -2663,7 +2663,7 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te
* @return True if the selector should be shown
*/
boolean shouldShowSelector() {
- return (!isInTouchMode()) || (touchModeDrawsInPressedState() && isPressed());
+ return (isFocused() && !isInTouchMode()) || (touchModeDrawsInPressedState() && isPressed());
}
private void drawSelector(Canvas canvas) {