There is a strange problem in my application development.
At some point in my application, this will call Intent (Intent.ACTION_SEND) to start Gmail, and the "Complete action using ..." dialog box will appear.
Despite the fact that I check the default field at the bottom and select Gmail, the next time my application calls the intention, the full action appears using the dialog.
I can’t get him to leave, although I have already selected the default application to run.
Any ideas why?
Intention example
private void do_gmail_failover() { // If GMailSender fails, revert back to old method Intent email_pic = new Intent(Intent.ACTION_SEND); // Commence choose photo action // Used to be ACTION_SEND email_pic.putExtra(Intent.EXTRA_EMAIL, Recipients); // Inserts Digital Signature address in recipient email_pic.putExtra(Intent.EXTRA_SUBJECT, DIGIJOB); // Inserts Track Number automatically in subject email_pic.putExtra(Intent.EXTRA_STREAM, uriTarget); // Attaches image to Gmail email_pic.setType("image/jpeg"); // Converts image to jpeg startActivityForResult(email_pic, RETURN_ACTIVITY); overridePendingTransition(R.anim.fadein, R.anim.fadeout); LOGCAT.DEBUG("do_gmail_failover", "Inside do_gmail_failover function"); }
source share