Home
last modified time | relevance | path

Searched refs:mBackend (Results 1 – 25 of 163) sorted by relevance

1234567

/aosp12/packages/apps/Settings/src/com/android/settings/notification/app/
H A DAppNotificationSettings.java84 mControllers.add(new BadgePreferenceController(context, mBackend)); in createPreferenceControllers()
86 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
88 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
90 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
92 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
94 mDependentFieldListener, mBackend)); in createPreferenceControllers()
95 mControllers.add(new LightsPreferenceController(context, mBackend)); in createPreferenceControllers()
96 mControllers.add(new VibrationPreferenceController(context, mBackend)); in createPreferenceControllers()
98 mBackend)); in createPreferenceControllers()
99 mControllers.add(new DndPreferenceController(context, mBackend)); in createPreferenceControllers()
[all …]
H A DChannelNotificationSettings.java121 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
123 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
125 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
127 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
129 mDependentFieldListener, mBackend)); in createPreferenceControllers()
130 mControllers.add(new VibrationPreferenceController(context, mBackend)); in createPreferenceControllers()
133 mBackend)); in createPreferenceControllers()
134 mControllers.add(new LightsPreferenceController(context, mBackend)); in createPreferenceControllers()
135 mControllers.add(new BadgePreferenceController(context, mBackend)); in createPreferenceControllers()
136 mControllers.add(new DndPreferenceController(context, mBackend)); in createPreferenceControllers()
[all …]
H A DConversationNotificationSettings.java86 context, mBackend, mDependentFieldListener)); in createPreferenceControllers()
88 context, mDependentFieldListener, mBackend)); in createPreferenceControllers()
90 mDependentFieldListener, mBackend)); in createPreferenceControllers()
91 mControllers.add(new VibrationPreferenceController(context, mBackend)); in createPreferenceControllers()
93 mBackend)); in createPreferenceControllers()
94 mControllers.add(new LightsPreferenceController(context, mBackend)); in createPreferenceControllers()
95 mControllers.add(new BadgePreferenceController(context, mBackend)); in createPreferenceControllers()
98 mBackend, false /* isAppPage */, null /* dependentFieldListener */)); in createPreferenceControllers()
99 mControllers.add(new ConversationDemotePreferenceController(context, this, mBackend)); in createPreferenceControllers()
H A DConversationListSettings.java37 NotificationBackend mBackend = new NotificationBackend(); field in ConversationListSettings
65 mControllers.add(new NoConversationsPreferenceController(context, mBackend, mPs)); in createPreferenceControllers()
66 mControllers.add(new PriorityConversationsPreferenceController(context, mBackend)); in createPreferenceControllers()
67 mControllers.add(new AllConversationsPreferenceController(context, mBackend)); in createPreferenceControllers()
68 mControllers.add(new RecentConversationsPreferenceController(context, mBackend, mPs)); in createPreferenceControllers()
/aosp12/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/zen/
H A DZenModeVisEffectPreferenceControllerTest.java61 private ZenModeBackend mBackend; field in ZenModeVisEffectPreferenceControllerTest
87 ReflectionHelpers.setField(mController, "mBackend", mBackend); in setup()
137 ReflectionHelpers.setField(mController, "mBackend", mBackend); in updateState_checkedFalse_parentChecked()
139 when(mBackend.isVisualEffectSuppressed(PARENT_EFFECT1)).thenReturn(false); in updateState_checkedFalse_parentChecked()
140 when(mBackend.isVisualEffectSuppressed(PARENT_EFFECT2)).thenReturn(true); in updateState_checkedFalse_parentChecked()
153 ReflectionHelpers.setField(mController, "mBackend", mBackend); in updateState_checkedFalse_parentNotChecked()
155 when(mBackend.isVisualEffectSuppressed(PARENT_EFFECT1)).thenReturn(false); in updateState_checkedFalse_parentNotChecked()
156 when(mBackend.isVisualEffectSuppressed(PARENT_EFFECT2)).thenReturn(false); in updateState_checkedFalse_parentNotChecked()
161 verify(mBackend, never()).saveVisualEffectsPolicy(SUPPRESSED_EFFECT_PEEK, true); in updateState_checkedFalse_parentNotChecked()
168 verify(mBackend).saveVisualEffectsPolicy(SUPPRESSED_EFFECT_PEEK, false); in onPreferenceChanged_checkedFalse()
[all …]
H A DZenModeVisEffectsCustomPreferenceControllerTest.java60 private ZenModeBackend mBackend; field in ZenModeVisEffectsCustomPreferenceControllerTest
82 ReflectionHelpers.setField(mController, "mBackend", mBackend); in setup()
90 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0); in isAvailable_noVisEffects()
96 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 1); in isAvailable_visEffects()
102 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0); in updateState_notChecked_noVisEffects()
119 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed); in updateState_notChecked_allVisEffects()
127 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2); in updateState_checked()
135 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2); in updateState_listeners()
H A DZenFooterPreferenceControllerTest.java61 private ZenModeBackend mBackend; field in ZenFooterPreferenceControllerTest
82 ReflectionHelpers.setField(mController, "mBackend", mBackend); in setup()
89 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0); in isAvailable_noVisEffects()
95 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2); in isAvailable_someVisEffects()
110 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed); in isAvailable_allVisEffects()
116 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0); in updateSummary_noVisEffects()
123 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2); in getSummary_someVisEffects()
139 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed); in getSummary_allVisEffects()
H A DZenModeRepeatCallersPreferenceControllerTest.java58 private ZenModeBackend mBackend; field in ZenModeRepeatCallersPreferenceControllerTest
82 ReflectionHelpers.setField(mController, "mBackend", mBackend); in setup()
113 when(mBackend.isPriorityCategoryEnabled( in updateState_Priority()
126 when(mBackend.isPriorityCategoryEnabled(NotificationManager.Policy.PRIORITY_CATEGORY_CALLS)) in updateState_Priority_anyCallers()
128 when(mBackend.getPriorityCallSenders()).thenReturn( in updateState_Priority_anyCallers()
130 when(mBackend.isPriorityCategoryEnabled( in updateState_Priority_anyCallers()
145 verify(mBackend) in onPreferenceChanged_EnableRepeatCallers()
155 verify(mBackend) in onPreferenceChanged_DisableRepeatCallers()
H A DZenModeAddBypassingAppsPreferenceControllerTest.java56 private NotificationBackend mBackend; field in ZenModeAddBypassingAppsPreferenceControllerTest
70 mContext, null, mock(Fragment.class), mBackend); in setup()
90 when(mBackend.getNotificationChannelsBypassingDnd( in testUpdateAppList()
95 when(mBackend.getChannelCount( in testUpdateAppList()
104 when(mBackend.getChannelCount( in testUpdateAppList()
108 when(mBackend.getNotificationChannelsBypassingDnd( in testUpdateAppList()
118 when(mBackend.getChannelCount( in testUpdateAppList()
122 when(mBackend.getNotificationChannelsBypassingDnd( in testUpdateAppList()
/aosp12/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/
H A DNotificationAssistantPreferenceControllerTest.java67 private NotificationBackend mBackend; field in NotificationAssistantPreferenceControllerTest
83 mPreferenceController.setBackend(mBackend); in setUp()
94 when(mBackend.getAllowedNotificationAssistant()).thenReturn(null); in testIsChecked()
104 verify(mBackend, times(0)).setNotificationAssistantGranted(any()); in testSetChecked()
108 verify(mBackend, times(1)).setNotificationAssistantGranted(null); in testSetChecked()
121 verify(mBackend, times(1)) in testMigrationFromSetting_userEnable_multiProfile()
123 verify(mBackend, never()) in testMigrationFromSetting_userEnable_multiProfile()
137 verify(mBackend, times(1)) in testMigrationFromSetting_userEnable_multiUser()
139 verify(mBackend, never()) in testMigrationFromSetting_userEnable_multiUser()
153 verify(mBackend, times(1)) in testMigrationFromSetting_userDisable_multiProfile()
[all …]
H A DSilentStatusBarPreferenceControllerTest.java43 private NotificationBackend mBackend; field in SilentStatusBarPreferenceControllerTest
56 mController.setBackend(mBackend); in setUp()
64 when(mBackend.shouldHideSilentStatusBarIcons(any())).thenReturn(false); in isChecked_settingIsOff()
70 when(mBackend.shouldHideSilentStatusBarIcons(any())).thenReturn(true); in isChecked_settingIsOn()
77 verify(mBackend, times(1)).setHideSilentStatusIcons(false); in setChecked_Off()
83 verify(mBackend, times(1)).setHideSilentStatusIcons(true); in setChecked_On()
/aosp12/packages/apps/Settings/tests/robotests/src/com/android/settings/dream/
H A DWhenToDreamPickerTest.java45 private DreamBackend mBackend; field in WhenToDreamPickerTest
60 ReflectionHelpers.setField(mPicker, "mBackend", mBackend); in setup()
65 when(mBackend.getWhenToDreamSetting()).thenReturn(DreamBackend.WHILE_CHARGING); in getDefaultKeyReturnsCurrentWhenToDreamSetting()
69 when(mBackend.getWhenToDreamSetting()).thenReturn(DreamBackend.WHILE_DOCKED); in getDefaultKeyReturnsCurrentWhenToDreamSetting()
73 when(mBackend.getWhenToDreamSetting()).thenReturn(DreamBackend.EITHER); in getDefaultKeyReturnsCurrentWhenToDreamSetting()
77 when(mBackend.getWhenToDreamSetting()).thenReturn(DreamBackend.NEVER); in getDefaultKeyReturnsCurrentWhenToDreamSetting()
86 verify(mBackend).setWhenToDream(DreamBackend.WHILE_CHARGING); in setDreamWhileCharging()
93 verify(mBackend).setWhenToDream(DreamBackend.WHILE_DOCKED); in setDreamWhileDocked()
100 verify(mBackend).setWhenToDream(DreamBackend.EITHER); in setDreamWhileChargingOrDocked()
107 verify(mBackend).setWhenToDream(DreamBackend.NEVER); in setDreamNever()
H A DCurrentDreamPreferenceControllerTest.java50 private DreamBackend mBackend; field in CurrentDreamPreferenceControllerTest
61 ReflectionHelpers.setField(mController, "mBackend", mBackend); in setup()
66 when(mBackend.getDreamInfos()).thenReturn(new ArrayList<>(0)); in isDisabledIfNoDreamsAvailable()
73 when(mBackend.getDreamInfos()).thenReturn(Collections.singletonList(mDreamInfo)); in isEnabledIfDreamsAvailable()
83 when(mBackend.getDreamInfos()).thenReturn(Collections.singletonList(mDreamInfo)); in gearShowsIfActiveDreamInfoHasOptions()
100 when(mBackend.getDreamInfos()).thenReturn(Collections.singletonList(mDreamInfo)); in gearHidesIfActiveDreamInfoHasNoOptions()
/aosp12/packages/apps/StorageManager/src/com/android/storagemanager/deletionhelper/
H A DAppDeletionPreferenceGroup.java38 private AppDeletionType mBackend; field in AppDeletionPreferenceGroup
73 preference.setChecked(mBackend.isChecked(packageName)); in onAppRebuild()
91 return mBackend.getDeletionThreshold() == 0; in isNoThreshold()
107 if (mBackend == null) { in onPreferenceChange()
116 mBackend.setChecked(p.getPackageName(), isChecked); in onPreferenceChange()
127 mBackend.setChecked(p.getPackageName(), isChecked); in onPreferenceChange()
146 mBackend = type; in setDeletionType()
152 if (mBackend != null) { in updateText()
154 mBackend.getTotalAppsFreeableSpace(DeletionHelperSettings.COUNT_UNCHECKED); in updateText()
155 deletionThreshold = mBackend.getDeletionThreshold(); in updateText()
[all …]
/aosp12/packages/apps/TvSettings/Settings/src/com/android/tv/settings/device/display/daydream/
H A DDaydreamFragment.java74 private DreamBackend mBackend; field in DaydreamFragment
86 mBackend = new DreamBackend(getActivity()); in onCreate()
146 dreamNowPref.setEnabled(mBackend.isEnabled()); in onCreatePreferences()
207 if (!mBackend.isEnabled()) { in setActiveDream()
208 mBackend.setEnabled(true); in setActiveDream()
211 mBackend.setActiveDream(dreamInfo.componentName); in setActiveDream()
214 if (mBackend.isEnabled()) { in setActiveDream()
215 mBackend.setActiveDream(null); in setActiveDream()
216 mBackend.setEnabled(false); in setActiveDream()
235 mBackend.startDreaming(); in onPreferenceTreeClick()
[all …]
/aosp12/packages/apps/Settings/src/com/android/settings/dream/
H A DCurrentDreamPreferenceController.java34 private final DreamBackend mBackend; field in CurrentDreamPreferenceController
38 mBackend = DreamBackend.getInstance(context); in CurrentDreamPreferenceController()
43 return mBackend.getDreamInfos().size() > 0 ? AVAILABLE : CONDITIONALLY_UNAVAILABLE; in getAvailabilityStatus()
55 return mBackend.getActiveDreamName(); in getSummary()
75 mBackend.launchSettings(mContext, info.get()); in launchScreenSaverSettings()
79 return mBackend.getDreamInfos() in getActiveDreamInfo()
91 gearPref.setIcon(Utils.getSafeIcon(mBackend.getActiveIcon())); in setActiveDreamIcon()
H A DCurrentDreamPicker.java37 private DreamBackend mBackend; field in CurrentDreamPicker
43 mBackend = DreamBackend.getInstance(context); in onAttach()
60 mBackend.setActiveDream(componentNameMap.get(key)); in setDefaultKey()
68 return mBackend.getActiveDream().flattenToString(); in getDefaultKey()
74 candidates = mBackend.getDreamInfos().stream() in getCandidates()
90 mBackend.getDreamInfos() in getDreamComponentsMap()
/aosp12/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/app/
H A DInvalidConversationPreferenceControllerTest.java66 private NotificationBackend mBackend; field in InvalidConversationPreferenceControllerTest
83 mController = spy(new InvalidConversationPreferenceController(mContext, mBackend)); in setUp()
100 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_notIfAppBlocked()
111 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(false); in testIsAvailable_notIfInValidMsgState()
121 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable()
131 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_filteredIn()
142 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_filteredOut()
183 when(mBackend.hasUserDemotedInvalidMsgApp(anyString(), anyInt())).thenReturn(true); in testUpdateState_checked()
196 when(mBackend.hasUserDemotedInvalidMsgApp(anyString(), anyInt())).thenReturn(true); in testOnPreferenceChange_toggleEnabled()
206 verify(mBackend, times(1)).setInvalidMsgAppDemoted(any(), anyInt(), eq(false)); in testOnPreferenceChange_toggleEnabled()
[all …]
H A DInvalidConversationInfoPreferenceControllerTest.java60 private NotificationBackend mBackend; field in InvalidConversationInfoPreferenceControllerTest
77 mController = spy(new InvalidConversationInfoPreferenceController(mContext, mBackend)); in setUp()
93 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_notIfAppBlocked()
104 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(false); in testIsAvailable_notIfInValidMsgState()
114 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable()
124 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_filteredIn()
135 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testIsAvailable_filteredOut()
145 when(mBackend.isInInvalidMsgState(anyString(), anyInt())).thenReturn(true); in testUpdateState()
/aosp12/packages/apps/Settings/src/com/android/settings/notification/
H A DSilentStatusBarPreferenceController.java29 private NotificationBackend mBackend; field in SilentStatusBarPreferenceController
33 mBackend = new NotificationBackend(); in SilentStatusBarPreferenceController()
38 mBackend = backend; in setBackend()
43 return mBackend.shouldHideSilentStatusBarIcons(mContext); in isChecked()
48 mBackend.setHideSilentStatusIcons(isChecked); in setChecked()
H A DConversationListSummaryPreferenceController.java26 private NotificationBackend mBackend; field in ConversationListSummaryPreferenceController
30 mBackend = new NotificationBackend(); in ConversationListSummaryPreferenceController()
40 final int count = mBackend.getConversations(true).getList().size(); in getSummary()
50 mBackend = backend; in setBackend()
/aosp12/packages/apps/Settings/src/com/android/settings/notification/zen/
H A DZenModeRepeatCallersPreferenceController.java37 private final ZenModeBackend mBackend; field in ZenModeRepeatCallersPreferenceController
45 mBackend = ZenModeBackend.getInstance(context); in ZenModeRepeatCallersPreferenceController()
76 boolean anyCallersCanBypassDnd = (mBackend.isPriorityCategoryEnabled( in updateState()
78 && mBackend.getPriorityCallSenders() == Policy.PRIORITY_SENDERS_ANY); in updateState()
85 pref.setChecked(mBackend.isPriorityCategoryEnabled( in updateState()
99 mBackend.saveSoundPolicy(Policy.PRIORITY_CATEGORY_REPEAT_CALLERS, allowRepeatCallers); in onPreferenceChange()
H A DZenModePeoplePreferenceController.java66 preference.setSummary(mBackend.getAlarmsTotalSilencePeopleSummary( in updateState()
76 final int callersAllowed = mBackend.getPriorityCallSenders(); in getPeopleSummary()
77 final int messagesAllowed = mBackend.getPriorityMessageSenders(); in getPeopleSummary()
78 final int conversationsAllowed = mBackend.getPriorityConversationSenders(); in getPeopleSummary()
80 mBackend.isPriorityCategoryEnabled(PRIORITY_CATEGORY_REPEAT_CALLERS); in getPeopleSummary()
/aosp12/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/
H A DBatteryOptimizationPreferenceControllerTest.java58 private TestPowerAllowlistBackend mBackend; field in BatteryOptimizationPreferenceControllerTest
69 doReturn(false).when(mBackend).isAllowlisted(PKG_NOT_IN_ALLOWLIST); in setUp()
70 doReturn(true).when(mBackend).isAllowlisted(PKG_IN_ALLOWLIST); in setUp()
74 PKG_NOT_IN_ALLOWLIST, mBackend)); in setUp()
101 PKG_IN_ALLOWLIST, mBackend); in testUpdateState_appInAllowlist_showSummaryNotOptimized()
119 verify(mBackend).refreshList(); in testUpdateState_refreshList()
/aosp12/packages/apps/Settings/src/com/android/settings/fuelgauge/
H A DBatteryOptimizationPreferenceController.java41 private PowerAllowlistBackend mBackend; field in BatteryOptimizationPreferenceController
52 mBackend = PowerAllowlistBackend.getInstance(mSettingsActivity); in BatteryOptimizationPreferenceController()
62 mBackend = backend; in BatteryOptimizationPreferenceController()
72 mBackend.refreshList(); in updateState()
73 final boolean isAllowlisted = mBackend.isAllowlisted(mPackageName); in updateState()

1234567