diff options
author | Yuhao Zheng <yuhaozheng@google.com> | 2013-10-09 11:53:51 -0700 |
---|---|---|
committer | Yuhao Zheng <yuhaozheng@google.com> | 2013-10-09 12:28:22 -0700 |
commit | 8b033d37cac86ad4961891d760ca883e8bd0ef97 (patch) | |
tree | 1a4b166f76140999ed453b4088375dbc2886a5fa /wifi/java/android/net | |
parent | a45251080cf1da1eef1e55c22c399e79342d4001 (diff) | |
download | frameworks_base-8b033d37cac86ad4961891d760ca883e8bd0ef97.zip frameworks_base-8b033d37cac86ad4961891d760ca883e8bd0ef97.tar.gz frameworks_base-8b033d37cac86ad4961891d760ca883e8bd0ef97.tar.bz2 |
Add a missing wifi p2p discovery changed broadcast
When we disable wifi while wifi p2p peer searching is in progress, we don't get
a WIFI_P2P_DISCOVERY_CHANGED_ACTION broadcast saying that discovery is stopped.
Since this broadcast is sticky, applications will still get the previous one
saying discovery is started even if wifi p2p has been disabled. Adding a
sendP2pDiscoveryChangedBroadcast when exiting P2pEnabledState fixes this problem,
and it won't be a duplicate as sendP2pDiscoveryChangedBroadcast checks for that.
Bug: 11151666
Change-Id: I62de8f3d17d80f151403b91cf5c62866d931c01b
Diffstat (limited to 'wifi/java/android/net')
-rw-r--r-- | wifi/java/android/net/wifi/p2p/WifiP2pService.java | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/wifi/java/android/net/wifi/p2p/WifiP2pService.java b/wifi/java/android/net/wifi/p2p/WifiP2pService.java index 625ffb8..23058f4 100644 --- a/wifi/java/android/net/wifi/p2p/WifiP2pService.java +++ b/wifi/java/android/net/wifi/p2p/WifiP2pService.java @@ -1080,6 +1080,7 @@ public class WifiP2pService extends IWifiP2pManager.Stub { @Override public void exit() { + sendP2pDiscoveryChangedBroadcast(false); sendP2pStateChangedBroadcast(false); mNetworkInfo.setIsAvailable(false); } |