Merge changes I984e796a,I4af61a72 into tm-qpr-dev

* changes:
  Fix muteOnReturn behavior for snoozed notifications
  Allow secondary summaries to wrap in entity header
This commit is contained in:
Julia Reynolds
2022-07-21 10:56:49 +00:00
committed by Android (Google) Code Review
2 changed files with 4 additions and 2 deletions

View File

@@ -71,6 +71,8 @@
<TextView <TextView
android:id="@+id/entity_header_second_summary" android:id="@+id/entity_header_second_summary"
style="@style/TextAppearance.EntityHeaderSummary" style="@style/TextAppearance.EntityHeaderSummary"
android:singleLine="false"
android:maxLines="4"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content"/> android:layout_height="wrap_content"/>

View File

@@ -2459,11 +2459,11 @@ public class NotificationManagerService extends SystemService {
SnoozeHelper snoozeHelper = new SnoozeHelper(getContext(), (userId, r, muteOnReturn) -> { SnoozeHelper snoozeHelper = new SnoozeHelper(getContext(), (userId, r, muteOnReturn) -> {
try { try {
if (DBG) { if (DBG) {
Slog.d(TAG, "Reposting " + r.getKey()); Slog.d(TAG, "Reposting " + r.getKey() + " " + muteOnReturn);
} }
enqueueNotificationInternal(r.getSbn().getPackageName(), r.getSbn().getOpPkg(), enqueueNotificationInternal(r.getSbn().getPackageName(), r.getSbn().getOpPkg(),
r.getSbn().getUid(), r.getSbn().getInitialPid(), r.getSbn().getTag(), r.getSbn().getUid(), r.getSbn().getInitialPid(), r.getSbn().getTag(),
r.getSbn().getId(), r.getSbn().getNotification(), userId, true); r.getSbn().getId(), r.getSbn().getNotification(), userId, muteOnReturn);
} catch (Exception e) { } catch (Exception e) {
Slog.e(TAG, "Cannot un-snooze notification", e); Slog.e(TAG, "Cannot un-snooze notification", e);
} }