• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2017 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.launcher3.uioverrides;
18 
19 import android.app.ActivityOptions;
20 import android.app.Person;
21 import android.content.Context;
22 import android.content.pm.LauncherActivityInfo;
23 import android.content.pm.ShortcutInfo;
24 
25 import com.android.launcher3.Utilities;
26 
27 import java.util.Collections;
28 import java.util.Map;
29 
30 /**
31  * A wrapper for the hidden API calls
32  */
33 public class ApiWrapper {
34 
35     public static final boolean TASKBAR_DRAWN_IN_PROCESS = false;
36 
getPersons(ShortcutInfo si)37     public static Person[] getPersons(ShortcutInfo si) {
38         return Utilities.EMPTY_PERSON_ARRAY;
39     }
40 
getActivityOverrides(Context context)41     public static Map<String, LauncherActivityInfo> getActivityOverrides(Context context) {
42         return Collections.emptyMap();
43     }
44 
45     /**
46      * Creates an ActivityOptions to play fade-out animation on closing targets
47      */
createFadeOutAnimOptions(Context context)48     public static ActivityOptions createFadeOutAnimOptions(Context context) {
49         return ActivityOptions.makeCustomAnimation(context, 0, android.R.anim.fade_out);
50     }
51 }
52