blob: 8c5c8fa15f8413fe6778a22a418ce4247a68c6e0 [file] [log] [blame]
Winson Chung303e1ff2014-03-07 15:06:19 -08001/*
2 * Copyright (C) 2014 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
17package com.android.systemui.recents;
18
19/**
20 * Constants
21 * XXX: We are going to move almost all of these into a resource.
22 */
23public class Constants {
24 public static class DebugFlags {
25 // Enable this with any other debug flag to see more info
26 public static final boolean Verbose = false;
27
28 public static class App {
Winson Chungc6a16232014-04-01 14:04:48 -070029 public static final boolean EnableTaskFiltering = true;
Winson Chung303e1ff2014-03-07 15:06:19 -080030 public static final boolean EnableTaskStackClipping = false;
Winson Chung47c4c692014-03-17 10:17:11 -070031 public static final boolean EnableToggleNewRecentsActivity = false;
Winson Chung04dfe0d2014-03-14 14:06:29 -070032 // This disables the bitmap and icon caches to
33 public static final boolean DisableBackgroundCache = false;
Winson Chunga10370f2014-04-02 12:25:04 -070034 // For debugging, this enables us to create mock recents tasks
35 public static final boolean EnableSystemServicesProxy = false;
36 // For debugging, this defines the number of mock recents packages to create
37 public static final int SystemServicesProxyMockPackageCount = 12;
38 // For debugging, this defines the number of mock recents tasks to create
39 public static final int SystemServicesProxyMockTaskCount = 75;
Winson Chung4d7b0922014-03-13 17:14:17 -070040
Winson Chungbd912972014-03-18 14:36:35 -070041 // Timing certain paths
42 public static final String TimeRecentsStartupKey = "startup";
43 public static final String TimeRecentsLaunchKey = "launchTask";
44 public static final boolean TimeRecentsStartup = false;
45 public static final boolean TimeRecentsLaunchTask = false;
46
Winson Chung7048fea2014-03-18 12:21:24 -070047 public static final boolean RecentsComponent = false;
Winson Chung71243902014-03-14 17:52:47 -070048 public static final boolean TaskDataLoader = false;
Winson Chung303e1ff2014-03-07 15:06:19 -080049 public static final boolean SystemUIHandshake = false;
50 public static final boolean TimeSystemCalls = false;
Winson Chung4d7b0922014-03-13 17:14:17 -070051 public static final boolean Memory = false;
Winson Chung303e1ff2014-03-07 15:06:19 -080052 }
53
54 public static class UI {
55 public static final boolean Draw = false;
56 public static final boolean ClickEvents = false;
57 public static final boolean TouchEvents = false;
58 public static final boolean MeasureAndLayout = false;
Winson Chung71243902014-03-14 17:52:47 -070059 public static final boolean HwLayers = false;
Winson Chung303e1ff2014-03-07 15:06:19 -080060 }
61
62 public static class TaskStack {
63 public static final boolean SynchronizeViewsWithModel = false;
64 }
65
66 public static class ViewPool {
67 public static final boolean PoolCallbacks = false;
68 }
69 }
70
71 public static class Values {
72 public static class Window {
Winson Chung4d7b0922014-03-13 17:14:17 -070073 // The dark background dim is set behind the empty recents view
Winson Chung303e1ff2014-03-07 15:06:19 -080074 public static final float DarkBackgroundDim = 0.5f;
Winson Chung4d7b0922014-03-13 17:14:17 -070075 // The background dim is set behind the card stack
Winson Chung303e1ff2014-03-07 15:06:19 -080076 public static final float BackgroundDim = 0.35f;
77 }
78
79 public static class RecentsTaskLoader {
80 // XXX: This should be calculated on the first load
81 public static final int PreloadFirstTasksCount = 5;
Winson Chung303e1ff2014-03-07 15:06:19 -080082 }
83
84 public static class TaskStackView {
85 public static class Animation {
86 public static final int TaskRemovedReshuffleDuration = 200;
87 public static final int SnapScrollBackDuration = 650;
Winson Chungc6a16232014-04-01 14:04:48 -070088 public static final int FilteredCurrentViewsDuration = 150;
89 public static final int FilteredNewViewsDuration = 200;
90 public static final int UnfilteredCurrentViewsDuration = 150;
91 public static final int UnfilteredNewViewsDuration = 200;
Winson Chung303e1ff2014-03-07 15:06:19 -080092 }
93
Winson Chung47c4c692014-03-17 10:17:11 -070094 public static final int TaskStackOverscrollRange = 150;
95
Winson Chung303e1ff2014-03-07 15:06:19 -080096 // The padding will be applied to the smallest dimension, and then applied to all sides
97 public static final float StackPaddingPct = 0.15f;
98 // The overlap height relative to the task height
99 public static final float StackOverlapPct = 0.65f;
100 // The height of the peek space relative to the stack height
101 public static final float StackPeekHeightPct = 0.1f;
102 // The min scale of the last card in the peek area
103 public static final float StackPeekMinScale = 0.9f;
104 // The number of cards we see in the peek space
105 public static final int StackPeekNumCards = 3;
106 }
107
108 public static class TaskView {
109 public static class Animation {
110 public static final int TaskDataUpdatedFadeDuration = 250;
Winson Chung47c4c692014-03-17 10:17:11 -0700111 public static final int TaskIconOnEnterDuration = 175;
112 public static final int TaskIconOnLeavingDuration = 75;
Winson Chung303e1ff2014-03-07 15:06:19 -0800113 }
114
115 public static final boolean AnimateFrontTaskIconOnEnterRecents = true;
116 public static final boolean AnimateFrontTaskIconOnLeavingRecents = true;
Winson Chung37c8d8e2014-03-24 14:53:07 -0700117
Winson Chungc6a16232014-04-01 14:04:48 -0700118 public static final boolean UseRoundedCorners = false;
Winson Chung303e1ff2014-03-07 15:06:19 -0800119 public static final float RoundedCornerRadiusDps = 3;
Winson Chung303e1ff2014-03-07 15:06:19 -0800120 }
121 }
Winson Chung303e1ff2014-03-07 15:06:19 -0800122}