Customize the Android contact picker
I'd like to present a Contact picker, but add additional prompting when the picker is opened. On 1.5 the title is simply "Contacts".
I was thinking I could add an EXTRA_TITLE to the Intent which opens the picker, but it supposedly only works开发者_如何学Python on ACTION_CHOOSER, not ACTION_PICK.
Or do I have to roll my own Contact picker?
If you want functionality beyond what the built-in activities do, you must build your own version, and specify IntentFilter
s that match those of the activity you wish to "mimic".
Be advised, this does not simply "replace" any built-in activity's functionality. The system will automatically present a Chooser to the user, who may or may not pick your activity to complete the action.
Adding your own "extras" to a "system-replacement" activity has dubious value; everything else in the system will not know about your extras, and not send them!
精彩评论