/frameworks/base/services/core/java/com/android/server/wm/ |
D | WindowOrganizerController.java | 409 final TaskFragment taskFragment = getTaskFragment(tfToken); in isCreatedTaskFragmentReady() local 410 if (taskFragment != null && !taskFragment.isReadyToTransit()) { in isCreatedTaskFragmentReady() 942 private int applyTaskFragmentChanges(@NonNull TaskFragment taskFragment, in applyTaskFragmentChanges() argument 944 if (taskFragment.isEmbeddedTaskFragmentInPip()) { in applyTaskFragmentChanges() 953 mTmpBounds0.set(taskFragment.getBounds()); in applyTaskFragmentChanges() 954 mTmpBounds1.set(taskFragment.getRelativeEmbeddedBounds()); in applyTaskFragmentChanges() 955 taskFragment.deferOrganizedTaskFragmentSurfaceUpdate(); in applyTaskFragmentChanges() 959 adjustTaskFragmentRelativeBoundsForMinDimensionsIfNeeded(taskFragment, relBounds, in applyTaskFragmentChanges() 965 final Rect parentBounds = taskFragment.getParent().getBounds(); in applyTaskFragmentChanges() 967 final Rect absBounds = taskFragment.translateRelativeBoundsToAbsoluteBounds(relBounds, in applyTaskFragmentChanges() [all …]
|
D | TaskFragmentOrganizerController.java | 200 boolean addTaskFragment(TaskFragment taskFragment) { in addTaskFragment() argument 201 if (taskFragment.mTaskFragmentAppearedSent) { in addTaskFragment() 204 if (mOrganizedTaskFragments.contains(taskFragment)) { in addTaskFragment() 207 mOrganizedTaskFragments.add(taskFragment); in addTaskFragment() 211 void removeTaskFragment(TaskFragment taskFragment) { in removeTaskFragment() argument 212 mOrganizedTaskFragments.remove(taskFragment); in removeTaskFragment() 218 final TaskFragment taskFragment = mOrganizedTaskFragments.get(i); in dispose() local 219 if (taskFragment.isVisibleRequested()) { in dispose() 225 taskFragment.onTaskFragmentOrganizerRemoved(); in dispose() 245 final TaskFragment taskFragment = mOrganizedTaskFragments.remove(0); in dispose() local [all …]
|
D | ActivityStartInterceptor.java | 153 final TaskFragment taskFragment = getLaunchTaskFragment(); in createIntentSenderForOriginalIntent() local 156 if (taskFragment != null) { in createIntentSenderForOriginalIntent() 157 activityOptions.setLaunchTaskFragmentToken(taskFragment.getFragmentToken()); in createIntentSenderForOriginalIntent() 393 final TaskFragment taskFragment = getLaunchTaskFragment(); in interceptLockedProfileIfNeeded() local 400 } else if (taskFragment != null) { in interceptLockedProfileIfNeeded() 404 final Task parentTask = taskFragment.getTask(); in interceptLockedProfileIfNeeded()
|
D | TaskFragment.java | 446 void setAdjacentTaskFragment(@Nullable TaskFragment taskFragment) { in setAdjacentTaskFragment() argument 447 if (mAdjacentTaskFragment == taskFragment) { in setAdjacentTaskFragment() 451 if (taskFragment != null) { in setAdjacentTaskFragment() 452 mAdjacentTaskFragment = taskFragment; in setAdjacentTaskFragment() 453 taskFragment.setAdjacentTaskFragment(this); in setAdjacentTaskFragment() 1242 final TaskFragment taskFragment = adjacentTaskFragments.get(j); in getVisibility() local 1244 taskFragment.mAdjacentTaskFragment; in getVisibility() 1248 if (mTmpRect.intersect(taskFragment.getBounds()) in getVisibility() 2941 forAllTaskFragments(taskFragment -> taskFragment.mLastPausedActivity = null); in clearLastPausedActivity() 3086 task.forAllLeafTaskFragments(taskFragment -> { in cleanUpEmbeddedTaskFragment() [all …]
|
D | ActivityStarter.java | 2112 static int canEmbedActivity(@NonNull TaskFragment taskFragment, in canEmbedActivity() argument 2114 final Task hostTask = taskFragment.getTask(); in canEmbedActivity() 2119 return taskFragment.isAllowedToEmbedActivity(starting); in canEmbedActivity() 3007 final TaskFragment taskFragment = wc.asTaskFragment(); in findCandidateTaskFragment() local 3008 if (taskFragment == null || taskFragment.isRemovalRequested()) { in findCandidateTaskFragment() 3012 if (taskFragment.getActivity(ActivityRecord::canBeTopRunning) == null) { in findCandidateTaskFragment() 3016 if (taskFragment.isIsolatedNav()) { in findCandidateTaskFragment() 3020 if (sourceTaskFragment != null && sourceTaskFragment == taskFragment) { in findCandidateTaskFragment() 3022 return taskFragment; in findCandidateTaskFragment() 3024 if (taskFragment.isPinned()) { in findCandidateTaskFragment() [all …]
|
D | AppTransitionController.java | 709 final boolean hasMultipleOrganizers = task.forAllLeafTaskFragments(taskFragment -> { in findTaskFragmentOrganizer() 710 final ITaskFragmentOrganizer tfOrganizer = taskFragment.getTaskFragmentOrganizer(); in findTaskFragmentOrganizer() 1227 final TaskFragment taskFragment = container.asTaskFragment(); in handleClosingChangingContainers() local 1228 if (taskFragment != null) { in handleClosingChangingContainers() 1229 taskFragment.updateOrganizedTaskFragmentSurface(); in handleClosingChangingContainers() 1344 final boolean notReady = rootTask.forAllLeafTaskFragments(taskFragment -> { in transitionGoodToGoForTaskFragments() 1345 if (!taskFragment.isReadyToTransit()) { in transitionGoodToGoForTaskFragments() 1347 taskFragment); in transitionGoodToGoForTaskFragments()
|
D | LockTaskController.java | 265 final TaskFragment taskFragment = activity.getTaskFragment(); in activityBlockedFromFinish() local 266 final TaskFragment adjacentTaskFragment = taskFragment.getAdjacentTaskFragment(); in activityBlockedFromFinish() 267 if (taskFragment.asTask() != null in activityBlockedFromFinish() 268 || !taskFragment.isDelayLastActivityRemoval() in activityBlockedFromFinish() 276 taskFragment.getActivity(a -> !a.finishing && a != activity) != null; in activityBlockedFromFinish()
|
D | Transition.java | 2375 final TaskFragment taskFragment = wc.asTaskFragment(); in isTranslucent() local 2376 if (taskFragment == null) { in isTranslucent() 2382 if (taskFragment.isTranslucentForTransition()) { in isTranslucent() 2386 final TaskFragment adjacentTaskFragment = taskFragment.getAdjacentTaskFragment(); in isTranslucent() 2804 final TaskFragment taskFragment = target.asTaskFragment(); in calculateTransitionInfo() local 2805 final boolean isEmbeddedTaskFragment = taskFragment != null in calculateTransitionInfo() 2806 && taskFragment.isEmbedded(); in calculateTransitionInfo() 2857 : taskFragment.getOrganizedTaskFragment(); in calculateTransitionInfo() 2870 : taskFragment.getTask(); in calculateTransitionInfo() 2884 final TaskFragmentAnimationParams params = taskFragment.getAnimationParams(); in calculateTransitionInfo() [all …]
|
D | Task.java | 1422 final TaskFragment taskFragment = newTop.getTaskFragment(); in moveActivityToFront() local 1424 if (taskFragment != this) { in moveActivityToFront() 1425 if (taskFragment.isEmbedded() && taskFragment.getNonFinishingActivityCount() == 1) { in moveActivityToFront() 1426 taskFragment.mClearedForReorderActivityToFront = true; in moveActivityToFront() 1430 if (taskFragment.isEmbedded()) { in moveActivityToFront() 1739 final TaskFragment taskFragment = mChildren.get(i).asTaskFragment(); in moveTaskFragmentsToBottomIfNeeded() local 1740 if (taskFragment != null && taskFragment.isMoveToBottomIfClearWhenLaunch()) { in moveTaskFragmentsToBottomIfNeeded() 1744 taskFragmentsToMove.add(taskFragment); in moveTaskFragmentsToBottomIfNeeded() 1754 final TaskFragment taskFragment = taskFragmentsToMove.get(i); in moveTaskFragmentsToBottomIfNeeded() local 1758 mTransitionController.collect(taskFragment); in moveTaskFragmentsToBottomIfNeeded() [all …]
|
D | ActivityRecord.java | 3196 final TaskFragment taskFragment = getOrganizedTaskFragment(); in isEmbeddedInHostContainer() local 3197 return taskFragment != null && taskFragment.isEmbeddedWithBoundsOverride(); in isEmbeddedInHostContainer() 3948 final TaskFragment taskFragment = getTaskFragment(); in completeFinishing() local 3949 if (next != null && taskFragment != null && taskFragment.isEmbedded()) { in completeFinishing() 3950 final TaskFragment organized = taskFragment.getOrganizedTaskFragment(); in completeFinishing() 4205 final TaskFragment taskFragment = getTaskFragment(); in makeFinishingLocked() local 4206 if (taskFragment != null) { in makeFinishingLocked() 4207 final Task task = taskFragment.getTask(); in makeFinishingLocked() 4209 && taskFragment.getTopNonFinishingActivity() == null) { in makeFinishingLocked() 4210 taskFragment.mClearedTaskForReuse = true; in makeFinishingLocked() [all …]
|
D | ActivityStartController.java | 559 int startActivityInTaskFragment(@NonNull TaskFragment taskFragment, in startActivityInTaskFragment() argument 569 .setInTaskFragment(taskFragment) in startActivityInTaskFragment()
|
D | ActivityClientController.java | 1690 final TaskFragment taskFragment = r.getTaskFragment(); in isRelativeTaskRootActivity() local 1691 if (r != taskFragment.getActivity(ar -> !ar.finishing || ar == r, in isRelativeTaskRootActivity() 1698 return taskRoot.getTaskFragment().getCompanionTaskFragment() == taskFragment; in isRelativeTaskRootActivity()
|
D | BackgroundActivityStartController.java | 1403 TaskFragment taskFragment = topActivity.getTaskFragment(); in checkTopActivityForAsm() local 1404 if (taskFragment == null) { in checkTopActivityForAsm() 1408 TaskFragment adjacentTaskFragment = taskFragment.getAdjacentTaskFragment(); in checkTopActivityForAsm()
|
D | WindowProcessController.java | 1493 final TaskFragment taskFragment = r.getTaskFragment(); in handleAppDied() local 1494 if (taskFragment != null) { in handleAppDied() 1498 hasVisibleActivities |= taskFragment.handleAppDied(this); in handleAppDied()
|
D | WindowContainer.java | 3282 final TaskFragment taskFragment = asTaskFragment(); in applyAnimationUnchecked() local 3287 || (taskFragment != null && taskFragment.isEmbedded() in applyAnimationUnchecked() 3297 : taskFragment.getOrganizedTaskFragment(); in applyAnimationUnchecked() 3311 : taskFragment.getTask(); in applyAnimationUnchecked()
|
D | ActivityTaskSupervisor.java | 809 final TaskFragment taskFragment = r.getTaskFragment(); in realStartActivityLocked() local 810 if (taskFragment != null && taskFragment.getResumedActivity() != null) { in realStartActivityLocked() 811 if (taskFragment.startPausing(mUserLeaving, false /* uiSleeping */, r, in realStartActivityLocked()
|
/frameworks/base/services/tests/wmtests/src/com/android/server/wm/ |
D | TaskFragmentTest.java | 424 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testEmbeddedActivityExitPip_notifyOrganizer() local 436 final ActivityRecord activity = taskFragment.getTopMostActivity(); in testEmbeddedActivityExitPip_notifyOrganizer() 452 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testIsReadyToTransit() local 457 final Task task = taskFragment.getTask(); in testIsReadyToTransit() 460 assertFalse(taskFragment.isReadyToTransit()); in testIsReadyToTransit() 465 activity.reparent(taskFragment, WindowContainer.POSITION_TOP); in testIsReadyToTransit() 466 assertTrue(taskFragment.isReadyToTransit()); in testIsReadyToTransit() 469 taskFragment.removeChild(activity); in testIsReadyToTransit() 471 assertTrue(taskFragment.isReadyToTransit()); in testIsReadyToTransit() 475 taskFragment.mClearedTaskFragmentForPip = true; in testIsReadyToTransit() [all …]
|
D | AppTransitionControllerTest.java | 851 final TaskFragment taskFragment = createTaskFragmentWithEmbeddedActivity(task, organizer); in testOverrideTaskFragmentAdapter_overrideWithEmbeddedActivity() local 852 final ActivityRecord activity = taskFragment.getTopMostActivity(); in testOverrideTaskFragmentAdapter_overrideWithEmbeddedActivity() 857 prepareAndTriggerAppTransition(activity, null /* closingActivity */, taskFragment); in testOverrideTaskFragmentAdapter_overrideWithEmbeddedActivity() 873 final TaskFragment taskFragment = createTaskFragmentWithEmbeddedActivity(task, organizer); in testOverrideTaskFragmentAdapter_noOverrideWithOnlyTaskFragmentFillingTask() local 876 assertFalse(taskFragment.isEmbeddedWithBoundsOverride()); in testOverrideTaskFragmentAdapter_noOverrideWithOnlyTaskFragmentFillingTask() 877 final ActivityRecord openingActivity = taskFragment.getTopMostActivity(); in testOverrideTaskFragmentAdapter_noOverrideWithOnlyTaskFragmentFillingTask() 904 final TaskFragment taskFragment = createTaskFragmentWithEmbeddedActivity(task, organizer); in testOverrideTaskFragmentAdapter_overrideWithTaskFragmentNotFillingTask() local 907 taskFragment.setWindowingMode(WINDOWING_MODE_MULTI_WINDOW); in testOverrideTaskFragmentAdapter_overrideWithTaskFragmentNotFillingTask() 910 taskFragment.setBounds(embeddedBounds); in testOverrideTaskFragmentAdapter_overrideWithTaskFragmentNotFillingTask() 911 assertTrue(taskFragment.isEmbeddedWithBoundsOverride()); in testOverrideTaskFragmentAdapter_overrideWithTaskFragmentNotFillingTask() [all …]
|
D | TaskFragmentOrganizerControllerTest.java | 454 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testOnActivityReparentedToTask_activityInOrganizerProcess_useActivityToken() local 458 taskFragment.setTaskFragmentOrganizer(mOrganizer.getOrganizerToken(), uid, in testOnActivityReparentedToTask_activityInOrganizerProcess_useActivityToken() 460 activity.reparent(taskFragment, POSITION_TOP); in testOnActivityReparentedToTask_activityInOrganizerProcess_useActivityToken() 696 final TaskFragment taskFragment = mWindowOrganizerController.getTaskFragment( in testApplyTransaction_enforceHierarchyChange_createTaskFragment() local 698 assertNotNull(taskFragment); in testApplyTransaction_enforceHierarchyChange_createTaskFragment() 699 assertEquals(ownerActivity.getTask(), taskFragment.getTask()); in testApplyTransaction_enforceHierarchyChange_createTaskFragment() 961 final TaskFragment taskFragment = mWindowOrganizerController.getTaskFragment( in testApplyTransaction_createTaskFragment_withPairedPrimaryFragmentToken() local 963 assertNotNull(taskFragment); in testApplyTransaction_createTaskFragment_withPairedPrimaryFragmentToken() 966 task.mChildren.indexOf(taskFragment)); in testApplyTransaction_createTaskFragment_withPairedPrimaryFragmentToken() 968 assertEquals(task.mChildren.indexOf(taskFragment) + 1, in testApplyTransaction_createTaskFragment_withPairedPrimaryFragmentToken() [all …]
|
D | ActivityStarterTests.java | 1242 final TaskFragment taskFragment = new TaskFragment(mAtm, sourceRecord.token, in testStartActivityInner_inTaskFragment_failsByDefault() local 1244 sourceRecord.getTask().addChild(taskFragment, POSITION_TOP); in testStartActivityInner_inTaskFragment_failsByDefault() 1247 null /* inTask */, taskFragment); in testStartActivityInner_inTaskFragment_failsByDefault() 1249 assertFalse(taskFragment.hasChild()); in testStartActivityInner_inTaskFragment_failsByDefault() 1258 final TaskFragment taskFragment = new TaskFragment(mAtm, sourceRecord.token, in testStartActivityInner_inTaskFragment_allowedForSystemUid() local 1260 sourceRecord.getTask().addChild(taskFragment, POSITION_TOP); in testStartActivityInner_inTaskFragment_allowedForSystemUid() 1262 taskFragment.setTaskFragmentOrganizer(mock(TaskFragmentOrganizerToken.class), SYSTEM_UID, in testStartActivityInner_inTaskFragment_allowedForSystemUid() 1266 null /* inTask */, taskFragment); in testStartActivityInner_inTaskFragment_allowedForSystemUid() 1268 assertTrue(taskFragment.hasChild()); in testStartActivityInner_inTaskFragment_allowedForSystemUid() 1276 final TaskFragment taskFragment = new TaskFragment(mAtm, sourceRecord.token, in testStartActivityInner_inTaskFragment_allowedForSameUid() local [all …]
|
D | AppTransitionTests.java | 212 final TaskFragment taskFragment = new TaskFragment(mAtm, new Binder(), in testTaskFragmentChange() local 214 activity.getTask().addChild(taskFragment, POSITION_TOP); in testTaskFragmentChange() 215 activity.reparent(taskFragment, POSITION_TOP); in testTaskFragmentChange() 220 mDc.mChangingContainers.add(taskFragment); in testTaskFragmentChange() 443 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testActivityRecordReparentedToTaskFragment() local 449 taskFragment.setBounds(0, 0, taskBounds.right / 2, taskBounds.bottom); in testActivityRecordReparentedToTaskFragment() 450 spyOn(taskFragment); in testActivityRecordReparentedToTaskFragment() 451 mockSurfaceFreezerSnapshot(taskFragment.mSurfaceFreezer); in testActivityRecordReparentedToTaskFragment() 458 activity.reparent(taskFragment, POSITION_TOP); in testActivityRecordReparentedToTaskFragment() 461 verify(taskFragment).initializeChangeTransition(activity.getBounds(), activityLeash); in testActivityRecordReparentedToTaskFragment() [all …]
|
D | WindowOrganizerTests.java | 594 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testTaskFragmentHiddenFocusableTranslucentChanges() local 603 assertTrue(taskFragment.shouldBeVisible(null)); in testTaskFragmentHiddenFocusableTranslucentChanges() 604 assertTrue(taskFragment.isFocusable()); in testTaskFragmentHiddenFocusableTranslucentChanges() 605 assertTrue(taskFragment.isTopActivityFocusable()); in testTaskFragmentHiddenFocusableTranslucentChanges() 606 assertFalse(taskFragment.isForceTranslucent()); in testTaskFragmentHiddenFocusableTranslucentChanges() 609 t.setHidden(taskFragment.mRemoteToken.toWindowContainerToken(), true); in testTaskFragmentHiddenFocusableTranslucentChanges() 610 t.setFocusable(taskFragment.mRemoteToken.toWindowContainerToken(), false); in testTaskFragmentHiddenFocusableTranslucentChanges() 611 t.setForceTranslucent(taskFragment.mRemoteToken.toWindowContainerToken(), true); in testTaskFragmentHiddenFocusableTranslucentChanges() 617 assertFalse(taskFragment.shouldBeVisible(null)); in testTaskFragmentHiddenFocusableTranslucentChanges() 618 assertFalse(taskFragment.isFocusable()); in testTaskFragmentHiddenFocusableTranslucentChanges() [all …]
|
D | RootWindowContainerTests.java | 443 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testSingleActivityInTaskFragmentEnterPip() local 447 final ActivityRecord activity = taskFragment.getTopMostActivity(); in testSingleActivityInTaskFragmentEnterPip() 468 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testMultipleActivitiesInTaskFragmentEnterPip() local 472 final ActivityRecord firstActivity = taskFragment.getTopMostActivity(); in testMultipleActivitiesInTaskFragmentEnterPip() 473 final ActivityRecord secondActivity = taskFragment.getBottomMostActivity(); in testMultipleActivitiesInTaskFragmentEnterPip() 499 final TaskFragment taskFragment = new TaskFragmentBuilder(mAtm) in testMovingEmbeddedActivityToPip() local 504 assertEquals(taskFragmentBounds, taskFragment.getBounds()); in testMovingEmbeddedActivityToPip() 505 final ActivityRecord topActivity = taskFragment.getTopMostActivity(); in testMovingEmbeddedActivityToPip()
|
D | WindowTestsBase.java | 903 final TaskFragment taskFragment = new TaskFragmentBuilder(parentTask.mAtmService) in createTaskFragmentWithEmbeddedActivity() local 910 .put(fragmentToken, taskFragment); in createTaskFragmentWithEmbeddedActivity() 911 return taskFragment; in createTaskFragmentWithEmbeddedActivity() 1569 final TaskFragment taskFragment = new TaskFragment(mAtm, mFragmentToken, in build() local 1575 mParentTask.addChild(taskFragment, POSITION_TOP); in build() 1579 taskFragment.addChild(activity); in build() 1583 taskFragment.setTaskFragmentOrganizer( in build() 1588 taskFragment.setBounds(mBounds); in build() 1590 spyOn(taskFragment); in build() 1591 return taskFragment; in build()
|
D | ActivityRecordTests.java | 213 final TaskFragment taskFragment = activity.getTaskFragment(); in testTaskFragmentCleanupOnClearingTask() local 215 verify(taskFragment).cleanUpActivityReferences(any()); in testTaskFragmentCleanupOnClearingTask() 222 final TaskFragment taskFragment = activity.getTaskFragment(); in testTaskFragmentCleanupOnActivityRemoval() local 224 verify(taskFragment).cleanUpActivityReferences(any()); in testTaskFragmentCleanupOnActivityRemoval() 3051 final TaskFragment taskFragment = createTaskFragmentWithActivity(task); in testTransitionAnimationBounds_returnTaskFragment() local 3052 final ActivityRecord activity = taskFragment.getTopNonFinishingActivity(); in testTransitionAnimationBounds_returnTaskFragment() 3061 taskFragment.getWindowConfiguration().setBounds(taskFragmentBounds); in testTransitionAnimationBounds_returnTaskFragment() 3066 assertEquals(taskFragment.getBounds(), activity.getAnimationBounds(ROOT_TASK_CLIP_NONE)); in testTransitionAnimationBounds_returnTaskFragment() 3071 assertEquals(taskFragment.getBounds(), in testTransitionAnimationBounds_returnTaskFragment() 3664 final TaskFragment taskFragment = new TaskFragment(mAtm, new Binder(), in testEnsureActivitiesVisibleAnotherUserTasks() local [all …]
|