Don't add focusables when getDescendantFocusability is FOCUS_BLOCK_DESCENDANTS.

Bug: 32315286
Change-Id: I6fc6600fc9cbf83f720d9e6e878735076cd52cf1
This commit is contained in:
Jon Miranda
2016-10-25 16:19:17 -07:00
parent 9ccafbff26
commit 6a85817dfc

View File

@@ -1068,6 +1068,10 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
@Override
public void addFocusables(ArrayList<View> views, int direction, int focusableMode) {
if (getDescendantFocusability() == FOCUS_BLOCK_DESCENDANTS) {
return;
}
// XXX-RTL: This will be fixed in a future CL
if (mCurrentPage >= 0 && mCurrentPage < getPageCount()) {
getPageAt(mCurrentPage).addFocusables(views, direction, focusableMode);