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

Commit 5dc47f9a authored by Steve Kondik's avatar Steve Kondik
Browse files

Revert "SystemUI: Fix no emergency call button on lock screen"

This reverts commit 2ce7d20b.

Revert "Keyguard: Replace "Emergency" to "Emergency call""

This reverts commit e9b89c11.

Change-Id: I4438d76de8589037eb47775131ed786d8090d25a
parent 552d81e3
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -34,7 +34,4 @@

    <!-- config for showing AM/PM on lock screen in 12hour format -->
    <bool name="config_showAmpm">true</bool>

    <!-- whether to show emergency button in lock screen -->
    <bool name="config_showEmergencyButton">true</bool>
</resources>
+0 −1
Original line number Diff line number Diff line
@@ -399,5 +399,4 @@ number">%d</xliff:g> remaining attempt before SIM becomes permanently unusable.
number">%d</xliff:g> remaining attempts before SIM becomes permanently unusable. Contact carrier for details.</item>
    </plurals>

    <string name="button_lockscreen_emergency_call">Emergency call</string>
</resources>
+1 −18
Original line number Diff line number Diff line
@@ -75,10 +75,6 @@ public class EmergencyButton extends Button {

    private final boolean mIsVoiceCapable;
    private final boolean mEnableEmergencyCallWhileSimLocked;
    private final boolean mIsCarrierSupported = isCarrierOneSupported();

    public static final String PROPERTY_RADIO_ATEL_CARRIER = "persist.radio.atel.carrier";
    public static final String CARRIER_ONE_DEFAULT_MCC_MNC = "405854";

    public EmergencyButton(Context context) {
        this(context, null);
@@ -174,14 +170,9 @@ public class EmergencyButton extends Button {
            int textId;
            if (isInCall()) {
                textId = com.android.internal.R.string.lockscreen_return_to_call;
            } else {
                if (mIsCarrierSupported) {
                    // Text "Emergency call"
                    textId = R.string.button_lockscreen_emergency_call;
            } else {
                textId = com.android.internal.R.string.lockscreen_emergency_call;
            }
            }
            setText(textId);
        } else {
            setVisibility(View.GONE);
@@ -209,12 +200,4 @@ public class EmergencyButton extends Button {
    private TelecomManager getTelecommManager() {
        return (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
    }

    /**
     * Check is carrier one supported or not
     */
    public static boolean isCarrierOneSupported() {
        String property = SystemProperties.get(PROPERTY_RADIO_ATEL_CARRIER);
        return CARRIER_ONE_DEFAULT_MCC_MNC.equals(property);
    }
}
+0 −4
Original line number Diff line number Diff line
@@ -843,10 +843,6 @@ public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickL
            } else {
                label = mContext.getString(R.string.phone_hint);

    private void updateEmergencyButton() {
        if(mContext.getResources().getBoolean(R.bool.config_showEmergencyButton)){
            if (mEmergencyButton != null) {
                mEmergencyButton.updateEmergencyCallButton();
            }
        }
        return label;