Reputation: 3080
Is it possible to launch an option like which application you want to open on contact icon is clicked in Android? So when I clicked on the Android phone icon, then it should ask to whether you want to launch Android default app or my application.
Basically I have developed call log module of Android application with customization so I want to give user to select any option at click of Android phone icon.
So is it possible?
Upvotes: 1
Views: 311
Reputation: 9697
it is possible. i try for Dail icon put this code in your androidmenifest file
<intent-filter>
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.intent.category.DEFAULT" />
<action android:name="android.intent.action.DIAL" />
</intent-filter>
when clicked on call icon then open option complete action using list my application is in list.
i think also action tag available for contact icon.
Upvotes: 1
Reputation: 2308
It is possible, in fact it happens naturally when you have more than one application installed for a desired action. Intent filters would help you.
Upvotes: 1
Reputation: 2662
No, it's not possible. When you click an icon in the launcher it simply launches the clicked app. You could instead ask the user which app to use in certain situations like when trying to call someone. I'm not very sure, but you might be able to ask the user which log to use when clicking on a missed call notification.
Upvotes: 0