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 android.server.wm.alertwindowappsdk25; 18 19 import android.os.Bundle; 20 21 import static android.view.WindowManager.LayoutParams.TYPE_PHONE; 22 import static android.view.WindowManager.LayoutParams.TYPE_PRIORITY_PHONE; 23 import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_ALERT; 24 import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_ERROR; 25 import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_OVERLAY; 26 27 public class AlertWindowTestActivitySdk25 extends AlertWindowTestBaseActivity { 28 private static final int[] ALERT_WINDOW_TYPES = { 29 TYPE_PHONE, 30 TYPE_PRIORITY_PHONE, 31 TYPE_SYSTEM_ALERT, 32 TYPE_SYSTEM_ERROR, 33 TYPE_SYSTEM_OVERLAY 34 }; 35 36 @Override 37 protected void onCreate(Bundle icicle) { 38 super.onCreate(icicle); 39 createAllAlertWindows(getPackageName()); 40 } 41 42 @Override 43 protected int[] getAlertWindowTypes() { 44 return ALERT_WINDOW_TYPES; 45 } 46 } 47