Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c7c04b92 authored by Julia Reynolds's avatar Julia Reynolds
Browse files

Remove feature flag for evenly divided call style buttons

This feature is fully launched and should no longer be gated behind a flag.

Test: TH
Flag: EXEMPT flag cleanup
Fixes: 409610747
Change-Id: I0e2e2ce8694ff65cc53ec412520ad759980f3412
parent 36f40836
Loading
Loading
Loading
Loading
+7 −14
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package android.app;
import static android.annotation.Dimension.DP;
import static android.app.Flags.FLAG_NM_SUMMARIZATION;
import static android.app.Flags.evenlyDividedCallStyleActionLayout;
import static android.app.Flags.notificationsRedesignTemplates;
import static android.app.admin.DevicePolicyResources.Drawables.Source.NOTIFICATION;
import static android.app.admin.DevicePolicyResources.Drawables.Style.SOLID_COLORED;
@@ -6672,13 +6671,11 @@ public class Notification implements Parcelable
                    contentView.setInt(R.id.actions, "setCollapsibleIndentDimen",
                            R.dimen.call_notification_collapsible_indent);
                }
                if (evenlyDividedCallStyleActionLayout()) {
                if (CallStyle.DEBUG_NEW_ACTION_LAYOUT) {
                    Log.d(TAG, "setting evenly divided mode on action list");
                }
                contentView.setBoolean(R.id.actions, "setEvenlyDividedMode", true);
            }
            }
            if (!notificationsRedesignTemplates()) {
                contentView.setBoolean(R.id.actions, "setEmphasizedMode", emphasizedMode);
            }
@@ -7280,7 +7277,7 @@ public class Notification implements Parcelable
                final CharSequence label = ensureColorSpanContrastOrStripStyling(title, p);
                if (p.mCallStyleActions && evenlyDividedCallStyleActionLayout()) {
                if (p.mCallStyleActions) {
                    if (CallStyle.DEBUG_NEW_ACTION_LAYOUT) {
                        Log.d(TAG, "new action layout enabled, gluing instead of setting text");
                    }
@@ -7304,14 +7301,10 @@ public class Notification implements Parcelable
                button.setColorStateList(R.id.action0, "setButtonBackground",
                        ColorStateList.valueOf(buttonFillColor));
                if (p.mCallStyleActions) {
                    if (evenlyDividedCallStyleActionLayout()) {
                    if (CallStyle.DEBUG_NEW_ACTION_LAYOUT) {
                        Log.d(TAG, "new action layout enabled, gluing instead of setting icon");
                    }
                    button.setIcon(R.id.action0, "glueIcon", action.getIcon());
                    } else {
                        button.setImageViewIcon(R.id.action0, action.getIcon());
                    }
                    boolean priority = action.getExtras().getBoolean(CallStyle.KEY_ACTION_PRIORITY);
                    button.setBoolean(R.id.action0, "setIsPriority", priority);
                    int minWidthDimen =
+0 −10
Original line number Diff line number Diff line
@@ -175,16 +175,6 @@ flag {
  }
}

flag {
  name: "evenly_divided_call_style_action_layout"
  namespace: "systemui"
  description: "Evenly divides horizontal space for action buttons in CallStyle notifications."
  bug: "268733030"
  metadata {
    purpose: PURPOSE_BUGFIX
  }
}

flag {
  name: "sort_section_by_time"
  namespace: "systemui"
+0 −16
Original line number Diff line number Diff line
@@ -16,7 +16,6 @@

package com.android.internal.widget;

import static android.app.Flags.evenlyDividedCallStyleActionLayout;
import static android.app.Notification.CallStyle.DEBUG_NEW_ACTION_LAYOUT;
import static android.text.style.DynamicDrawableSpan.ALIGN_CENTER;

@@ -166,11 +165,6 @@ public class EmphasizedNotificationButton extends Button {
    }

    private void setIconToGlue(@Nullable Drawable icon) {
        if (!evenlyDividedCallStyleActionLayout()) {
            Log.e(TAG, "glueIcon: new action layout disabled; doing nothing");
            return;
        }

        if (icon != null) {
            prepareIcon(icon);
        }
@@ -209,11 +203,6 @@ public class EmphasizedNotificationButton extends Button {
    }

    private void setLabelToGlue(@Nullable CharSequence label) {
        if (!evenlyDividedCallStyleActionLayout()) {
            Log.e(TAG, "glueLabel: new action layout disabled; doing nothing");
            return;
        }

        mLabelToGlue = label;
        mGluePending = true;

@@ -250,11 +239,6 @@ public class EmphasizedNotificationButton extends Button {
            return;
        }

        if (!evenlyDividedCallStyleActionLayout()) {
            Log.e(TAG, "glueIconAndLabelIfNeeded: new action layout disabled; doing nothing");
            return;
        }

        // Not ready to glue yet:

        if (!isLayoutDirectionResolved()) {
+0 −7
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package com.android.internal.widget;

import static android.app.Flags.notificationsRedesignTemplates;
import static android.app.Notification.CallStyle.DEBUG_NEW_ACTION_LAYOUT;
import static android.app.Flags.evenlyDividedCallStyleActionLayout;

import android.annotation.DimenRes;
import android.app.Flags;
@@ -421,12 +420,6 @@ public class NotificationActionListLayout extends LinearLayout {
     */
    @RemotableViewMethod
    public void setEvenlyDividedMode(boolean evenlyDividedMode) {
        if (evenlyDividedMode && !evenlyDividedCallStyleActionLayout()) {
            Log.e(TAG, "setEvenlyDividedMode(true) called with new action layout disabled; "
                    + "leaving evenly divided mode disabled");
            return;
        }

        if (evenlyDividedMode == mEvenlyDividedMode) {
            return;
        }