Loading src/com/android/settings/wifi/details2/WifiDetailPreferenceController2.java +7 −23 Original line number Diff line number Diff line Loading @@ -631,21 +631,23 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle } private void refreshMacAddress() { String macAddress = mWifiEntry.getMacAddress(); if (macAddress == null) { final String macAddress = mWifiEntry.getMacAddress(); if (TextUtils.isEmpty(macAddress)) { mMacAddressPref.setVisible(false); return; } mMacAddressPref.setVisible(true); mMacAddressPref.setTitle((mWifiEntry.getPrivacy() == WifiEntry.PRIVACY_RANDOMIZED_MAC) ? R.string.wifi_advanced_randomized_mac_address_title : R.string.wifi_advanced_device_mac_address_title); if (macAddress.equals(WifiInfo.DEFAULT_MAC_ADDRESS)) { mMacAddressPref.setSummary(R.string.device_info_not_available); } else { mMacAddressPref.setSummary(macAddress); } // MAC Address Pref Title refreshMacTitle(); } private void updatePreference(Preference pref, String detailText) { Loading Loading @@ -930,24 +932,6 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle } } private void refreshMacTitle() { if (!mWifiEntry.isSaved()) { return; } // For saved Passpoint network, framework doesn't have the field to keep the MAC choice // persistently, so Passpoint network will always use the default value so far, which is // randomized MAC address, so don't need to modify title. if (mWifiEntry.isSubscription()) { return; } mMacAddressPref.setTitle( (mWifiEntry.getPrivacy() == WifiEntry.PRIVACY_RANDOMIZED_MAC) ? R.string.wifi_advanced_randomized_mac_address_title : R.string.wifi_advanced_device_mac_address_title); } /** * Indicates the state of the WifiEntry has changed and clients may retrieve updates through * the WifiEntry getter methods. Loading Loading
src/com/android/settings/wifi/details2/WifiDetailPreferenceController2.java +7 −23 Original line number Diff line number Diff line Loading @@ -631,21 +631,23 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle } private void refreshMacAddress() { String macAddress = mWifiEntry.getMacAddress(); if (macAddress == null) { final String macAddress = mWifiEntry.getMacAddress(); if (TextUtils.isEmpty(macAddress)) { mMacAddressPref.setVisible(false); return; } mMacAddressPref.setVisible(true); mMacAddressPref.setTitle((mWifiEntry.getPrivacy() == WifiEntry.PRIVACY_RANDOMIZED_MAC) ? R.string.wifi_advanced_randomized_mac_address_title : R.string.wifi_advanced_device_mac_address_title); if (macAddress.equals(WifiInfo.DEFAULT_MAC_ADDRESS)) { mMacAddressPref.setSummary(R.string.device_info_not_available); } else { mMacAddressPref.setSummary(macAddress); } // MAC Address Pref Title refreshMacTitle(); } private void updatePreference(Preference pref, String detailText) { Loading Loading @@ -930,24 +932,6 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle } } private void refreshMacTitle() { if (!mWifiEntry.isSaved()) { return; } // For saved Passpoint network, framework doesn't have the field to keep the MAC choice // persistently, so Passpoint network will always use the default value so far, which is // randomized MAC address, so don't need to modify title. if (mWifiEntry.isSubscription()) { return; } mMacAddressPref.setTitle( (mWifiEntry.getPrivacy() == WifiEntry.PRIVACY_RANDOMIZED_MAC) ? R.string.wifi_advanced_randomized_mac_address_title : R.string.wifi_advanced_device_mac_address_title); } /** * Indicates the state of the WifiEntry has changed and clients may retrieve updates through * the WifiEntry getter methods. Loading