Merge "Have ViewGroups without a parent clip child visible rects to bounds" into lmp-mr1-dev
This commit is contained in:
@@ -5113,7 +5113,8 @@ public abstract class ViewGroup extends View implements ViewParent, ViewManager
|
|||||||
final int height = mBottom - mTop;
|
final int height = mBottom - mTop;
|
||||||
|
|
||||||
boolean rectIsVisible = true;
|
boolean rectIsVisible = true;
|
||||||
if (mParent instanceof ViewGroup && ((ViewGroup)mParent).getClipChildren()) {
|
if (mParent == null ||
|
||||||
|
(mParent instanceof ViewGroup && ((ViewGroup) mParent).getClipChildren())) {
|
||||||
// Clip to bounds.
|
// Clip to bounds.
|
||||||
rectIsVisible = rect.intersect(0, 0, width, height);
|
rectIsVisible = rect.intersect(0, 0, width, height);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user