Loading core/java/android/view/View.java +2 −1 Original line number Diff line number Diff line Loading @@ -24512,8 +24512,9 @@ public class View implements Drawable.Callback, KeyEvent.Callback, /** * Set the current default focus highlight. * @param highlight the highlight drawable, or {@code null} if it's no longer needed. * @hide */ private void setDefaultFocusHighlight(Drawable highlight) { void setDefaultFocusHighlight(Drawable highlight) { mDefaultFocusHighlight = highlight; mDefaultFocusHighlightSizeChanged = true; if (highlight != null) { core/java/android/view/ViewRootImpl.java +14 −1 Original line number Diff line number Diff line Loading @@ -3815,6 +3815,13 @@ public final class ViewRootImpl implements ViewParent, if (mAttachInfo.mTooltipHost != null) { mAttachInfo.mTooltipHost.hideTooltip(); } if (!hasWindowFocus) { // Clear focus highlight if its window lost focus. final View focused = mView.findFocus(); if (focused != null) { focused.setDefaultFocusHighlight(null); } } } // Note: must be done after the focus change callbacks, Loading Loading @@ -5846,7 +5853,13 @@ public final class ViewRootImpl implements ViewParent, // be when the window is first being added, and mFocused isn't // set yet. final View focused = mView.findFocus(); if (focused != null && !focused.isFocusableInTouchMode()) { if (focused == null) { return false; } // Clear default focus highlight if it entered touch mode. focused.setDefaultFocusHighlight(null); if (!focused.isFocusableInTouchMode()) { final ViewGroup ancestorToTakeFocus = findAncestorToTakeFocusInTouchMode(focused); if (ancestorToTakeFocus != null) { // there is an ancestor that wants focus after its Loading Loading
core/java/android/view/View.java +2 −1 Original line number Diff line number Diff line Loading @@ -24512,8 +24512,9 @@ public class View implements Drawable.Callback, KeyEvent.Callback, /** * Set the current default focus highlight. * @param highlight the highlight drawable, or {@code null} if it's no longer needed. * @hide */ private void setDefaultFocusHighlight(Drawable highlight) { void setDefaultFocusHighlight(Drawable highlight) { mDefaultFocusHighlight = highlight; mDefaultFocusHighlightSizeChanged = true; if (highlight != null) {
core/java/android/view/ViewRootImpl.java +14 −1 Original line number Diff line number Diff line Loading @@ -3815,6 +3815,13 @@ public final class ViewRootImpl implements ViewParent, if (mAttachInfo.mTooltipHost != null) { mAttachInfo.mTooltipHost.hideTooltip(); } if (!hasWindowFocus) { // Clear focus highlight if its window lost focus. final View focused = mView.findFocus(); if (focused != null) { focused.setDefaultFocusHighlight(null); } } } // Note: must be done after the focus change callbacks, Loading Loading @@ -5846,7 +5853,13 @@ public final class ViewRootImpl implements ViewParent, // be when the window is first being added, and mFocused isn't // set yet. final View focused = mView.findFocus(); if (focused != null && !focused.isFocusableInTouchMode()) { if (focused == null) { return false; } // Clear default focus highlight if it entered touch mode. focused.setDefaultFocusHighlight(null); if (!focused.isFocusableInTouchMode()) { final ViewGroup ancestorToTakeFocus = findAncestorToTakeFocusInTouchMode(focused); if (ancestorToTakeFocus != null) { // there is an ancestor that wants focus after its Loading