Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit ab313f84 authored by Lorenzo Colitti's avatar Lorenzo Colitti
Browse files

Don't show "Connected, no Internet" any longer than necessary.

Currently, both the wifi detail view in Quick Settings and the
wifi settings screen show "connected, no internet" for a few
seconds after a network connects. This makes it seem that
network validation is slow, even though usually it only takes
tens or hundreds of milliseconds.

Fix this by updating the access point list when we receive an
onCapabilitiesChanged NetworkCallback for the current wifi
connection.

This also allows us to stop listening to the RSSI_CHANGED_ACTION
broadcast, because:

1. WifiStateMachine only ever sends out that broadcast just after
   calling updateCapabilities, which causes an
   onCapabilitiesChanged callback to be received.
2. We don't use any of the extras in the RSSI_CHANGED_ACTION
   broadcast, only call updateNetworkInfo, which we do on
   every onCapabilitiesChanged callback anyway.

While I'm at it, move a variable assignment around to improve
clarity.

Change-Id: I57d3a13754ba4d8c6d58c566713d3f07d0ed2476
parent 355a74f2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment