1c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek/*
2c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * Copyright (C) 2016 The Android Open Source Project
3c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek *
4c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * Licensed under the Apache License, Version 2.0 (the "License");
5c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * you may not use this file except in compliance with the License.
6c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * You may obtain a copy of the License at
7c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek *
8c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek *      http://www.apache.org/licenses/LICENSE-2.0
9c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek *
10c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * Unless required by applicable law or agreed to in writing, software
11c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * distributed under the License is distributed on an "AS IS" BASIS,
12c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * See the License for the specific language governing permissions and
14c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * limitations under the License
15c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek */
16c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek
17c0d7058b14c24cd07912f5629c26b39b7b4673d5Winsonpackage com.android.systemui;
18c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek
19c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinekimport android.view.animation.AccelerateDecelerateInterpolator;
203b6ba1ab144c53752841869627a1b9f6d357c404Winsonimport android.view.animation.AccelerateInterpolator;
21c0d7058b14c24cd07912f5629c26b39b7b4673d5Winsonimport android.view.animation.DecelerateInterpolator;
22c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinekimport android.view.animation.Interpolator;
23c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinekimport android.view.animation.LinearInterpolator;
24c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinekimport android.view.animation.PathInterpolator;
25c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek
26c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek/**
27c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek * Utility class to receive interpolators from
28c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek */
29c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinekpublic class Interpolators {
30c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator FAST_OUT_SLOW_IN = new PathInterpolator(0.4f, 0f, 0.2f, 1f);
31c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator FAST_OUT_LINEAR_IN = new PathInterpolator(0.4f, 0f, 1f, 1f);
32c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator LINEAR_OUT_SLOW_IN = new PathInterpolator(0f, 0f, 0.2f, 1f);
33c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator ALPHA_IN = new PathInterpolator(0.4f, 0f, 1f, 1f);
34c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator ALPHA_OUT = new PathInterpolator(0f, 0f, 0.8f, 1f);
35c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator LINEAR = new LinearInterpolator();
363b6ba1ab144c53752841869627a1b9f6d357c404Winson    public static final Interpolator ACCELERATE = new AccelerateInterpolator();
37c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek    public static final Interpolator ACCELERATE_DECELERATE = new AccelerateDecelerateInterpolator();
38c0d7058b14c24cd07912f5629c26b39b7b4673d5Winson    public static final Interpolator DECELERATE_QUINT = new DecelerateInterpolator(2.5f);
39d15745bdba23a2cccb08e27bf9aae4d9d4aff270Adrian Roos    public static final Interpolator CUSTOM_40_40 = new PathInterpolator(0.4f, 0f, 0.6f, 1f);
40ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi
41ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi    /**
42ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi     * Interpolator to be used when animating a move based on a click. Pair with enough duration.
43ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi     */
44ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi    public static final Interpolator TOUCH_RESPONSE =
45ea4a19f1aa27ba4b9fc4ec0af1d19b4177f801dfJorim Jaggi            new PathInterpolator(0.3f, 0f, 0.1f, 1f);
46c18010f6720f606003cde3cd376ddacaca30f6e5Selim Cinek}
47