Home
last modified time | relevance | path

Searched refs:mAppRow (Results 1 – 25 of 38) sorted by relevance

12

/packages/apps/Settings/src/com/android/settings/notification/app/
DBlockPreferenceController.java56 if (mAppRow == null) { in isAvailable()
96 bar.setChecked(!mAppRow.banned in updateState()
99 bar.setChecked(!mAppRow.banned && !mChannelGroup.isBlocked()); in updateState()
101 bar.setChecked(!mAppRow.banned); in updateState()
123 if (mBackend.onlyHasDefaultChannel(mAppRow.pkg, mAppRow.uid)) { in onCheckedChanged()
124 if (mAppRow.banned != blocked) { in onCheckedChanged()
125 mAppRow.banned = blocked; in onCheckedChanged()
126 mBackend.setNotificationsEnabledForPackage(mAppRow.pkg, mAppRow.uid, !blocked); in onCheckedChanged()
131 mBackend.updateChannelGroup(mAppRow.pkg, mAppRow.uid, mChannelGroup); in onCheckedChanged()
132 } else if (mAppRow != null) { in onCheckedChanged()
[all …]
DNotificationPreferenceController.java53 protected NotificationBackend.AppRow mAppRow; field in NotificationPreferenceController
85 if (mAppRow == null) { in isAvailable()
88 if (mAppRow.banned) { in isAvailable()
111 mAppRow = appRow; in onResume()
136 if (mChannel != null && mAppRow != null) { in saveChannel()
137 mBackend.updateChannel(mAppRow.pkg, mAppRow.uid, mChannel); in saveChannel()
152 if (channel != null && mAppRow != null) { in isChannelBlockable()
153 boolean locked = mAppRow.lockedImportance; in isChannelBlockable()
158 return channel.isBlockable() || !mAppRow.systemApp in isChannelBlockable()
171 if (mAppRow != null) { in isAppBlockable()
[all …]
DBadgePreferenceController.java54 if (mAppRow == null && mChannel == null) { in isAvailable()
65 return mAppRow == null in isAvailable()
67 : mAppRow.channelCount == 0 in isAvailable()
69 : mAppRow.showBadge; in isAvailable()
72 if (mAppRow.channelCount == 0) { in isAvailable()
84 if (mAppRow != null) { in updateState()
91 pref.setChecked(mAppRow.showBadge); in updateState()
102 } else if (mAppRow != null){ in onPreferenceChange()
103 mAppRow.showBadge = showBadge; in onPreferenceChange()
104 mBackend.setShowBadge(mAppRow.pkg, mAppRow.uid, showBadge); in onPreferenceChange()
DBubblePreferenceController.java77 return mAppRow != null && mAppRow.bubblePreference != BUBBLE_PREFERENCE_NONE; in isAvailable()
90 if (mIsAppPage && mAppRow != null) { in updateState()
91 mHasSentInvalidMsg = mBackend.isInInvalidMsgState(mAppRow.pkg, mAppRow.uid); in updateState()
93 mAppRow.pkg, mAppRow.uid).getList().size(); in updateState()
95 int backEndPref = mAppRow.bubblePreference; in updateState()
121 if (mAppRow != null && mFragmentManager != null) { in onPreferenceChange()
128 .setPkgPrefInfo(mAppRow.pkg, mAppRow.uid, value) in onPreferenceChange()
132 mAppRow.bubblePreference = value; in onPreferenceChange()
133 mBackend.setAllowBubbles(mAppRow.pkg, mAppRow.uid, value); in onPreferenceChange()
DInvalidConversationPreferenceController.java44 if (mAppRow == null) { in isAvailable()
47 if (mAppRow.banned) { in isAvailable()
53 return mBackend.isInInvalidMsgState(mAppRow.pkg, mAppRow.uid); in isAvailable()
63 if (mAppRow == null) { in updateState()
69 pref.setChecked(!mBackend.hasUserDemotedInvalidMsgApp(mAppRow.pkg, mAppRow.uid)); in updateState()
75 if (mAppRow == null) { in onPreferenceChange()
78 mBackend.setInvalidMsgAppDemoted(mAppRow.pkg, mAppRow.uid, !((Boolean) newValue)); in onPreferenceChange()
DAppConversationListPreferenceController.java62 if (mAppRow == null) { in isAvailable()
65 if (mAppRow.banned) { in isAvailable()
69 if (mBackend.onlyHasDefaultChannel(mAppRow.pkg, mAppRow.uid) in isAvailable()
74 return mBackend.hasSentValidMsg(mAppRow.pkg, mAppRow.uid) || mBackend.isInInvalidMsgState( in isAvailable()
75 mAppRow.pkg, mAppRow.uid); in isAvailable()
90 if (mAppRow == null) { in loadConversationsAndPopulate()
98 mBackend.getConversations(mAppRow.pkg, mAppRow.uid); in loadConversationsAndPopulate()
163 pref.setIcon(mBackend.getConversationDrawable(mContext, si, mAppRow.pkg, mAppRow.uid, in populateConversationPreference()
169 channelArgs.putInt(AppInfoBase.ARG_PACKAGE_UID, mAppRow.uid); in populateConversationPreference()
170 channelArgs.putString(AppInfoBase.ARG_PACKAGE_NAME, mAppRow.pkg); in populateConversationPreference()
DBubbleSummaryPreferenceController.java48 if (mAppRow == null) { in isAvailable()
58 return mAppRow != null; in isAvailable()
61 return isGloballyEnabled() && mBackend.hasSentValidBubble(mAppRow.pkg, mAppRow.uid); in isAvailable()
78 if (mAppRow != null) { in updateState()
81 intent.putExtra(Settings.EXTRA_APP_PACKAGE, mAppRow.pkg); in updateState()
82 intent.putExtra(Settings.EXTRA_APP_UID, mAppRow.uid); in updateState()
89 if (mAppRow == null) { in getSummary()
92 int backEndPref = mAppRow.bubblePreference; in getSummary()
DAppChannelsBypassingDndPreferenceController.java86 mAllNotificationsToggle.setEnabled(!mAppRow.banned in displayPreference()
98 mBackend.updateChannel(mAppRow.pkg, mAppRow.uid, channel); in displayPreference()
123 return mAppRow != null; in isAvailable()
133 if (mAppRow != null) { in updateState()
144 List<NotificationChannelGroup> mChannelGroupList = mBackend.getGroups(mAppRow.pkg, in loadAppChannels()
145 mAppRow.uid).getList(); in loadAppChannels()
212 mBackend.updateChannel(mAppRow.pkg, mAppRow.uid, channel); in populateList()
219 channelArgs.putInt(AppInfoBase.ARG_PACKAGE_UID, mAppRow.uid); in populateList()
220 channelArgs.putString(AppInfoBase.ARG_PACKAGE_NAME, mAppRow.pkg); in populateList()
227 .setUserHandle(UserHandle.of(mAppRow.userId)) in populateList()
[all …]
DInvalidConversationInfoPreferenceController.java43 if (mAppRow == null) { in isAvailable()
46 if (mAppRow.banned) { in isAvailable()
52 return mBackend.isInInvalidMsgState(mAppRow.pkg, mAppRow.uid); in isAvailable()
62 if (mAppRow == null) { in updateState()
66 R.string.convo_not_supported_summary, mAppRow.label)); in updateState()
DChannelListPreferenceController.java75 if (mAppRow == null) { in isAvailable()
78 if (mAppRow.banned) { in isAvailable()
82 if (mBackend.onlyHasDefaultChannel(mAppRow.pkg, mAppRow.uid) in isAvailable()
104 mChannelGroupList = mBackend.getGroups(mAppRow.pkg, mAppRow.uid).getList(); in updateState()
106 mChannelGroupList = mBackend.getGroupsWithRecentBlockedFilter(mAppRow.pkg, in updateState()
107 mAppRow.uid).getList(); in updateState()
110 mChannelGroupList = mBackend.getGroups(mAppRow.pkg, mAppRow.uid).getList(); in updateState()
334 mBackend.updateChannelGroup(mAppRow.pkg, mAppRow.uid, group); in addOrUpdateGroupToggle()
361 mContext, mAppRow.sentByChannel.get(channel.getId()), false)); in updateSingleChannelPrefs()
364 channelArgs.putInt(AppInfoBase.ARG_PACKAGE_UID, mAppRow.uid); in updateSingleChannelPrefs()
[all …]
DHeaderPreferenceController.java58 return mAppRow != null; in isAvailable()
68 if (mAppRow != null && mFragment != null) { in updateState()
83 pref = mHeaderController.setIcon(mAppRow.icon) in updateState()
87 .setPackageName(mAppRow.pkg) in updateState()
88 .setUid(mAppRow.uid) in updateState()
102 return mAppRow.label; in getLabel()
118 summary.append(bidi.unicodeWrap(mAppRow.label)); in getSummary()
124 return mAppRow.label.toString(); in getSummary()
DNotificationSettings.java80 protected NotificationBackend.AppRow mAppRow; field in NotificationSettings
154 controller.onResume(mAppRow, mChannel, mChannelGroup, null, null, in onAttach()
188 if (mUid < 0 || TextUtils.isEmpty(mPkg) || mPkgInfo == null || mAppRow == null) { in onResume()
197 if (mAppRow == null) { in onResume()
284 mContext, mConversationInfo, mAppRow.pkg, mAppRow.uid, in loadConversation()
290 mAppRow = mBackend.loadAppRow(mContext, mPm, mPkgInfo); in loadAppRow()
294 mShowLegacyChannelConfig = mBackend.onlyHasDefaultChannel(mAppRow.pkg, mAppRow.uid) in loadChannelGroup()
300 mAppRow.pkg, mAppRow.uid, NotificationChannel.DEFAULT_CHANNEL_ID, null); in loadChannelGroup()
318 .setPackage(mAppRow.pkg); in collectConfigActivities()
329 if (mAppRow.settingsIntent != null) { in collectConfigActivities()
[all …]
DConversationHeaderPreferenceController.java59 return mAppRow != null; in isAvailable()
69 if (mAppRow != null && mFragment != null) { in updateState()
87 .setPackageName(mAppRow.pkg) in updateState()
88 .setUid(mAppRow.uid) in updateState()
106 summary.append(bidi.unicodeWrap(mAppRow.label.toString())); in getSummary()
112 return mAppRow.label.toString(); in getSummary()
115 return mAppRow.label.toString(); in getSummary()
DDeletedChannelsPreferenceController.java52 return mBackend.getDeletedChannelCount(mAppRow.pkg, mAppRow.uid) > 0; in isAvailable()
61 if (mAppRow != null) { in updateState()
62 int deletedChannelCount = mBackend.getDeletedChannelCount(mAppRow.pkg, mAppRow.uid); in updateState()
DAppLinkPreferenceController.java48 return mAppRow.settingsIntent != null; in isAvailable()
57 if (mAppRow != null) { in updateState()
58 preference.setIntent(mAppRow.settingsIntent); in updateState()
DBubbleLinkPreferenceController.java57 if (mAppRow != null) { in updateState()
60 intent.putExtra(Settings.EXTRA_APP_PACKAGE, mAppRow.pkg); in updateState()
61 intent.putExtra(Settings.EXTRA_APP_UID, mAppRow.uid); in updateState()
DBubbleCategoryPreferenceController.java57 if (mAppRow != null) { in updateState()
60 intent.putExtra(Settings.EXTRA_APP_PACKAGE, mAppRow.pkg); in updateState()
61 intent.putExtra(Settings.EXTRA_APP_UID, mAppRow.uid); in updateState()
DNotificationsOffPreferenceController.java43 if (mAppRow == null) { in isAvailable()
60 if (mAppRow != null) { in updateState()
65 } else if (mAppRow.permissionStateLocked) { in updateState()
DVisibilityPreferenceController.java65 if (mChannel == null || mAppRow.banned) { in isAvailable()
77 if (mChannel != null && mAppRow != null) { in updateState()
140 mContext, keyguardNotificationFeatures, mAppRow.userId); in setRestrictedIfNotificationFeaturesDisabled()
DConversationPriorityPreferenceController.java51 if (mAppRow == null || mChannel == null) { in isAvailable()
64 if (mAppRow != null) { in updateState()
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/app/
DAppConversationListPreferenceControllerTest.java65 private NotificationBackend.AppRow mAppRow; field in AppConversationListPreferenceControllerTest
75 mAppRow = new NotificationBackend.AppRow(); in setUp()
76 mAppRow.uid = 42; in setUp()
77 mAppRow.pkg = "com.example.exampling"; in setUp()
80 mController.onResume(mAppRow, null, null, null, null, null, new ArrayList<>()); in setUp()
90 when(mBackend.getConversations(eq(mAppRow.pkg), eq(mAppRow.uid))).thenReturn( in updateState_someConversations_loadsConversations()
110 when(mBackend.getConversations(eq(mAppRow.pkg), eq(mAppRow.uid))) in updateState_someConversations_loadsNotDemotedOnly()
127 when(mBackend.getConversations(eq(mAppRow.pkg), eq(mAppRow.uid))) in updateState_noConversations_hides()
140 when(mBackend.getConversations(eq(mAppRow.pkg), eq(mAppRow.uid))) in updateState_refreshes()
149 when(mBackend.getConversations(eq(mAppRow.pkg), eq(mAppRow.uid))) in updateState_refreshes()
[all …]
DAppChannelsBypassingDndPreferenceControllerTest.java67 private NotificationBackend.AppRow mAppRow; field in AppChannelsBypassingDndPreferenceControllerTest
80 mAppRow = new NotificationBackend.AppRow(); in setUp()
81 mAppRow.uid = 42; in setUp()
82 mAppRow.pkg = "com.example.exampling"; in setUp()
85 mController.onResume(mAppRow, null, null, null, null, null, new ArrayList<>()); in setUp()
96 when(mBackend.getGroups(eq(mAppRow.pkg), eq(mAppRow.uid))).thenReturn( in displayPreference_showsAllAndChannels()
113 when(mBackend.getGroups(eq(mAppRow.pkg), eq(mAppRow.uid))).thenReturn( in displayPreference_canToggleAllInterrupt()
125 when(mBackend.getGroups(eq(mAppRow.pkg), eq(mAppRow.uid))).thenReturn( in displayPreference_canToggleInterruptIfChannelEnabled()
142 mAppRow.banned = true; in displayPreference_appBlocked_cannotToggleAllOrChannelInterrupts()
143 when(mBackend.getGroups(eq(mAppRow.pkg), eq(mAppRow.uid))).thenReturn( in displayPreference_appBlocked_cannotToggleAllOrChannelInterrupts()
[all …]
DBubbleSummaryPreferenceControllerTest.java74 NotificationBackend.AppRow mAppRow; field in BubbleSummaryPreferenceControllerTest
84 mAppRow = new NotificationBackend.AppRow(); in setUp()
85 mAppRow.pkg = "pkg"; in setUp()
86 mAppRow.uid = 0; in setUp()
108 mController.onResume(mAppRow, null, null, null, null, null, null); in isAvailable_NOTIFICATION_BUBBLESisOn_shouldReturnTrue()
116 mController.onResume(mAppRow, null, null, null, null, null, null); in isAvailable_NOTIFICATION_BUBBLESisOn_neverSentBubble_shouldReturnFalse()
126 mController.onResume(mAppRow, null, null, null, null, null, null); in isAvailable_NOTIFICATION_BUBBLESisOff_shouldReturnFalse()
137 mController.onResume(mAppRow, channel, null, null, null, null, null); in isAvailable_nonNullChannelNOTIFICATION_BUBBLESisOff_shouldReturnFalse()
148 mController.onResume(mAppRow, channel, null, null, null, null, null); in isAvailable_defaultChannelNOTIFICATION_BUBBLESisOn_shouldReturnTrue()
156 mController.onResume(mAppRow, null, null, null, null, null, null); in isAvailable_lowRam_shouldReturnFalse()
[all …]
/packages/apps/Settings/src/com/android/settings/notification/
DAppBubbleListPreferenceController.java86 if (mAppRow == null) { in isAvailable()
89 if (mAppRow.banned) { in isAvailable()
93 if (mBackend.onlyHasDefaultChannel(mAppRow.pkg, mAppRow.uid) in isAvailable()
98 if (mAppRow.bubblePreference == BUBBLE_PREFERENCE_NONE) { in isAvailable()
111 if (mAppRow.bubblePreference == BUBBLE_PREFERENCE_SELECTED) { in filterAndSortConversations()
113 } else if (mAppRow.bubblePreference == BUBBLE_PREFERENCE_ALL) { in filterAndSortConversations()
124 return mAppRow.bubblePreference == BUBBLE_PREFERENCE_SELECTED
134 pref.setOnClickBubblesConversation(mAppRow.bubblePreference == BUBBLE_PREFERENCE_ALL);
137 mBackend.updateChannel(mAppRow.pkg, mAppRow.uid, conversation.getNotificationChannel());
/packages/apps/Settings/tests/unit/src/com/android/settings/notification/app/
DChannelListPreferenceControllerTest.java60 private NotificationBackend.AppRow mAppRow; field in ChannelListPreferenceControllerTest
72 mAppRow = mBackend.loadAppRow(mContext, in setUp()
75 mController.onResume(mAppRow, null, null, null, null, null, null); in setUp()
348 mAppRow.sentByChannel.put("channelA", sentA); in testUpdateFullList_channelUpdates()
375 mAppRow.sentByChannel.remove("channelA"); in testUpdateFullList_channelUpdates()
376 mAppRow.sentByChannel.put("channelB", sentB); in testUpdateFullList_channelUpdates()

12