Merge "Skype is not opening in full screen"

This commit is contained in:
Jerry Chang
2022-12-20 07:59:16 +00:00
committed by Gerrit Code Review

View File

@@ -1085,10 +1085,14 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
// Use launch-adjacent-flag-root if launching with launch-adjacent flag. // Use launch-adjacent-flag-root if launching with launch-adjacent flag.
if ((launchFlags & FLAG_ACTIVITY_LAUNCH_ADJACENT) != 0 if ((launchFlags & FLAG_ACTIVITY_LAUNCH_ADJACENT) != 0
&& mLaunchAdjacentFlagRootTask != null) { && mLaunchAdjacentFlagRootTask != null) {
// If the adjacent launch is coming from the same root, launch to adjacent root instead. if (sourceTask != null && sourceTask == candidateTask) {
if (sourceTask != null && mLaunchAdjacentFlagRootTask.getAdjacentTaskFragment() != null // Do nothing when task that is getting opened is same as the source.
} else if (sourceTask != null
&& mLaunchAdjacentFlagRootTask.getAdjacentTaskFragment() != null
&& (sourceTask == mLaunchAdjacentFlagRootTask && (sourceTask == mLaunchAdjacentFlagRootTask
|| sourceTask.isDescendantOf(mLaunchAdjacentFlagRootTask))) { || sourceTask.isDescendantOf(mLaunchAdjacentFlagRootTask))) {
// If the adjacent launch is coming from the same root, launch to
// adjacent root instead.
return mLaunchAdjacentFlagRootTask.getAdjacentTaskFragment().asTask(); return mLaunchAdjacentFlagRootTask.getAdjacentTaskFragment().asTask();
} else { } else {
return mLaunchAdjacentFlagRootTask; return mLaunchAdjacentFlagRootTask;