[WifiSettings] Add Wi-Fi dialog activity

Add a Wi-Fi dialog activity that can be started by setup wizard to
connect to a Wi-Fi access point.

Also refactored mEdit and mModify in WifiConfigController into an
int-enum mMode, with modes view, connect and modify. This is how the
new modes maps to the old flags:

MODE_VIEW     --  mEdit = false, mModify = *
MODE_CONNECT  --  mEdit = true, mModify = false
MODE_MODIFY   --  mEdit = true, mModify = true

Bug: 23426311
Change-Id: I8e2221fd3c42577068e07686dab245dd5888e0ae
This commit is contained in:
Maurice Lam
2015-09-08 10:36:43 -07:00
parent 2662df8433
commit 771fac591f
8 changed files with 187 additions and 53 deletions

View File

@@ -146,7 +146,7 @@ public class SavedAccessPointsWifiSettings extends SettingsPreferenceFragment
final boolean hideForgetButton = WifiSettings.isEditabilityLockedDown(getActivity(),
mDlgAccessPoint.getConfig());
mDialog = new WifiDialog(getActivity(), this, mDlgAccessPoint,
false /* not editting */, false, true /* hide the submit button */,
WifiConfigUiBase.MODE_VIEW, true /* hide the submit button */,
hideForgetButton);
return mDialog;