Problem:
On the Wifi Settings screen, if instead of clicking on the AP shown on the scanned list, we do an "Add Wi-Fi network" and enter the AP information - the AP information gets stored and the client device connects to the AP. Afterwards, if we click on the AP again the "Forget" button does not appear until we exit the Wifi Settings screen and return.
Root cause and Fix:
mApScanList in WifiLayer tracks the list of APs shown. Upon doing a connect through a direct click, the configured state for the AP in the list updated. However, if we do an Add Network, the configured state on mApScanList remains unupdated. This causes the Settings screen to not show "Forget" for the AP when it is clicked.
The fix is to set the Configured state to true in handleSave() by fetching the AP state stored in WifiLayer.
Bug: 2296038
Change-id: I70c545905a4984a03a0f235f3baf17cd36688710
Merge commit 'c538b651a23287ab25584995c6c4b7a68ece027c'
* commit 'c538b651a23287ab25584995c6c4b7a68ece027c':
Fix some UI flow issues when the keystore is locked in WiFi setting.
Merge commit 'b2295174dcb27efa0bf2fb58bb31a517413d9c86'
* commit 'b2295174dcb27efa0bf2fb58bb31a517413d9c86':
Add the missing phase2 field in EAP configuration.
Merge commit 'c4a3bf94cc870d940df37756ed2c5ea7067d00da'
* commit 'c4a3bf94cc870d940df37756ed2c5ea7067d00da':
Add header 'blob://' in front of the cert/key names in wpa_supplicant.conf.
Merge commit 'eb7836f11ec4e9753db7c6ecd9414e153bb7bdbe'
* commit 'eb7836f11ec4e9753db7c6ecd9414e153bb7bdbe':
Apply the new keystore and certtool library in Wifi setting.
1. Certificate related APIs were moved to CertTool. Therefore,
we have to migrate to CertTool instead.
2. Unlock the keystore if it is not unlocked yet(send the intent
out to credential storage) for EAP access points.
3. Add Password field for WPA_EAP and IEEE8021X(this is for
phase 2 auth.)
Merge commit '150d5d84e8913e93402950a84ff991b7549b71b4'
* commit '150d5d84e8913e93402950a84ff991b7549b71b4':
Use the keystore service instead of the direct file access.
Merge commit 'e7e587daf65ec39ca2b10e5c6a03f6bb0b4ccce0'
* commit 'e7e587daf65ec39ca2b10e5c6a03f6bb0b4ccce0':
Revert "Use the keystore service instead of the direct file acess."
Merge commit 'e97bfa3c2581bc59eceaaf043b7059dc29307884'
* commit 'e97bfa3c2581bc59eceaaf043b7059dc29307884':
Fix the bug of missing EAP setting in wpa_supplicant.conf when a new EAP is configured.
Merge commit '289705f3311932a45adef1710358f5e302115013'
* commit '289705f3311932a45adef1710358f5e302115013':
Use the keystore service instead of the direct file acess.
1. Remove the isEnterprise() filter in Scanresult.
2. This requires the new fields such as identity, eap, certificate/key
to support EAP authentication in Wifi Settings.
3. Add simple file-based keystore to select the cert/key from UI.
-- Updated from the comments.
-- Fix the bug for passing null pointer for adding spinner items.