1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2007 The Android Open Source Project 3 4 Licensed under the Apache License, Version 2.0 (the "License"); 5 you may not use this file except in compliance with the License. 6 You may obtain a copy of the License at 7 8 http://www.apache.org/licenses/LICENSE-2.0 9 10 Unless required by applicable law or agreed to in writing, software 11 distributed under the License is distributed on an "AS IS" BASIS, 12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 See the License for the specific language governing permissions and 14 limitations under the License. 15--> 16 17<!-- Declare the contents of this Android application. The namespace 18 attribute brings in the Android platform namespace, and the package 19 supplies a unique name for the application. When writing your 20 own application, the package name must be changed from "com.example.*" 21 to come from a domain that you own or have control over. --> 22<manifest xmlns:android="http://schemas.android.com/apk/res/android" 23 package="com.example.android.notepad" 24> 25 <application android:icon="@drawable/app_notes" 26 android:label="@string/app_name" 27 > 28 <provider android:name="NotePadProvider" 29 android:authorities="com.google.provider.NotePad" 30 /> 31 32 <activity android:name="NotesList" android:label="@string/title_notes_list"> 33 <intent-filter> 34 <action android:name="android.intent.action.MAIN" /> 35 <category android:name="android.intent.category.LAUNCHER" /> 36 </intent-filter> 37 <intent-filter> 38 <action android:name="android.intent.action.VIEW" /> 39 <action android:name="android.intent.action.EDIT" /> 40 <action android:name="android.intent.action.PICK" /> 41 <category android:name="android.intent.category.DEFAULT" /> 42 <data android:mimeType="vnd.android.cursor.dir/vnd.google.note" /> 43 </intent-filter> 44 <intent-filter> 45 <action android:name="android.intent.action.GET_CONTENT" /> 46 <category android:name="android.intent.category.DEFAULT" /> 47 <data android:mimeType="vnd.android.cursor.item/vnd.google.note" /> 48 </intent-filter> 49 </activity> 50 51 <activity android:name="NoteEditor" 52 android:theme="@android:style/Theme.Light" 53 android:label="@string/title_note" 54 android:screenOrientation="sensor" 55 android:configChanges="keyboardHidden|orientation" 56 > 57 <!-- This filter says that we can view or edit the data of 58 a single note --> 59 <intent-filter android:label="@string/resolve_edit"> 60 <action android:name="android.intent.action.VIEW" /> 61 <action android:name="android.intent.action.EDIT" /> 62 <action android:name="com.android.notepad.action.EDIT_NOTE" /> 63 <category android:name="android.intent.category.DEFAULT" /> 64 <data android:mimeType="vnd.android.cursor.item/vnd.google.note" /> 65 </intent-filter> 66 67 <!-- This filter says that we can create a new note inside 68 of a directory of notes. --> 69 <intent-filter> 70 <action android:name="android.intent.action.INSERT" /> 71 <category android:name="android.intent.category.DEFAULT" /> 72 <data android:mimeType="vnd.android.cursor.dir/vnd.google.note" /> 73 </intent-filter> 74 75 </activity> 76 77 <activity android:name="TitleEditor" android:label="@string/title_edit_title" 78 android:theme="@android:style/Theme.Dialog" 79 android:windowSoftInputMode="stateVisible"> 80 <!-- This activity implements an alternative action that can be 81 performed on notes: editing their title. It can be used as 82 a default operation if the user invokes this action, and is 83 available as an alternative action for any note data. --> 84 <intent-filter android:label="@string/resolve_title"> 85 <!-- This is the action we perform. It is a custom action we 86 define for our application, not a generic VIEW or EDIT 87 action since we are not a general note viewer/editor. --> 88 <action android:name="com.android.notepad.action.EDIT_TITLE" /> 89 <!-- DEFAULT: execute if being directly invoked. --> 90 <category android:name="android.intent.category.DEFAULT" /> 91 <!-- ALTERNATIVE: show as an alternative action when the user is 92 working with this type of data. --> 93 <category android:name="android.intent.category.ALTERNATIVE" /> 94 <!-- SELECTED_ALTERNATIVE: show as an alternative action the user 95 can perform when selecting this type of data. --> 96 <category android:name="android.intent.category.SELECTED_ALTERNATIVE" /> 97 <!-- This is the data type we operate on. --> 98 <data android:mimeType="vnd.android.cursor.item/vnd.google.note" /> 99 </intent-filter> 100 </activity> 101 102 </application> 103</manifest> 104 105