Code example for WifiP2pManager

Methods: removeGroup

0
	/** 
	 * 接続中のPeerから切断する. 
	 */ 
	public void disconnect() { 
		mCallback.onDisconnect();
		mManager.removeGroup(mChannel, null);
	} 
 
	@Override 
	public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
		inflater.inflate(R.menu.action_items, menu);
	} 
 
	@Override 
	public boolean onOptionsItemSelected(MenuItem item) {
		if (item.getItemId() == R.id.wifi_settings) {
			startActivity(new Intent(Settings.ACTION_WIRELESS_SETTINGS));
			return true; 
		} else { 
			return super.onOptionsItemSelected(item);
		}