1 /*
2  * Copyright (C) 2022 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.quickstep.util;
18 
19 import static com.android.app.animation.Interpolators.LINEAR;
20 
21 import android.view.animation.Interpolator;
22 
23 /**
24  * Timings for the Home > OverviewSplitSelect animation on tablets.
25  */
26 public class TabletHomeToSplitTimings
27         extends TabletOverviewToSplitTimings implements SplitAnimationTimings {
28     @Override
getStagedRectXInterpolator()29     public Interpolator getStagedRectXInterpolator() { return LINEAR; }
30     @Override
getStagedRectScaleXInterpolator()31     public Interpolator getStagedRectScaleXInterpolator() { return LINEAR; }
32     @Override
getStagedRectScaleYInterpolator()33     public Interpolator getStagedRectScaleYInterpolator() { return LINEAR; }
34 
getScrimFadeInStart()35     public int getScrimFadeInStart() { return 0; }
getScrimFadeInEnd()36     public int getScrimFadeInEnd() { return 167; }
37 
getScrimFadeInStartOffset()38     public float getScrimFadeInStartOffset() {
39         return (float) getScrimFadeInStart() / getDuration();
40     }
getScrimFadeInEndOffset()41     public float getScrimFadeInEndOffset() {
42         return (float) getScrimFadeInEnd() / getDuration();
43     }
44 }
45