Consider orientationHandler when calculating ClearAllButton scrollOffset
Bug: 185498648 Fixes: 185498648 Test: Manual Change-Id: I7aaab4e62c3e7edf3ecdb3fe40020b8064e0109b
This commit is contained in:
@@ -3152,7 +3152,8 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
|
||||
// Align ClearAllButton to the left (RTL) or right (non-RTL), which is different from other
|
||||
// TaskViews. This must be called after laying out ClearAllButton.
|
||||
if (layoutChildren) {
|
||||
int clearAllWidthDiff = mTaskWidth - mClearAllButton.getWidth();
|
||||
int clearAllWidthDiff = mOrientationHandler.getPrimaryValue(mTaskWidth, mTaskHeight)
|
||||
- mOrientationHandler.getPrimarySize(mClearAllButton);
|
||||
mClearAllButton.setScrollOffsetPrimary(mIsRtl ? clearAllWidthDiff : -clearAllWidthDiff);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user