Add missing conversation field

NotificationChannel#EDIT_CONVERSATION should show
both 'demote conversation' and 'promote conversation'
fields.

Test: View Partial and Full Settings for promoted and
demoted channels
Fixes: 273508155

Change-Id: I4a17a73d695d7c79837fc647b79968f535fa4393
This commit is contained in:
Julia Reynolds
2023-03-16 17:29:55 -04:00
parent 8126e93ff2
commit 5164149efc
2 changed files with 8 additions and 0 deletions

View File

@@ -96,4 +96,11 @@
android:summary="@string/demote_conversation_summary" android:summary="@string/demote_conversation_summary"
settings:allowDividerAbove="true"/> settings:allowDividerAbove="true"/>
<!-- only used in ChannelPanelActivity -->
<Preference
android:key="convo_promote"
android:icon="@drawable/ic_promote_conversation"
android:title="@string/promote_conversation_title"
android:summary="@string/promote_conversation_summary" />
</PreferenceScreen> </PreferenceScreen>

View File

@@ -99,6 +99,7 @@ public class ConversationNotificationSettings extends NotificationSettings {
mControllers.add(new BubblePreferenceController(context, getChildFragmentManager(), mControllers.add(new BubblePreferenceController(context, getChildFragmentManager(),
mBackend, false /* isAppPage */, null /* dependentFieldListener */)); mBackend, false /* isAppPage */, null /* dependentFieldListener */));
mControllers.add(new ConversationDemotePreferenceController(context, this, mBackend)); mControllers.add(new ConversationDemotePreferenceController(context, this, mBackend));
mControllers.add(new ConversationPromotePreferenceController(context, this, mBackend));
mControllers.add(new BubbleCategoryPreferenceController(context)); mControllers.add(new BubbleCategoryPreferenceController(context));
mControllers.add(new BubbleLinkPreferenceController(context)); mControllers.add(new BubbleLinkPreferenceController(context));
return new ArrayList<>(mControllers); return new ArrayList<>(mControllers);