hi,
can somebody clarify few things here. I read
http://developer.android.com/guide/topics/intents/intents-filters.html
about intents and tried to listen for CALL action so my application
could start if user dial a number and start conversation.

I tried with something like
<intent-filter>
            <action android:name="android.intent.action.CALL" />
            <category android:name="android.intent.category.LAUNCHER" /
>
</intent-filter>

but it doesnt seem to work.
But now after I ve examine the notepad sample (http://
developer.android.com/resources/samples/NotePad/index.html) I am even
more confused. I expected filters
<intent-filter>
            <action android:name="android.intent.action.VIEW" />
            <action android:name="android.intent.action.EDIT" />
            <action android:name="android.intent.action.PICK" />
            <category android:name="android.intent.category.DEFAULT" /
>
            <data android:mimeType="vnd.android.cursor.dir/
vnd.google.note" />
</intent-filter>
<intent-filter>
            <action android:name="android.intent.action.GET_CONTENT" /
>
            <category android:name="android.intent.category.DEFAULT" /
>
            <data android:mimeType="vnd.android.cursor.item/
vnd.google.note" />
</intent-filter>
to define kind of call back in an activity code but in turn I found
@Override
protected void onListItemClick(ListView l, View v, int position, long
id) {
            Uri uri =
ContentUris.withAppendedId(getIntent().getData(), id);

            String action = getIntent().getAction();
            if (Intent.ACTION_PICK.equals(action) ||
Intent.ACTION_GET_CONTENT.equals(action)) {
            // The caller is waiting for us to return a note selected
by
            // the user.  The have clicked on one, so return it now.
                        setResult(RESULT_OK, new
Intent().setData(uri));
            } else {
            // Launch activity to view/edit the currently selected
item
                        startActivity(new Intent(Intent.ACTION_EDIT,
uri));
            }
}
so I dont know what to think about it and I cant find any explanation
for this sample.

could somebody guide me here in good direction, point me to some
resources that I obviously missed??
thanks for help!!

cheers

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to