Code example for FragmentActivity

Methods: onPause, unregisterReceiver

0
	 *  
	 * @see android.support.v4.app.FragmentActivity#onPause() 
	 */ 
	@Override 
	protected void onPause() { 
		super.onPause(); 
		embeddedAmarino.disconnect(BT_DEVICE_ADDRESS);
		if (null != receiver) {
			try { 
				unregisterReceiver(receiver);
			} catch (Exception e) {
				Log.e(TAG, Log.getStackTraceString(e));
			} 
		} 
	} 
 
	/** 
	 * Setup the fragment layout. 
	 */ 
	protected void initLayout() { 
		setContentView(R.layout.main);