Minor twaek to the focus behavior.
bug:6296603 Change-Id: I3bd0b291e6013cae019ca9049d9d3dc506845ab0
This commit is contained in:
@@ -4059,14 +4059,7 @@ public class View implements Drawable.Callback, Drawable.Callback2, KeyEvent.Cal
|
||||
void ensureInputFocusOnFirstFocusable() {
|
||||
View root = getRootView();
|
||||
if (root != null) {
|
||||
// Find the first focusble from the top.
|
||||
View next = root.focusSearch(FOCUS_FORWARD);
|
||||
if (next != null) {
|
||||
// Giving focus to the found focusable will not
|
||||
// perform a search since we found a view that is
|
||||
// guaranteed to be able to take focus.
|
||||
next.requestFocus(FOCUS_FORWARD);
|
||||
}
|
||||
root.requestFocus(FOCUS_FORWARD);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user