/frameworks/base/services/tests/wmtests/src/com/android/server/wm/ |
D | RefreshRatePolicyTest.java | 67 private RefreshRatePolicy mPolicy; field in RefreshRatePolicyTest 114 mPolicy = new RefreshRatePolicy(mWm, mDisplayInfo, mDenylist); in setUp() 130 assertEquals(0, mPolicy.getPreferredModeId(cameraUsingWindow)); in testCamera() 131 assertFalse(mPolicy.updateFrameRateVote(cameraUsingWindow)); in testCamera() 133 assertEquals(0, mPolicy.getPreferredMinRefreshRate(cameraUsingWindow), FLOAT_TOLERANCE); in testCamera() 134 assertEquals(0, mPolicy.getPreferredMaxRefreshRate(cameraUsingWindow), FLOAT_TOLERANCE); in testCamera() 135 mPolicy.addRefreshRateRangeForPackage("com.android.test", in testCamera() 137 assertEquals(0, mPolicy.getPreferredModeId(cameraUsingWindow)); in testCamera() 138 assertFalse(mPolicy.updateFrameRateVote(cameraUsingWindow)); in testCamera() 141 mPolicy.getPreferredMinRefreshRate(cameraUsingWindow), FLOAT_TOLERANCE); in testCamera() [all …]
|
D | DisplayRotationImmersiveAppCompatPolicyTests.java | 56 private DisplayRotationImmersiveAppCompatPolicy mPolicy; field in DisplayRotationImmersiveAppCompatPolicyTests 87 mPolicy = DisplayRotationImmersiveAppCompatPolicy.createIfNeeded( in setUp() 121 assertTrue(mPolicy.isRotationLockEnforced(Surface.ROTATION_0)); in testIsRotationLockEnforced_landscapeActivity_lockedWhenRotatingToPortrait() 123 assertFalse(mPolicy.isRotationLockEnforced(Surface.ROTATION_90)); in testIsRotationLockEnforced_landscapeActivity_lockedWhenRotatingToPortrait() 125 assertTrue(mPolicy.isRotationLockEnforced(Surface.ROTATION_180)); in testIsRotationLockEnforced_landscapeActivity_lockedWhenRotatingToPortrait() 127 assertFalse(mPolicy.isRotationLockEnforced(Surface.ROTATION_270)); in testIsRotationLockEnforced_landscapeActivity_lockedWhenRotatingToPortrait() 136 assertFalse(mPolicy.isRotationLockEnforced(Surface.ROTATION_0)); in testIsRotationLockEnforced_portraitActivity_lockedWhenRotatingToLandscape() 138 assertTrue(mPolicy.isRotationLockEnforced(Surface.ROTATION_90)); in testIsRotationLockEnforced_portraitActivity_lockedWhenRotatingToLandscape() 140 assertFalse(mPolicy.isRotationLockEnforced(Surface.ROTATION_180)); in testIsRotationLockEnforced_portraitActivity_lockedWhenRotatingToLandscape() 142 assertTrue(mPolicy.isRotationLockEnforced(Surface.ROTATION_270)); in testIsRotationLockEnforced_portraitActivity_lockedWhenRotatingToLandscape() [all …]
|
D | DisplayAreaPolicyBuilderTest.java | 92 private TestWindowManagerPolicy mPolicy = new TestWindowManagerPolicy(); field in DisplayAreaPolicyBuilderTest 129 .addFeature(foo = new Feature.Builder(mPolicy, "Foo", in testBuilder() 134 .addFeature(bar = new Feature.Builder(mPolicy, "Bar", in testBuilder() 259 .addFeature(dimmable = new Feature.Builder(mPolicy, "Dimmable", in testBuilder_createCustomizedDisplayAreaForFeature() 265 .addFeature(other = new Feature.Builder(mPolicy, "Other", in testBuilder_createCustomizedDisplayAreaForFeature() 395 .addFeature(new Feature.Builder(mPolicy, "testFeature", mRoot.mFeatureId) in testBuilder_rootHasUniqueId() 423 .addFeature(new Feature.Builder(mPolicy, "testFeature", mTda1.mFeatureId) in testBuilder_taskDisplayAreaHasUniqueId() 437 .addFeature(new Feature.Builder(mPolicy, "feature1", FEATURE_VENDOR_FIRST + 10) in testBuilder_featureHasUniqueId() 440 .addFeature(new Feature.Builder(mPolicy, "feature2", FEATURE_VENDOR_FIRST + 10) in testBuilder_featureHasUniqueId() 451 .addFeature(new Feature.Builder(mPolicy, "feature1", FEATURE_VENDOR_FIRST + 10) in testBuilder_featureHasUniqueId() [all …]
|
/frameworks/base/services/tests/wmtests/src/com/android/server/policy/ |
D | WindowWakeUpPolicyTests.java | 95 private WindowWakeUpPolicy mPolicy; field in WindowWakeUpPolicyTests 113 mPolicy = new WindowWakeUpPolicy(mContextSpy, mClock); in testSupportsInputWakeDelegatse_publishesLocalService() 122 mPolicy = new WindowWakeUpPolicy(mContextSpy, mClock); in testDoesNotSupportInputWakeDelegatse_doesNotPublishLocalService() 131 mPolicy = new WindowWakeUpPolicy(mContextSpy, mClock); in testMotionWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 139 assertThat(mPolicy.wakeUpFromMotion(200, SOURCE_TOUCHSCREEN, true)).isTrue(); in testMotionWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 147 assertThat(mPolicy.wakeUpFromMotion(300, SOURCE_ROTARY_ENCODER, false)).isTrue(); in testMotionWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 156 mPolicy = new WindowWakeUpPolicy(mContextSpy, mClock); in testKeyWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 164 assertThat(mPolicy.wakeUpFromKey(200, KEYCODE_POWER, true)).isTrue(); in testKeyWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 172 assertThat(mPolicy.wakeUpFromKey(300, KEYCODE_STEM_PRIMARY, false)).isTrue(); in testKeyWakeUpDelegation_wakePowerManagerIfDelegateDoesNotHandleWake() 184 mPolicy = new WindowWakeUpPolicy(mContextSpy, mClock); in testDelegatedKeyWakeIsSubjectToPolicyChecks() [all …]
|
/frameworks/base/cmds/incidentd/src/ |
D | Privacy.cpp | 76 mPolicy = argPolicy; in PrivacySpec() 79 mPolicy = android::os::PRIVACY_POLICY_AUTOMATIC; in PrivacySpec() 85 return mPolicy < that.mPolicy; in operator <() 90 return isAllowed(mPolicy, check); in CheckPremission() 94 return mPolicy == android::os::PRIVACY_POLICY_LOCAL; in RequireAll()
|
/frameworks/base/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/draganddrop/ |
D | DragAndDropPolicyTest.java | 116 private DragAndDropPolicy mPolicy; field in DragAndDropPolicyTest 154 mPolicy = spy(new DragAndDropPolicy(mContext, mSplitScreenStarter, mSplitScreenStarter)); in setUp() 289 mPolicy.start(dragSession, mLoggerSessionId); in dragOverFullscreenHome_expectOnlyFullscreenTarget() 291 mPolicy.getTargets(mInsets), TYPE_FULLSCREEN); in dragOverFullscreenHome_expectOnlyFullscreenTarget() 293 mPolicy.handleDrop(filterTargetByType(targets, TYPE_FULLSCREEN)); in dragOverFullscreenHome_expectOnlyFullscreenTarget() 304 mPolicy.start(dragSession, mLoggerSessionId); in dragOverFullscreenApp_expectSplitScreenTargets() 306 mPolicy.getTargets(mInsets), TYPE_SPLIT_LEFT, TYPE_SPLIT_RIGHT); in dragOverFullscreenApp_expectSplitScreenTargets() 308 mPolicy.handleDrop(filterTargetByType(targets, TYPE_SPLIT_LEFT)); in dragOverFullscreenApp_expectSplitScreenTargets() 313 mPolicy.handleDrop(filterTargetByType(targets, TYPE_SPLIT_RIGHT)); in dragOverFullscreenApp_expectSplitScreenTargets() 324 mPolicy.start(dragSession, mLoggerSessionId); in dragOverFullscreenAppPhone_expectVerticalSplitScreenTargets() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/devicestate/ |
D | DeviceStateManagerServiceTest.java | 96 private TestDeviceStatePolicy mPolicy; field in DeviceStateManagerServiceTest 105 mPolicy = new TestDeviceStatePolicy(mProvider); in setup() 112 mService = new DeviceStateManagerService(InstrumentationRegistry.getContext(), mPolicy, in setupDeviceStateManagerService() 144 assertEquals(mPolicy.getMostRecentRequestedStateToConfigure(), in baseStateChanged() 154 assertEquals(mPolicy.getMostRecentRequestedStateToConfigure(), in baseStateChanged() 160 mPolicy.blockConfigure(); in baseStateChanged_withStatePendingPolicyCallback() 169 assertEquals(mPolicy.getMostRecentRequestedStateToConfigure(), in baseStateChanged_withStatePendingPolicyCallback() 179 assertEquals(mPolicy.getMostRecentRequestedStateToConfigure(), in baseStateChanged_withStatePendingPolicyCallback() 182 mPolicy.resumeConfigure(); in baseStateChanged_withStatePendingPolicyCallback() 187 assertEquals(mPolicy.getMostRecentRequestedStateToConfigure(), in baseStateChanged_withStatePendingPolicyCallback() [all …]
|
/frameworks/base/services/core/java/com/android/server/wm/ |
D | InsetsPolicy.java | 70 private final DisplayPolicy mPolicy; field in InsetsPolicy 101 mPolicy = displayContent.getDisplayPolicy(); in InsetsPolicy() 102 final Resources r = mPolicy.getContext().getResources(); in InsetsPolicy() 114 final WindowState notificationShade = mPolicy.getNotificationShade(); in updateBarControlTarget() 115 final WindowState topApp = mPolicy.getTopFullscreenOpaqueWindow(); in updateBarControlTarget() 168 mPolicy.getStatusBarManagerInternal(); in showTransient() 464 final StatusBarManagerInternal statusBarManager = mPolicy.getStatusBarManagerInternal(); in checkAbortTransient() 479 final StatusBarManagerInternal statusBarManager = mPolicy.getStatusBarManagerInternal(); in abortTransient() 498 final WindowState notificationShade = mPolicy.getNotificationShade(); in getStatusControlTarget() 515 if (mPolicy.areTypesForciblyShownTransiently(Type.statusBars()) && !fake) { in getStatusControlTarget() [all …]
|
D | DisplayAreaPolicy.java | 133 rootHierarchy.addFeature(new Feature.Builder(wmService.mPolicy, "WindowedMagnification", in configureTrustedHierarchyBuilder() 143 rootHierarchy.addFeature(new Feature.Builder(wmService.mPolicy, "HideDisplayCutout", in configureTrustedHierarchyBuilder() 149 .addFeature(new Feature.Builder(wmService.mPolicy, "OneHanded", in configureTrustedHierarchyBuilder() 157 .addFeature(new Feature.Builder(wmService.mPolicy, "FullscreenMagnification", in configureTrustedHierarchyBuilder() 164 .addFeature(new Feature.Builder(wmService.mPolicy, "ImePlaceholder", in configureTrustedHierarchyBuilder()
|
D | InputManagerCallback.java | 150 mService.mPolicy.notifyLidSwitchChanged(whenNanos, lidOpen); in notifyLidSwitchChanged() 156 mService.mPolicy.notifyCameraLensCoverSwitchChanged(whenNanos, lensCovered); in notifyCameraLensCoverSwitchChanged() 165 return mService.mPolicy.interceptKeyBeforeQueueing(event, policyFlags); in interceptKeyBeforeQueueing() 172 return mService.mPolicy.interceptMotionBeforeQueueingNonInteractive( in interceptMotionBeforeQueueingNonInteractive() 183 return mService.mPolicy.interceptKeyBeforeDispatching(focusedToken, event, policyFlags); in interceptKeyBeforeDispatching() 193 return mService.mPolicy.dispatchUnhandledKey(focusedToken, event, policyFlags); in dispatchUnhandledKey() 199 return mService.mPolicy.getWindowLayerFromTypeLw(WindowManager.LayoutParams.TYPE_POINTER) in getPointerLayer()
|
D | RootDisplayArea.java | 139 int windowLayerFromType = mWmService.mPolicy.getWindowLayerFromTypeLw(windowType, in findAreaForWindowTypeInLayer() 161 final WindowManagerPolicy policy = mWmService.mPolicy; in updateImeContainerForLayers()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/ |
D | DozePauser.java | 36 private final AlwaysOnDisplayPolicy mPolicy; field in DozePauser 42 mPolicy = policy; in DozePauser() 54 mPauseTimeout.schedule(mPolicy.proxScreenOffDelayMs, in transitionTo()
|
/frameworks/opt/car/services/builtInServices/src/com/android/server/wm/ |
D | CarDisplayAreaPolicyProvider.java | 108 .addFeature(new DisplayAreaPolicyBuilder.Feature.Builder(wmService.mPolicy, in instantiate() 114 .addFeature(new DisplayAreaPolicyBuilder.Feature.Builder(wmService.mPolicy, in instantiate() 132 .addFeature(new DisplayAreaPolicyBuilder.Feature.Builder(wmService.mPolicy, in instantiate() 136 .addFeature(new DisplayAreaPolicyBuilder.Feature.Builder(wmService.mPolicy, in instantiate()
|
/frameworks/native/services/surfaceflinger/Scheduler/ |
D | Scheduler.cpp | 425 mPolicy.cachedModeChangedParams = {cycle, mode}; in onPrimaryDisplayModeChanged() 429 mPolicy.contentRequirements.clear(); in onPrimaryDisplayModeChanged() 436 if (!mPolicy.modeOpt) { in dispatchCachedReportedMode() 440 if (!mPolicy.cachedModeChangedParams) { in dispatchCachedReportedMode() 448 if (pacesetterSelectorPtr()->getActiveMode() != mPolicy.modeOpt) { in dispatchCachedReportedMode() 453 if (*mPolicy.modeOpt == mPolicy.cachedModeChangedParams->mode) { in dispatchCachedReportedMode() 457 mPolicy.cachedModeChangedParams->mode = *mPolicy.modeOpt; in dispatchCachedReportedMode() 458 onNonPrimaryDisplayModeChanged(mPolicy.cachedModeChangedParams->cycle, in dispatchCachedReportedMode() 459 mPolicy.cachedModeChangedParams->mode); in dispatchCachedReportedMode() 716 return mPolicy.modeOpt; in chooseRefreshRateForContent() [all …]
|
/frameworks/base/services/accessibility/java/com/android/server/accessibility/ |
D | KeyboardInterceptor.java | 38 private final WindowManagerPolicy mPolicy; field in KeyboardInterceptor 50 mPolicy = policy; in KeyboardInterceptor() 63 mPolicy = policy; in KeyboardInterceptor() 151 return mPolicy.interceptKeyBeforeDispatching(null, event, policyFlags); in getEventDelay()
|
/frameworks/base/services/core/java/com/android/server/inputmethod/ |
D | ImeVisibilityStateComputer.java | 165 private final ImeVisibilityPolicy mPolicy; field in ImeVisibilityStateComputer 198 mPolicy = imePolicy; in ImeVisibilityStateComputer() 235 if (mPolicy.mA11yRequestingNoSoftKeyboard || mPolicy.mImeHiddenByDisplayPolicy) { in onImeShowFlags() 316 mPolicy.setImeHiddenByDisplayPolicy(imeHiddenByPolicy); in computeImeDisplayId() 331 if (!mPolicy.mPendingA11yRequestingHideKeyboard) { in requestImeVisibility() 337 mPolicy.mPendingA11yRequestingHideKeyboard = false; in requestImeVisibility() 602 mPolicy.isA11yRequestNoSoftKeyboard()); in dumpDebug() 610 p.println(prefix + "mImeHiddenByDisplayPolicy=" + mPolicy.isImeHiddenByDisplayPolicy()); in dump() 666 return mPolicy; in getImePolicy()
|
/frameworks/native/services/surfaceflinger/tests/unittests/ |
D | TestableScheduler.h | 170 return mPolicy.touch == Scheduler::TouchState::Active; in isTouchActive() 175 mPolicy.touch = globalSignals.touch ? TouchState::Active : TouchState::Inactive; in setTouchStateAndIdleTimerPolicy() 176 mPolicy.idleTimer = globalSignals.idle ? TimerState::Expired : TimerState::Reset; in setTouchStateAndIdleTimerPolicy() 181 mPolicy.contentRequirements = std::move(layers); in setContentRequirements() 198 mPolicy.cachedModeChangedParams.reset(); in clearCachedReportedMode()
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/net/ |
D | NetworkCycleDataLoader.java | 46 private final NetworkPolicy mPolicy; field in NetworkCycleDataLoader 58 mPolicy = policyEditor.getPolicy(mNetworkTemplate); in NetworkCycleDataLoader() 70 } else if (mPolicy == null) { in loadInBackground() 81 NetworkPolicyManager.cycleIterator(mPolicy); in loadPolicyData()
|
/frameworks/base/libs/input/tests/ |
D | PointerController_test.cpp | 182 sp<MockPointerControllerPolicyInterface> mPolicy; member in android::PointerControllerTest 197 mPolicy = new MockPointerControllerPolicyInterface(); in PointerControllerTest() 202 mPointerController = std::make_unique<TestPointerController>(mRegisteredListener, mPolicy, in PointerControllerTest() 265 ASSERT_TRUE(mPolicy->noResourcesAreLoaded()); in TEST_F() 269 ASSERT_TRUE(mPolicy->allResourcesAreLoaded()); in TEST_F() 318 EXPECT_TRUE(mPolicy->noResourcesAreLoaded()); in TEST_F() 372 PointerController::create(mPolicy, mLooper, *mSpriteController, GetParam()); in TEST_P()
|
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/net/ |
D | NetworkCycleDataLoaderTest.java | 66 private NetworkPolicy mPolicy; field in NetworkCycleDataLoaderTest 79 when(mPolicy.cycleIterator()).thenReturn(mIterator); in setUp() 96 ReflectionHelpers.setField(mLoader, "mPolicy", mPolicy); in loadInBackground_hasNetworkPolicy_shouldLoadPolicyData() 129 ReflectionHelpers.setField(mLoader, "mPolicy", mPolicy); in loadPolicyData_shouldRecordUsageFromPolicyCycle()
|
/frameworks/base/services/core/java/com/android/server/power/ |
D | Notifier.java | 130 private final WindowManagerPolicy mPolicy; field in Notifier 204 mPolicy = policy; in Notifier() 440 mPolicy.showDismissibleKeyguard(); in showDismissibleKeyguard() 555 mHandler.post(() -> mPolicy.startedWakingUp(groupId, changeReason)); in handleEarlyInteractiveChange() 557 mHandler.post(() -> mPolicy.startedGoingToSleep(groupId, changeReason)); in handleEarlyInteractiveChange() 572 mPolicy.startedWakingUpGlobal(mGlobalInteractivity.changeReason); in handleEarlyGlobalInteractiveChange() 583 mPolicy.startedGoingToSleepGlobal(mGlobalInteractivity.changeReason); in handleEarlyGlobalInteractiveChange() 610 mPolicy.finishedWakingUpGlobal(mGlobalInteractivity.changeReason); in handleLateGlobalInteractiveChange() 639 mPolicy.finishedGoingToSleepGlobal(mGlobalInteractivity.changeReason); in handleLateGlobalInteractiveChange() 664 mHandler.post(() -> mPolicy.finishedWakingUp(groupId, changeReason)); in handleLateInteractiveChange() [all …]
|
/frameworks/av/media/module/libmediatranscoding/ |
D | TranscodingResourcePolicy.cpp | 76 TranscodingResourcePolicyCookie(TranscodingResourcePolicy* policy) : mPolicy(policy) {} in TranscodingResourcePolicyCookie() 78 TranscodingResourcePolicy* mPolicy; member in android::TranscodingResourcePolicyCookie 90 auto policy = reinterpret_cast<TranscodingResourcePolicy*>(it->second->mPolicy); in BinderDiedCallback()
|
/frameworks/av/media/utils/include/mediautils/ |
D | SharedMemoryAllocator.h | 224 : mAllocator(allocator), mPolicy(std::move(policy)) {} 233 if (!mPolicy.isValid(request)) { 238 mPolicy.allocated(val); 244 mPolicy.deallocated(allocation); 252 mPolicy.deallocated_all(); 268 [[no_unique_address]] Policy mPolicy;
|
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/draganddrop/ |
D | DragLayout.java | 81 private final DragAndDropPolicy mPolicy; field in DragLayout 112 mPolicy = new DragAndDropPolicy(context, splitScreenController); in DragLayout() 267 mPolicy.start(session, loggerSessionId); in prepare() 374 final ArrayList<DragAndDropPolicy.Target> targets = mPolicy.getTargets(mInsets); in recomputeDropTargets() 392 DragAndDropPolicy.Target target = mPolicy.getTargetAtLocation( in update() 400 if (mPolicy.getNumTargets() == 1) { in update() 465 mPolicy.handleDrop(mCurrentTarget); in drop()
|
/frameworks/native/services/inputflinger/ |
D | InputFilterCallbacks.cpp | 82 : mNextListener(listener), mPolicy(policy) {} in InputFilterCallbacks() 94 mPolicy.notifyStickyModifierStateChanged(modifierState, lockedModifierState); in onModifierStateChanged()
|