Use taskbarSize to calculate clippedInsets
- Instead of calculating clippedInsets from thumbnail dimension, always use taskbarSize - Clean up clippedInsets code as only bottom inset is ever present Fix: 235328056 Test: With taskbar hidden, out of orientation thumbnail has proper size in quickswitch and overview Change-Id: I3d7fc7899f04862c3401935b10f475e9ab74685a
This commit is contained in:
1 parent
e19aab9010
commit
b00a9fca79
2 files changed
+10
-48
No files matched your search
@@ -164,13 +164,6 @@ public class TaskView extends FrameLayout implements Reusable {
|
||||
return deviceProfile.isTablet;
|
||||
}
|
||||
|
||||
/**
|
||||
* Should the TaskView scale down to fit whole thumbnail in fullscreen.
|
||||
*/
|
||||
public static boolean useFullThumbnail(DeviceProfile deviceProfile) {
|
||||
return deviceProfile.isTablet && !deviceProfile.isTaskbarPresentInApps;
|
||||
}
|
||||
|
||||
private static final float EDGE_SCALE_DOWN_FACTOR_CAROUSEL = 0.03f;
|
||||
private static final float EDGE_SCALE_DOWN_FACTOR_GRID = 0.00f;
|
||||
|
||||
@@ -1576,13 +1569,11 @@ public class TaskView extends FrameLayout implements Reusable {
|
||||
RectF insets = pph.getInsetsToDrawInFullscreen(dp);
|
||||
|
||||
float currentInsetsLeft = insets.left * fullscreenProgress;
|
||||
float currentInsetsTop = insets.top * fullscreenProgress;
|
||||
float currentInsetsRight = insets.right * fullscreenProgress;
|
||||
float insetsBottom = insets.bottom;
|
||||
if (dp.isTaskbarPresentInApps) {
|
||||
insetsBottom = Math.max(0, insetsBottom - dp.taskbarSize);
|
||||
}
|
||||
mCurrentDrawnInsets.set(currentInsetsLeft, insets.top * fullscreenProgress,
|
||||
currentInsetsRight, insetsBottom * fullscreenProgress);
|
||||
float currentInsetsBottom = insets.bottom * fullscreenProgress;
|
||||
mCurrentDrawnInsets.set(
|
||||
currentInsetsLeft, currentInsetsTop, currentInsetsRight, currentInsetsBottom);
|
||||
|
||||
mCurrentDrawnCornerRadius =
|
||||
Utilities.mapRange(fullscreenProgress, mCornerRadius, mWindowCornerRadius)
|
||||
|
||||
Reference in new issue
Block a user