am 8a9a0b8f: am 6fee9288: am 5df6c6fe: am ecd4b988: Fix AppBarLayout not scrolling fully

* commit '8a9a0b8f8bebb57b24ced907813fbc9f91ec8e6d':
  Fix AppBarLayout not scrolling fully

GitOrigin-RevId=f61c1e4c51b2a45471adc4cc80338ca79716c828

PiperOrigin-RevId: 140548665
This commit is contained in:
Chris Banes 2016-11-30 01:18:22 +00:00 committed by Travis Collins
parent ba415acdc2
commit 7d75b44129

View File

@ -50,16 +50,14 @@ class ViewOffsetHelper {
updateOffsets();
}
private void updateOffsets() {
if (mOffsetLeft != 0 || mOffsetTop != 0) {
ViewCompat.offsetTopAndBottom(mView, mOffsetTop - (mView.getTop() - mLayoutTop));
ViewCompat.offsetLeftAndRight(mView, mOffsetLeft - (mView.getLeft() - mLayoutLeft));
private void updateOffsets() {
ViewCompat.offsetTopAndBottom(mView, mOffsetTop - (mView.getTop() - mLayoutTop));
ViewCompat.offsetLeftAndRight(mView, mOffsetLeft - (mView.getLeft() - mLayoutLeft));
// Manually invalidate the parent to make sure we get drawn
ViewParent parent = mView.getParent();
if (parent instanceof View) {
((View) parent).invalidate();
}
// Manually invalidate the parent to make sure we get drawn
ViewParent parent = mView.getParent();
if (parent instanceof View) {
((View) parent).invalidate();
}
}