Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Intent chooser dialog shows package name besides the Activity label

If I send files via Intent to other applications, the chooser dialog on Samsung devices shows the package name of my application besides the defined Activity labels. On Nexus devices I only see the labels, as expected. How to fix this issue?

  • On Galaxy Note 3 both, label and package name are shown (see screenshot)
  • On Galaxy S3 only the package name is visible

enter image description here

like image 981
artkoenig Avatar asked Oct 17 '16 13:10

artkoenig


People also ask

What is the use of intent createChooser () method?

createChooser(intent, title); // Try to invoke the intent. // Define what your app should do if no activity can handle the intent. This displays a dialog with a list of apps that respond to the intent passed to the createChooser() method and uses the supplied text as the dialog title.

Which of the following will force the app chooser to show?

Forcing an App Chooser If you want to display the App Chooser every time the user calls the Intent, then you can force the app chooser by using createChooser() and pass it to the startActivity().

Which method of the Intent class allows you to pass information to the target?

putExtra method is used.

How do I find my Android package name?

You can find an app's package name in the URL of your app's Google Play Store listing. For example, the URL of an app page is play.google.com/store/apps/details? id=com. example.


1 Answers

Ok, I got it. It happens only if you use equal labels for your Activities. Some devices show you the package name for better differentiation.

like image 164
artkoenig Avatar answered Sep 27 '22 20:09

artkoenig