This also fixes the issues related to explicit connection
to passpoint AP, and fixes occassional mention of
'connected via Wi-Fi Assistent'
Change-Id: I152cebafa6259194f1d09a6972a3508156335cb6
(cherry picked from commit 08b5b5d439)
Added setProgressBarVisible method to show the progress bar when the
UI is in a transient state (e.g. enabling / disabling Wi-Fi, scanning
for access points).
Bug: 19674909
Change-Id: I82180b7949a03f6ac468f069febf0ffd1f42f1b7
Also, 'FORGET' button is not shown on WifiDialogs of locked down configs.
Context menu only shows 'Connect' for them.
Bug: 20117316
Change-Id: I3fa986c10b6ff47d1a897794213c225c8c6f579b
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
This removes the grey Wi-Fi icon from the empty-view in the Wi-Fi
list of Setup Wizard. Also updated the style so it looks like the
description text in other setup screens.
Also fixed the view recycling by not calling getRootAdapter in
onActivityCreated, since that will cause the Preference framework
to not cache the AccessPoint preference.
Bug: 17575719
Bug: 16518752
Change-Id: I06cbc88db1c04b29a9ce8221596265effc39b90b
Show "Connected via Wi-Fi assistant" instead of just "Connected" when
a Wi-Fi connection is ephemeral. Otherwise, treat ephemeral
connections just like saved ones - show (read-only) connection stats
when you click the network, and offer the ability to "forget" the
network, which prevents further ephemeral connections.
Bug: 18525241
Change-Id: I0d2146ab47b82d32c50b2ef883f176a6b6066713
Per the latest mocks, advanced wireless settings will be the only
location in platform settings where Wi-Fi Assistants are configured.
The card is no longer being used.
Bug: 13780935
Change-Id: Idddf971404532256165045665bd0a6b19966d2bd
Configurations for these networks are not returned in
getConfiguredNetworks() and likely shouldn't be as clients of this API
would not expect them. (Note also that the ephemeral bit is marked
@hide). But the framework may connect to them regardless.
In these cases, as long as the connection status is something other
than the coarse-level DISCONNECTED, we show the status to be an
accurate representation of Wi-Fi state. (To make this possible, we
pass around the full NetworkInfo instead of just the DetailedState,
allowing us to get the coarse state where needed).
When long pressing on a non-DISCONNECTED ephemeral network, we offer
the ability to save the configuration. (Note that this flow is
currently broken and being tracked by another bug, but the behavior is
consistent with what happens when you simply click on the SSID).
Bug: 18205278
Change-Id: I30592c89546068c796f458a86bb26eb3b28c64df
This allows QS to set an extra that will launch the adding network
dialog directly for a specified ssid. It will be used to take users
straight from QS to the password entry, when a secure network is
selected.
Bug: 17722817
Change-Id: I570596af906de005c505678b539f915c06e6fd14
+ Removed Wi-Fi Assistant message in Wi-Fi Advanced since it was
overridden by the Wi-Fi Assistant.
+ Removed Wi-Fi Assistant message in Wi-Fi Assistant Card. Instead,
it is programatically created when the scorer is known.
+ "Google" was replaced with a placeholder.
Bug: 17457236
Change-Id: If3aab06c911ecf6ec13cbf00dea2fe9333abc1fc
SDK version is an int, not a long. (Also change SharedPreference key
to avoid issues for people who've already dismissed the Wifi Assistant
card).
Bug: 17304642
Change-Id: Ic959516b88e91edd53562703fa7db9c15ead20e4
Use a custom empty view to show the status while wifi is scanning
or off. Cannot use android.R.id.empty because in phone portrait
layout the illustration is the listview header, which will be hidden
if the list is empty and we use ListView.setEmptyView.
Bug: 17183006
Change-Id: Ie8598303f4e61f87e078008fb7a03918ba92c9ef
This replaces the previous behavior of an increasing timeout. When the
user dismisses the WiFi Assistant card, either by opting out or
successfully configuring the assistant, the card is suppressed until
the next major platform upgrade (assuming the assistant is not enabled
at the time of the upgrade).
Bug: 16902858
Change-Id: I5373a7a743f21777b7b75a620b5a4e9004e57466
Use a ListView header instead of a Preference to display the card at
the top of the list.
Also clean some dead code.
Bug: 16378017
Change-Id: I5a7f1d197cde071c45395b6d7f6016aa7201187a
This is not right because wpa_supplicant states are transient (for instance when the WiFi Layer, at Layer 2, is going thru some harmless spurious disconnection cycle due to WiFi signal fluctuation). This cause the state of the WiFi Network to appear to be unstable to the user.
Hence, I removed dependencies on wpa_supplicant internal state.
In addition so as to improve debugging, I added the BSSID to the Wifi Verbose Logging string which is shown in wifi picker alongside the current network. This string only appear when a user goes into Developper Options and enable WiFi Verbose Logging.
The below bug is an example of situation where a spurious disconnect (a coupld seconds) handled by wpa_supplicant can cause the WiFi Settings to indicate that the link is unstable.
Bug:16140888 Wifi best network selection not smooth
Change-Id: I0e7c6b86262b88ed993c46fcdcdbab4d9b1f5ea1
Do not create the assistant card if we are in WifiPickerActivity,
which includes setup wizard and account login.
Bug: 16382431
Change-Id: Id5eaa8040eafe5222e1a5c9276a2a10bedebfd71
We have been using forget() to prevent auto-reconnection when the
user hits back to Wifi setup. This has the side effect of forgetting
networks, which is undesirable especially for password protected APs.
The new mechanism keeps a flag on whether the user has selected a
connection. Only auto-advance if the user has picked a network and
there is a valid WiFi connection.
The new EXTRA_REQUIRE_USER_SELECTION can specify whether a user
selection is required initially. That is, whether to auto finish if
the system connected to a network without user input. The default is
false so WiFi can be skipped if the user started setup wizard with
a valid WiFi connection (e.g. after System Update). Note that a user
selection is always required when the user goes back from the next
screen.
Since the new AP dialog does not have a connect button, the SKIP
button in the navigation bar also changes to NEXT when there is a
valid WiFi connection, so the user can hit NEXT if they decided not
to change the network.
Bug: 15333554
Bug: 15999487
Change-Id: I98e935b8e09e470a0c49c44bc299bb2eced98634
Only show the card if we haven't already enabled an assistant, and if
there's one available on the device to enable. (For now, we enable the
first one; in the future, we can offer a selection between
assistants).
When the user opts in, we either show the standard system activity or
the custom opt-in activity if the assistant has defined one. In either
case, we only dismiss the card if the child activity indicates that
opt-in was successful.
Bug: 16376277
Change-Id: Ic92c7676c563ab8c8fb695117a053004f15f7d25