The single intent filter for this activity uses a custom action called " TITLE". It must be invoked on a specific note (data type, like the previous VIEW and EDIT actions. However, here the activity displays the title contained in the note data, not the content of the note itself.

In addition to supporting the usual DEFAULT category, the title editor also supports two other standard categories: ALTERNATIVE and SELECTED ALTERNATIVE. These categories identify activities that can be presented to users in a menu of options (much as the LAUNCHER category identifies activities that should be presented to user in the application launcher). Note that the filter also supplies an explicit label (via android:label = "@string/resolve title") to better control what users see when presented with this activity as an alternative action to the data they are currently viewing. (For more information on these categories and building options menus, see the PackageManager.queryIntentActivityOptions() and Menu.addIntentOptions() methods.)

Given these capabilities, the following intent will resolve to the TitleEditor activity:

0 0

Post a comment