List of usage examples for android.app Activity RESULT_FIRST_USER
int RESULT_FIRST_USER
To view the source code for android.app Activity RESULT_FIRST_USER.
Click Source Link
From source file:co.taqat.call.LinphoneActivity.java
@Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { if (resultCode == Activity.RESULT_FIRST_USER && requestCode == SETTINGS_ACTIVITY) { if (data.getExtras().getBoolean("Exit", false)) { quit();//from w w w . j ava 2s. c o m } else { pendingFragmentTransaction = (FragmentsAvailable) data.getExtras() .getSerializable("FragmentToDisplay"); } } else if (resultCode == Activity.RESULT_FIRST_USER && requestCode == CALL_ACTIVITY) { getIntent().putExtra("PreviousActivity", CALL_ACTIVITY); callTransfer = data == null ? false : data.getBooleanExtra("Transfer", false); boolean chat = data == null ? false : data.getBooleanExtra("chat", false); if (chat) { pendingFragmentTransaction = FragmentsAvailable.CHAT_LIST; } if (LinphoneManager.getLc().getCallsNb() > 0) { initInCallMenuLayout(callTransfer); } else { resetClassicMenuLayoutAndGoBackToCallIfStillRunning(); } } else if (requestCode == PERMISSIONS_REQUEST_OVERLAY) { if (Compatibility.canDrawOverlays(this)) { LinphonePreferences.instance().enableOverlay(true); } } else { super.onActivityResult(requestCode, resultCode, data); } }
From source file:org.totschnig.myexpenses.fragment.TransactionList.java
@Override public void onActivityResult(int requestCode, int resultCode, Intent intent) { if (requestCode == ProtectedFragmentActivity.FILTER_CATEGORY_REQUEST && resultCode != Activity.RESULT_CANCELED) { String label = intent.getStringExtra(KEY_LABEL); if (resultCode == Activity.RESULT_OK) { long catId = intent.getLongExtra(KEY_CATID, 0); addFilterCriteria(R.id.FILTER_CATEGORY_COMMAND, new CategoryCriteria(label, catId)); }//w ww . ja v a2 s . c o m if (resultCode == Activity.RESULT_FIRST_USER) { long[] catIds = intent.getLongArrayExtra(KEY_CATID); addFilterCriteria(R.id.FILTER_CATEGORY_COMMAND, new CategoryCriteria(label, catIds)); } } }
From source file:org.linphone.LinphoneActivity.java
@Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { if (resultCode == Activity.RESULT_FIRST_USER && requestCode == SETTINGS_ACTIVITY) { if (data.getExtras().getBoolean("Exit", false)) { exit();/*from w w w. j a va 2 s. com*/ } else { FragmentsAvailable newFragment = (FragmentsAvailable) data.getExtras() .getSerializable("FragmentToDisplay"); changeCurrentFragment(newFragment, null, true); selectMenu(newFragment); } } else if (resultCode == Activity.RESULT_FIRST_USER && requestCode == CALL_ACTIVITY) { getIntent().putExtra("PreviousActivity", CALL_ACTIVITY); boolean callTransfer = data.getBooleanExtra("Transfer", false); //boolean callTransfer = data == null ? false : data.getBooleanExtra("Transfer", false); if (LinphoneManager.getLc().getCallsNb() > 0) { initInCallMenuLayout(callTransfer); //Log.e("Add call ni if ma : initInCallMenuLayout " + callTransfer); } else { resetClassicMenuLayoutAndGoBackToCallIfStillRunning(); //Log.e("Add call ni else ma : resetClassicMenuLayoutAndGoBackToCallIfStillRunning " + callTransfer); } } else { super.onActivityResult(requestCode, resultCode, data); } }
From source file:com.sim2dial.dialer.LinphoneActivity.java
@Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { if (resultCode == Activity.RESULT_FIRST_USER && requestCode == SETTINGS_ACTIVITY) { if (data.getExtras().getBoolean("Exit", false)) { exit();//from w ww.j a va2s .com } else { FragmentsAvailable newFragment = (FragmentsAvailable) data.getExtras() .getSerializable("FragmentToDisplay"); changeCurrentFragment(newFragment, null, true); selectMenu(newFragment); } } else if (requestCode == callActivity) { boolean callTransfer = data == null ? false : data.getBooleanExtra("Transfer", false); if (LinphoneManager.getLc().getCallsNb() > 0) { initInCallMenuLayout(callTransfer); } else { resetClassicMenuLayoutAndGoBackToCallIfStillRunning(); } } else { super.onActivityResult(requestCode, resultCode, data); } }