Remove scrim on highlighted spring-loaded panel.

Bug: 27135377
Change-Id: I470955ed082a45ae7dc5f8fdd1f3decb2b573dbc
This commit is contained in:
Tony Wickham
2016-02-18 14:37:07 -08:00
parent 16466f1bbb
commit 95cdb3a021
7 changed files with 51 additions and 9 deletions

View File

@@ -625,17 +625,23 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
// we moved this functionality to a helper function so SmoothPagedView can reuse it
protected boolean computeScrollHelper() {
return computeScrollHelper(true);
}
protected boolean computeScrollHelper(boolean shouldInvalidate) {
if (mScroller.computeScrollOffset()) {
// Don't bother scrolling if the page does not need to be moved
if (getScrollX() != mScroller.getCurrX()
|| getScrollY() != mScroller.getCurrY()) {
|| getScrollY() != mScroller.getCurrY()) {
float scaleX = mFreeScroll ? getScaleX() : 1f;
int scrollX = (int) (mScroller.getCurrX() * (1 / scaleX));
scrollTo(scrollX, mScroller.getCurrY());
}
invalidate();
if (shouldInvalidate) {
invalidate();
}
return true;
} else if (mNextPage != INVALID_PAGE) {
} else if (mNextPage != INVALID_PAGE && shouldInvalidate) {
sendScrollAccessibilityEvent();
mCurrentPage = validateNewPage(mNextPage);