[Wi-Fi] Fix Wi-Fi wrong password notification can't launch editor
WifiPickerTracker gather WifiEntries at onStart but WifiPickerTracker.getWifiEntries() may still have no WifiEntry at onResume. Check if there is a specified wrong password Wi-Fi network at onWifiEntriesChanged. Bug: 143328194 Test: manual Edit a Wi-Fi network with wrong password, click the wrong password notification, should see a Wi-Fi editor for the wrong password Wi-Fi network Change-Id: I7de6e0e3eabb2cb00160709eca4951b655dc04d7
This commit is contained in:
@@ -227,7 +227,12 @@ public class WifiSettings extends RestrictedSettingsFragment
|
||||
super.onCreate(icicle);
|
||||
|
||||
if (FeatureFlagUtils.isEnabled(getContext(), FeatureFlagUtils.SETTINGS_WIFITRACKER2)) {
|
||||
getContext().startActivity(new Intent("android.settings.WIFI_SETTINGS2"));
|
||||
final Intent intent = new Intent("android.settings.WIFI_SETTINGS2");
|
||||
final Bundle extras = getActivity().getIntent().getExtras();
|
||||
if (extras != null) {
|
||||
intent.putExtras(extras);
|
||||
}
|
||||
getContext().startActivity(intent);
|
||||
finish();
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user