From 7db9e7b92c74eb07773f17ead422a032f543babc Mon Sep 17 00:00:00 2001 From: Zak Cohen Date: Fri, 17 Jan 2020 14:13:59 -0800 Subject: [PATCH] SystemUiProxy - add screenshot method. Test: build, manual integration Bug: 145297320 Change-Id: Ia19e4b88a669c4f8d4d29a2e8e61207fee279ac3 --- .../src/com/android/quickstep/SystemUiProxy.java | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/quickstep/src/com/android/quickstep/SystemUiProxy.java b/quickstep/src/com/android/quickstep/SystemUiProxy.java index 5539b3e393..3c6537a72d 100644 --- a/quickstep/src/com/android/quickstep/SystemUiProxy.java +++ b/quickstep/src/com/android/quickstep/SystemUiProxy.java @@ -18,6 +18,8 @@ package com.android.quickstep; import static com.android.launcher3.util.Executors.MAIN_EXECUTOR; import android.content.Context; +import android.graphics.Bitmap; +import android.graphics.Insets; import android.graphics.Rect; import android.os.Bundle; import android.os.IBinder; @@ -25,6 +27,7 @@ import android.os.IBinder.DeathRecipient; import android.os.RemoteException; import android.util.Log; import android.view.MotionEvent; + import com.android.launcher3.util.MainThreadInitializedObject; import com.android.quickstep.util.SharedApiCompat; import com.android.systemui.shared.recents.ISystemUiProxy; @@ -282,4 +285,15 @@ public class SystemUiProxy implements ISystemUiProxy { } } } + + @Override + public void handleImageAsScreenshot(Bitmap bitmap, Rect rect, Insets insets, int i) { + if (mSystemUiProxy != null) { + try { + mSystemUiProxy.handleImageAsScreenshot(bitmap, rect, insets, i); + } catch (RemoteException e) { + Log.w(TAG, "Failed call handleImageAsScreenshot", e); + } + } + } }