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 17package com.android.systemui.shared.recents; 18 19import android.graphics.Rect; 20import com.android.systemui.shared.system.GraphicBufferCompat; 21 22/** 23 * Temporary callbacks into SystemUI. 24 */ 25interface ISystemUiProxy { 26 27 /** 28 * Proxies SurfaceControl.screenshotToBuffer(). 29 */ 30 GraphicBufferCompat screenshot(in Rect sourceCrop, int width, int height, int minLayer, 31 int maxLayer, boolean useIdentityTransform, int rotation) = 0; 32 33 /** 34 * Begins screen pinning on the provided {@param taskId}. 35 */ 36 void startScreenPinning(int taskId) = 1; 37 38 /** 39 * Enables/disables launcher/overview interaction features {@link InteractionType}. 40 */ 41 void setInteractionState(int flags) = 4; 42 43 /** 44 * Notifies SystemUI that split screen has been invoked. 45 */ 46 void onSplitScreenInvoked() = 5; 47 48 /** 49 * Notifies SystemUI that Overview is shown. 50 */ 51 void onOverviewShown(boolean fromHome) = 6; 52 53 /** 54 * Get the secondary split screen app's rectangle when not minimized. 55 */ 56 Rect getNonMinimizedSplitScreenSecondaryBounds() = 7; 57 58 /** 59 * Control the {@param alpha} of the back button in the navigation bar and {@param animate} if 60 * needed from current value 61 */ 62 void setBackButtonAlpha(float alpha, boolean animate) = 8; 63} 64