Skip to content
This repository has been archived by the owner on Nov 8, 2023. It is now read-only.

Commit

Permalink
Remove remaining references to COMBINED_STATUS_BAR_SIGNAL_FLAGS
Browse files Browse the repository at this point in the history
The previous CL removes all implementationso f the provider model
combined iconography + call strength policy from the signal controllers.
This CL removes the remaining handful of references fo the flag which
could change some of our layouts.

Test: atest SystemUITests
Test: manual
Bug: 238873748
Change-Id: If36675acbea5c2f1f250fd526a0877e2a59fb3f3
  • Loading branch information
Evan Laird committed Jul 29, 2022
1 parent 9273f91 commit 36928c0
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 29 deletions.
3 changes: 0 additions & 3 deletions packages/SystemUI/src/com/android/systemui/flags/Flags.java
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,6 @@ public class Flags {

/***************************************/
// 600- status bar
public static final BooleanFlag COMBINED_STATUS_BAR_SIGNAL_ICONS =
new BooleanFlag(601, false);

public static final ResourceBooleanFlag STATUS_BAR_USER_SWITCHER =
new ResourceBooleanFlag(602, R.bool.flag_user_switcher_chip);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -264,14 +264,8 @@ class LargeScreenShadeHeaderController @Inject constructor(
Utils.getColorAttrDefaultColor(header.context, android.R.attr.textColorPrimary)
)

carrierIconSlots = if (featureFlags.isEnabled(Flags.COMBINED_STATUS_BAR_SIGNAL_ICONS)) {
listOf(
header.context.getString(com.android.internal.R.string.status_bar_no_calling),
header.context.getString(com.android.internal.R.string.status_bar_call_strength)
)
} else {
carrierIconSlots =
listOf(header.context.getString(com.android.internal.R.string.status_bar_mobile))
}
qsCarrierGroupController = qsCarrierGroupControllerBuilder
.setQSCarrierGroup(qsCarrierGroup)
.build()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,21 +61,19 @@ public class StatusBarMobileView extends FrameLayout implements DarkReceiver,
private int mVisibleState = -1;
private DualToneHandler mDualToneHandler;
private boolean mForceHidden;
private boolean mProviderModel;

/**
* Designated constructor
*/
public static StatusBarMobileView fromContext(
Context context,
String slot,
boolean providerModel
String slot
) {
LayoutInflater inflater = LayoutInflater.from(context);
StatusBarMobileView v = (StatusBarMobileView)
inflater.inflate(R.layout.status_bar_mobile_signal_group, null);
v.setSlot(slot);
v.init(providerModel);
v.init();
v.setVisibleState(STATE_ICON);
return v;
}
Expand Down Expand Up @@ -108,17 +106,12 @@ public void getDrawingRect(Rect outRect) {
outRect.bottom += translationY;
}

private void init(boolean providerModel) {
mProviderModel = providerModel;
private void init() {
mDualToneHandler = new DualToneHandler(getContext());
mMobileGroup = findViewById(R.id.mobile_group);
mMobile = findViewById(R.id.mobile_signal);
mMobileType = findViewById(R.id.mobile_type);
if (mProviderModel) {
mMobileRoaming = findViewById(R.id.mobile_roaming_large);
} else {
mMobileRoaming = findViewById(R.id.mobile_roaming);
}
mMobileRoaming = findViewById(R.id.mobile_roaming);
mMobileRoamingSpace = findViewById(R.id.mobile_roaming_space);
mIn = findViewById(R.id.mobile_in);
mOut = findViewById(R.id.mobile_out);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
import com.android.systemui.R;
import com.android.systemui.demomode.DemoMode;
import com.android.systemui.flags.FeatureFlags;
import com.android.systemui.flags.Flags;
import com.android.systemui.plugins.DarkIconDispatcher;
import com.android.systemui.plugins.DarkIconDispatcher.DarkReceiver;
import com.android.systemui.statusbar.StatusBarIconView;
Expand Down Expand Up @@ -255,9 +254,7 @@ public void updateWifiState(WifiIconState state) {

public void addMobileView(MobileIconState state) {
Log.d(TAG, "addMobileView: ");
StatusBarMobileView view = StatusBarMobileView.fromContext(
mContext, state.slot,
mFeatureFlags.isEnabled(Flags.COMBINED_STATUS_BAR_SIGNAL_ICONS));
StatusBarMobileView view = StatusBarMobileView.fromContext(mContext, state.slot);

view.applyMobileState(state);
view.setStaticDrawableColor(mColor);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
import com.android.systemui.dagger.SysUISingleton;
import com.android.systemui.demomode.DemoModeCommandReceiver;
import com.android.systemui.flags.FeatureFlags;
import com.android.systemui.flags.Flags;
import com.android.systemui.plugins.DarkIconDispatcher;
import com.android.systemui.plugins.DarkIconDispatcher.DarkReceiver;
import com.android.systemui.statusbar.StatusBarIconView;
Expand Down Expand Up @@ -361,9 +360,7 @@ private StatusBarWifiView onCreateStatusBarWifiView(String slot) {
}

private StatusBarMobileView onCreateStatusBarMobileView(String slot) {
StatusBarMobileView view = StatusBarMobileView.fromContext(
mContext, slot,
mFeatureFlags.isEnabled(Flags.COMBINED_STATUS_BAR_SIGNAL_ICONS));
StatusBarMobileView view = StatusBarMobileView.fromContext(mContext, slot);
return view;
}

Expand Down

0 comments on commit 36928c0

Please sign in to comment.