Info

The first, primary, purpose of this activity is to enable the user to interact with a single note &mdash to either VIEW the note or EDIT it. (The EDIT NOTE category is a synonym for EDIT.) The intent would contain the URI for data matching the MIME type vnd.android.cursor.item/vnd.google.note — that is, the URI for a single, specific note. It would typically be a URI that was returned by the PICK or GET_CONTENT actions of the NoteList activity.

As before, this filter lists the DEFAULT category so that the activity can be launched by intents that don't explicitly specify the NoteEditor class.

<intent-filter>

<action android:name="android.intent.action.INSERT" />

<category android:name="android.intent.category.DEFAULT"

/>

<data android:mimeType="vnd.android.cursor.dir/vnd.google

.note" />

</intent-filter>

The secondary purpose of this activity is to enable the user to create a new note, which it will INSERT into an existing directory of notes. The intent would contain the URI for data matching the MIME type vnd.android.cursor.dir/vnd.google.note — that is, the URI for the directory where the note should be placed.

Given these capabilities, the following intents will resolve to the NoteEditor activity: action: android.intent.action.VIEW

0 0

Post a comment