Loading core/java/android/provider/Settings.java +24 −0 Original line number Diff line number Diff line Loading @@ -1355,6 +1355,30 @@ public final class Settings { */ public static final String RECENT_APPS_NUMBER = "recent_apps_number"; /** * bcrook - Double Carrier * Toggles whether to display the PLMN field on the Lockscreen */ public static final String SHOW_PLMN_LS = "show_plmn_ls"; /** * bcrook - Double Carrier * Toggles whether to display the SPN field on the Lockscreen */ public static final String SHOW_SPN_LS = "show_spn_ls"; /** * bcrook - Double Carrier * Toggles whether to display the PLMN field on the Notification bar */ public static final String SHOW_PLMN_SB = "show_plmn_sb"; /** * bcrook - Double Carrier * Toggles whether to display the SPN field on the Notification bar */ public static final String SHOW_SPN_SB = "show_spn_sb"; /** * Wysie_Soh * Specifies whether to show or hide clock Loading services/java/com/android/server/status/StatusBarService.java +16 −3 Original line number Diff line number Diff line Loading @@ -90,6 +90,10 @@ public class StatusBarService extends IStatusBar.Stub static final String TAG = "StatusBar"; static final boolean SPEW = false; //Double carrier private boolean mShowPlmnSb; private boolean mShowSpnSb; static final int EXPANDED_LEAVE_ALONE = -10000; static final int EXPANDED_FULL_OPEN = -10001; Loading Loading @@ -1785,12 +1789,16 @@ public class StatusBarService extends IStatusBar.Stub }; void updateNetworkName(boolean showSpn, String spn, boolean showPlmn, String plmn) { // Double carrier mShowPlmnSb = (Settings.System.getInt(mContext.getContentResolver(), Settings.System.SHOW_PLMN_SB, 0) == 1); mShowSpnSb = (Settings.System.getInt(mContext.getContentResolver(), Settings.System.SHOW_SPN_SB, 0) == 1); if (false) { Log.d(TAG, "updateNetworkName showSpn=" + showSpn + " spn=" + spn + " showPlmn=" + showPlmn + " plmn=" + plmn); + " ShowPlmn=" + showPlmn + " plmn=" + plmn); } boolean something = false; if (showPlmn) { // Double carrier - bcrook if (showPlmn && mShowPlmnSb) { mPlmnLabel.setVisibility(View.VISIBLE); if (plmn != null) { mPlmnLabel.setText(plmn); Loading @@ -1801,7 +1809,11 @@ public class StatusBarService extends IStatusBar.Stub mPlmnLabel.setText(""); mPlmnLabel.setVisibility(View.GONE); } if (showSpn && spn != null) { // Double carrier - bcrook, refinements from Wysie if (showSpn && spn != null && mShowSpnSb) { mSpnLabel.setText(spn); mSpnLabel.setVisibility(View.VISIBLE); something = true; Loading @@ -1809,6 +1821,7 @@ public class StatusBarService extends IStatusBar.Stub mSpnLabel.setText(""); mSpnLabel.setVisibility(View.GONE); } } /** Loading Loading
core/java/android/provider/Settings.java +24 −0 Original line number Diff line number Diff line Loading @@ -1355,6 +1355,30 @@ public final class Settings { */ public static final String RECENT_APPS_NUMBER = "recent_apps_number"; /** * bcrook - Double Carrier * Toggles whether to display the PLMN field on the Lockscreen */ public static final String SHOW_PLMN_LS = "show_plmn_ls"; /** * bcrook - Double Carrier * Toggles whether to display the SPN field on the Lockscreen */ public static final String SHOW_SPN_LS = "show_spn_ls"; /** * bcrook - Double Carrier * Toggles whether to display the PLMN field on the Notification bar */ public static final String SHOW_PLMN_SB = "show_plmn_sb"; /** * bcrook - Double Carrier * Toggles whether to display the SPN field on the Notification bar */ public static final String SHOW_SPN_SB = "show_spn_sb"; /** * Wysie_Soh * Specifies whether to show or hide clock Loading
services/java/com/android/server/status/StatusBarService.java +16 −3 Original line number Diff line number Diff line Loading @@ -90,6 +90,10 @@ public class StatusBarService extends IStatusBar.Stub static final String TAG = "StatusBar"; static final boolean SPEW = false; //Double carrier private boolean mShowPlmnSb; private boolean mShowSpnSb; static final int EXPANDED_LEAVE_ALONE = -10000; static final int EXPANDED_FULL_OPEN = -10001; Loading Loading @@ -1785,12 +1789,16 @@ public class StatusBarService extends IStatusBar.Stub }; void updateNetworkName(boolean showSpn, String spn, boolean showPlmn, String plmn) { // Double carrier mShowPlmnSb = (Settings.System.getInt(mContext.getContentResolver(), Settings.System.SHOW_PLMN_SB, 0) == 1); mShowSpnSb = (Settings.System.getInt(mContext.getContentResolver(), Settings.System.SHOW_SPN_SB, 0) == 1); if (false) { Log.d(TAG, "updateNetworkName showSpn=" + showSpn + " spn=" + spn + " showPlmn=" + showPlmn + " plmn=" + plmn); + " ShowPlmn=" + showPlmn + " plmn=" + plmn); } boolean something = false; if (showPlmn) { // Double carrier - bcrook if (showPlmn && mShowPlmnSb) { mPlmnLabel.setVisibility(View.VISIBLE); if (plmn != null) { mPlmnLabel.setText(plmn); Loading @@ -1801,7 +1809,11 @@ public class StatusBarService extends IStatusBar.Stub mPlmnLabel.setText(""); mPlmnLabel.setVisibility(View.GONE); } if (showSpn && spn != null) { // Double carrier - bcrook, refinements from Wysie if (showSpn && spn != null && mShowSpnSb) { mSpnLabel.setText(spn); mSpnLabel.setVisibility(View.VISIBLE); something = true; Loading @@ -1809,6 +1821,7 @@ public class StatusBarService extends IStatusBar.Stub mSpnLabel.setText(""); mSpnLabel.setVisibility(View.GONE); } } /** Loading