Merge "Add a button for floating tasks to taskbar (behind a flag)" into tm-qpr-dev

This commit is contained in:
Mady Mellor authored and Android (Google) Code Review committed 2022-09-22 14:58:13 +00:00
commit 13b7e00fff
8 files changed
+250 -4

No files matched your search

@@ -58,6 +58,7 @@ import com.android.systemui.shared.system.smartspace.ILauncherUnlockAnimationCon
import com.android.systemui.shared.system.smartspace.ISysuiUnlockAnimationController;
import com.android.systemui.shared.system.smartspace.SmartspaceState;
import com.android.wm.shell.back.IBackAnimation;
import com.android.wm.shell.floating.IFloatingTasks;
import com.android.wm.shell.onehanded.IOneHanded;
import com.android.wm.shell.pip.IPip;
import com.android.wm.shell.pip.IPipAnimationListener;
@@ -88,6 +89,7 @@ public class SystemUiProxy implements ISystemUiProxy {
private IPip mPip;
private ISysuiUnlockAnimationController mSysuiUnlockAnimationController;
private ISplitScreen mSplitScreen;
private IFloatingTasks mFloatingTasks;
private IOneHanded mOneHanded;
private IShellTransitions mShellTransitions;
private IStartingWindow mStartingWindow;
@@ -164,7 +166,7 @@ public class SystemUiProxy implements ISystemUiProxy {
}
public void setProxy(ISystemUiProxy proxy, IPip pip, ISplitScreen splitScreen,
IOneHanded oneHanded, IShellTransitions shellTransitions,
IFloatingTasks floatingTasks, IOneHanded oneHanded, IShellTransitions shellTransitions,
IStartingWindow startingWindow, IRecentTasks recentTasks,
ISysuiUnlockAnimationController sysuiUnlockAnimationController,
IBackAnimation backAnimation) {
@@ -172,6 +174,7 @@ public class SystemUiProxy implements ISystemUiProxy {
mSystemUiProxy = proxy;
mPip = pip;
mSplitScreen = splitScreen;
mFloatingTasks = floatingTasks;
mOneHanded = oneHanded;
mShellTransitions = shellTransitions;
mStartingWindow = startingWindow;
@@ -204,7 +207,7 @@ public class SystemUiProxy implements ISystemUiProxy {
}
public void clearProxy() {
setProxy(null, null, null, null, null, null, null, null, null);
setProxy(null, null, null, null, null, null, null, null, null, null);
}
// TODO(141886704): Find a way to remove this
@@ -662,6 +665,20 @@ public class SystemUiProxy implements ISystemUiProxy {
return null;
}
//
// Floating tasks
//
public void showFloatingTask(Intent intent) {
if (mFloatingTasks != null) {
try {
mFloatingTasks.showTask(intent);
} catch (RemoteException e) {
Log.w(TAG, "Launcher: Failed call showFloatingTask", e);
}
}
}
//
// One handed
//