Merge "Update REQUEST_PEERS message with calling package" am: 836e74052e
am: e8431a09ca
Change-Id: If5f4f60919f2f4083f109e1609ecd1834030f1c8
This commit is contained in:
@@ -283,6 +283,13 @@ public class WifiP2pManager {
|
||||
public static final String EXTRA_HANDOVER_MESSAGE =
|
||||
"android.net.wifi.p2p.EXTRA_HANDOVER_MESSAGE";
|
||||
|
||||
/**
|
||||
* The lookup key for a calling package returned by the WifiP2pService.
|
||||
* @hide
|
||||
*/
|
||||
public static final String CALLING_PACKAGE =
|
||||
"android.net.wifi.p2p.CALLING_PACKAGE";
|
||||
|
||||
IWifiP2pManager mService;
|
||||
|
||||
private static final int BASE = Protocol.BASE_WIFI_P2P_MANAGER;
|
||||
@@ -1271,7 +1278,10 @@ public class WifiP2pManager {
|
||||
*/
|
||||
public void requestPeers(Channel c, PeerListListener listener) {
|
||||
checkChannel(c);
|
||||
c.mAsyncChannel.sendMessage(REQUEST_PEERS, 0, c.putListener(listener));
|
||||
Bundle callingPackage = new Bundle();
|
||||
callingPackage.putString(CALLING_PACKAGE, c.mContext.getOpPackageName());
|
||||
c.mAsyncChannel.sendMessage(REQUEST_PEERS, 0, c.putListener(listener),
|
||||
callingPackage);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user