Commit Graph

30 Commits

Author SHA1 Message Date
tmfang
db00a3177a Refactor add network page
WifiDialog.java can be launched as "full screen mode"
in some use cases. However the way it's done is that
it uses theme to fake the full screen appearance.
It just feels hacky to use a dialog for full screen UI.
So, we created an "AddNetworkFragment" to make this
page can look like a normal fragment.

Also, clean up some useless code about "full screen mode"
of WifiDialog.

Change-Id: Iedd04c6a8e403cbceb872313314e1cba0d514246
Fixes: 111875856
Test: robo test, manual test
2018-08-18 00:16:14 +08:00
tmfang
9d4a806f28 Settings crashes on opening Wi-Fi Add network
Since Theme_Settings_NoActionBar extends from Theme.DeviceDefault.Settings,
so it carshed when AppCompatDelegateImpl tried to get AppCompat theme from WifiDialog.

Test: visual inspection, robo
Change-Id: I751b771fdfa9ad2261baa5a06274f6bb0a70d677
Fixes: 111804691
2018-07-27 13:49:29 +08:00
tmfang
41ab6b4bf8 Migrate all AlertDialogs to AndroidX version
This CL only changed AlertDialog imports.
So, reviewer can review it easily.

Change-Id: I097bc44394195b14287f4f920c570ac8653f356a
Fixes: 111413092
Test: This CL can't pass Robo test.
2018-07-20 11:32:13 +08:00
Fan Zhang
2ff710a911 Move logic from SavedAccessPoint fragment to controller
Change-Id: Ic54e536f97490cec1746fa58c42ec55b60d17f0e
Fixes: 64806699
Test: robotests
2018-07-19 14:49:14 -07:00
Pavel Grafov
d429225640 Block editing of locked down wifi network from details page.
Test: make ROBOTEST_FILTER=WifiDetailPreferenceControllerTest RunSettingsRoboTests
Bug: 68990370
Change-Id: Idceb064486afd93bc8b2f52d605a788520de8e56
2017-11-17 18:11:25 +00:00
Eric Schwarzenbach
5a7e46dd80 Add modify button to WifiNetworkDetailsFragment.
Adds pencil icon to Wifi Detail action bar to modify the network.
Modifies package/public visibility to allow the detail package to
use the WifiDialog. Listens for changes in WifiConfigurations to
propagate changes to the UI in WifiNetworkDetailsFragment.

Changes WifiNetworkDetail preference launch to conform to pattern
of other Settings apps. Removes unused WifiDetailActionBarObserver.

Bug: 36483704, 37082355
Test: make -j40 RunSettingsRoboTests
Change-Id: Ie9dc1892eaefdfad4a6bd7040bfc5dbf6236cfb4
2017-09-08 13:39:22 -07:00
Eric Schwarzenbach
bc1cf7e260 Make only the "Add Network" WifiDialog fullscreen.
Fixes an issue where other instances of WifiDialog were being launched
fullscreen. Creates static methods for creating fullscreen and modal
WifiDialogs to make the style more explicit.

Bug: 63889135
Test: make -j40 RunSettingsRoboTests
Change-Id: I2200b5d7f817b9f69a6abb73bf2c04ea24556d19
2017-07-26 17:04:42 -07:00
Eric Schwarzenbach
c86f5bbd00 Make "Add Network" dialog fullscreen.
Bug: 35324632
Test: manual

Change-Id: Ideac214eb97d774878ee772daca2b7efceba95b4
2017-07-17 08:56:57 -07:00
Sudheer Shanka
e2b2c3ffe4 Add more policy transparency for wifi settings.
Show policy transparency dialog if user tries to modify a
wifi configuration locked by device owner.

Bug: 27375948
Change-Id: I504082282f57bc5de9f097e962d195ecd2cc9da4
2016-03-17 15:35:15 -07:00
Jason Monk
39b467482d Depend on support lib preferences
Bug: 24576551
Change-Id: Ic6190bacd3f7582c9bbc8de972da4612bd92421e
2015-10-13 10:12:20 -04:00
Maurice Lam
771fac591f [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
2015-09-17 16:03:49 -07:00
Maurice Lam
2662df8433 [WifiSettings] Submit Wi-Fi dialog with enter key
Add a OnKeyListener for hardware keyboards and an
OnEditorActionListener for on-screen IMEs to submit the Wi-Fi dialog
with the currently entered information.

Before committing the action, check for whether the dialog is
submittable -- that is checking whether all necessary information has
been entered. If not the enter key behaves the same as it is before
the change.

Bug: 22211604
Change-Id: Idede4233a7385d3bcd8fd6614948270280536bf1
2015-09-14 12:07:06 -07:00
Sanket Padawe
3bf0db8d10 Fix issues in AP dialog arising after clicking on AP preferences.
+Added a new flag to keep track if user wanted to modify AP by hard
pressing on AP.

Bug: 22485686
Change-Id: Ia60a564a5344393f5e5340a3493ae7c660ead3d7
2015-07-24 13:52:03 -07:00
Zoltan Szatmary-Ban
89403529ad Show dialog when user tries to edit a locked down WiFi config
Also, 'FORGET' button is not shown on WifiDialogs of locked down configs.
Context menu only shows 'Connect' for them.

Bug: 20117316
Change-Id: I3fa986c10b6ff47d1a897794213c225c8c6f579b
2015-04-20 16:04:15 +01:00
Prerepa Viswanadham
77eb8880e8 Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release' into master_merge
Fix build in DevelopmentSettings.java

Change-Id: I8d89fd46482fae8e708398f749e480b8a06f5f03
2015-03-24 19:08:43 -07:00
Sanket Padawe
3eb3b104d7 Restore password visibility on screen rotation in Hotspot/Wifi setup.
Bug: 16237425
Change-Id: I2bf0aaaa657d60f007858c6635d2a17326562c66
2015-03-20 10:07:50 -07:00
Jason Monk
fc1b00cfe4 Move some wifi tracking code to SettingsLib
Move tracking of which networks are available/saved and their state
over to SettingsLib to share it with Quick Settings.

Bug: 19180466
Change-Id: Iaeef06b26da8cb38e1ba09a7d105d04d499dc181
2015-02-04 20:40:32 +00:00
PauloftheWest
a7383f3862 Removed connect button from Saved Networks dialog.
Bug: 17065357
Change-Id: Idb46ac404b171733ccac271ba74188224ca2611d
2014-09-08 16:06:04 -07:00
Russell Brenner
e8a80b5db3 Support Holo Light theme for wifi during setup
Adds programmatic support for holo light theme, activated by setting
EXTRA_THEME to "holo_light". Light-themed graphics are still pending.

Bug: 10407819
Change-Id: I81b6bf3fdf7ca3ee72b0f921b8adf6d858415887
2013-08-28 09:44:36 -07:00
Irfan Sheriff
0c0bd827a1 Fix button visibility on connect
Bug: 5750846
Change-Id: I1f31308a21f7f6876f12eb4f1ab45ecd1bc74092
2011-12-13 11:55:15 -08:00
Amith Yamasani
25b69ebccc Use a resizable dialog for wifi configuration.
Bug: 3175152

Use a custom theme that allows the dialog to resize.

Change-Id: I004b91c58d0d1810df50f9bdee9430698f51f8ab
2011-01-07 15:31:35 -08:00
Daisuke Miyakawa
58b0291fe6 Refactor WiFi code around XL setup
Major:
- move SetupWizard-related codes to WifiSettingsForSetupWizardXL as
  much as possible
- stop using Preference for configurinig wifi network. We use
  WifiConfigUiForSetupWizardXL instead, which is base on a bare View.

Minor:
- change button handling code expecting better readability.
- hide Detail button.
- modify strings a bit.
- add logs

Bug: 3175016
Change-Id: I5b29917af73aac6a82e13ba846a9d5085f9bd523
2010-11-10 15:31:10 -08:00
Daisuke Miyakawa
5cd60eb8aa Add modifications which should have been in the change
I520d690d3301837d32f91dad54a973a379ce1989

Change-Id: Iecca6b4fef2ec42a62273035b096ccedcea94d78
2010-09-01 19:38:23 -07:00
Daisuke Miyakawa
d36699282c Add Wifi Setup screen for Setup Wizard with XL size screen.
* Add WifiSettingsForSetupWizardXL as a new Activity
The activity has WifiSettings fragment in it. It also contains
several buttons, texts around the fragment.

* Making configuration UI part of Preference list.
In Wifi Setup for Setup Wizard XL, WifiSettings fragment lets
a UI for configuring access points shown inside a
PregerenceCategory object, while it has been shown as Dialog.

To achieve this action, WifiDialog is decomposed into two parts:
- WifiConfigUiBase (Mainly UI part)
- WifiConfigController (Mainly Wifi controller part)

All codes for wifi configuration in WifiDialog is now in
WifiConfigController, which is reused from
WifiConfigPreference.

* Misc stuff
- Remove AccessPoint#compareTo(). Instead,
  AccessPoint.AccessPointComparater should be used when needed.

Change-Id: I520d690d3301837d32f91dad54a973a379ce1989
2010-09-01 16:17:51 -07:00
Irfan Sheriff
de3e56650d Add phase2 authentication settings
Bug: 2734813
Change-Id: Iaf4455577be888f6c78f490b2cc046adef41403e
2010-06-02 16:31:20 -07:00
Chung-yih Wang
8c81257f70 Fix the double-quoted SSID issue.
Bug id http://b/issue?id=2684571

Change-Id: I0f1e508b9a3d0fefcef28235380392368a51e42a
2010-05-15 10:57:23 +08:00
Chung-yih Wang
141fe818f1 Fix the incorrect keystore prefix of private key in the wpa_supplicant.conf.
Change-Id: Ibc77d10f6c945d274037422b2e4e58d1bbd9888d
2010-03-23 12:17:20 +08:00
Chia-chi Yeh
05d35416e8 WifiSettings: do not set auth_alg for WPA/WPA2 networks.
Change-Id: Ib41a52d90ca8db3cb52aa1fb87e2433bb76f4de2
2010-03-17 15:52:54 +08:00
Dmitry Shmidt
c11618c826 Fix WEP Open/Shared network settings
Change-Id: I2ccf73e19d27ed5c60f3f028a44a241ed6a7bb50
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2010-03-16 12:47:33 -07:00
Chia-chi Yeh
48090d4066 WifiSettings: revise and add support for editing EAP networks.
Use arrays.xml to store translations for enumerations;
avoid race conditions happened when pop up menu or dialog;
avoid saving configurations with networks disabled;
use the same layout for all the dialogs;
support editing EAP networks;
only unlock keystore before connecting;
and many bug fixes I cannot remember.

The number of lines in the new code is about 1/3 of the old one,
and it improves the readability a lot!
2010-02-02 18:31:58 +08:00