Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Intent : remove Always / Only once buttons

I'm pretty new to Android development.

Is it possible to remove the two buttons (Always / Only Once) when opening an Intent.ACTION_GET_CONTENT ?

Here is my current code.

Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
startActivityForResult(intent,PICK);
like image 424
Matthieu Riegler Avatar asked Jun 27 '13 08:06

Matthieu Riegler


1 Answers

I found a way to achieve this :

Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
Intent openInChooser = Intent.createChooser(intent, "Open in...");
startActivityForResult(openInChooser,PICK);
like image 70
Matthieu Riegler Avatar answered Sep 23 '22 13:09

Matthieu Riegler