How-to start service automatically on system startup and on installation + custom Contacts ContextMenu

by Jonas Petersson » Tue, 14 Apr 2009 14:36:29 GMT


Sponsored Links
 


I do agree with this sentiment. However, for my app (Zap's Hitta) I need 
to grab the phone number just as the incoming call appears. Currently I 
do this by starting a service with a listener at boot time. I'd love to 
find a different way. (I also start it when the GUI is opened if needed, 
hence it starts at installation too.)

Related to my app (but sadly not the original subject): I understand 
that there is no way to use Contacts as a picker from my own Activity 
with my own ContextMenu since that particular case is explicitly 
disabled in an if statement.

Is there any way I could add an entry to the existing ContextMenu (in my 
case: "Lookup address" from phone number and store in phonebook) when 
Contacts is used the standard way?

I suspect it is not currently possible. Would adding such an ability be 
against the design goals?

(At the moment I use an ExpandableListActivity, but it's on the crude 
side for this purpose.)

                Thanks in advance / Jonas

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Handling long process after clicking menu item from the menu

Hi all,
  Upon the selection of a menu item from the menu, I wrote some code
to open a dialog using onCreateDialog of the activity. Each time a
dialog is opened, new data downloaded has to be shown on dialog, which
is pausing the application for 2 to 3 seconds. And the menu item
becomes unresponsive.

I tried using AsyncTask, but because of the following code, in
onCreateDialog,

protected Dialog onCreateDialog(int id) {

                Dialog dialog = null;

                switch (id) {

                    case DIALOG_WITH_DOWNLOADED_DATA:

                         DataDialog dataDialog = new DataDialog(this);
                         dialog = dataDialog.getDialog();

                          break;
               }
}


Even though, I extend AsyncTask to DataDialog class, I am not able to
return data because, onPostExecute() method returns void.

Please help.

-- 

2. Contacts App

Hi
could someone explain How the Contact app creates a scroll bar that displays 
the Alphabet as you go down ?

and group the contacts by first letter

Thanks

-- 

3. HTC Thunderbolt camera orientation

4. batere mulai boros..battery use paling banyak android system

5. Cannot get sound to play from notification

6. Downloading other applications from a stub

7. Question about Android 2.2/2.3 and Hardware accelerated graphics