use of com.samourai.wallet.fragments.PaynymSelectModalFragment in project samourai-wallet-android by Samourai-Wallet.
the class SendActivity method onOptionsItemSelected.
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
int id = item.getItemId();
if (item.getItemId() == android.R.id.home) {
this.onBackPressed();
return true;
}
if (item.getItemId() == R.id.select_paynym) {
PaynymSelectModalFragment paynymSelectModalFragment = PaynymSelectModalFragment.newInstance(code -> processPCode(code, null));
paynymSelectModalFragment.show(getSupportFragmentManager(), "paynym_select");
return true;
}
// noinspection SimplifiableIfStatement
if (id == R.id.action_scan_qr) {
doScan();
} else if (id == R.id.action_ricochet) {
Intent intent = new Intent(SendActivity.this, RicochetActivity.class);
startActivity(intent);
} else if (id == R.id.action_empty_ricochet) {
emptyRicochetQueue();
} else if (id == R.id.action_utxo) {
doUTXO();
} else if (id == R.id.action_fees) {
doFees();
} else if (id == R.id.action_batch) {
doBatchSpend();
} else if (id == R.id.action_support) {
doSupport();
} else {
;
}
return super.onOptionsItemSelected(item);
}
Aggregations