Android Complete action using keeps showing after default has been selected

落花浮王杯 提交于 2019-12-12 16:21:48

问题


I'm running into a weird issue in my app development.

At some point in my app, it would call an Intent (Intent.ACTION_SEND) to launch Gmail, and the "Complete action using..." dialog will appear.

Even though I check the default box at the bottom and select Gmail, the next time my app calls for the Intent, the Complete action using dialog keeps appearing.

I can not get it to go away even though I already selected the default app to launch.

Any ideas why?

Example of the Intent

   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");
 }  

来源:https://stackoverflow.com/questions/22238315/android-complete-action-using-keeps-showing-after-default-has-been-selected

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!