Modern Apps git
git clone https://git.maproj.org/Modern-Apps.git
translate ▾

Modern-Apps.git / todo / src / main / AndroidManifest.xml

AndroidManifest.xml186 lines · 8.8 KiBRaw
1<?xml version="1.0" encoding="utf-8"?>
2<manifest xmlns:android="http://schemas.android.com/apk/res/android">
3
4 <!-- Task reminders and the daily summary. USE_EXACT_ALARM is install-granted on API 33+;
5 SCHEDULE_EXACT_ALARM covers 31-32. The scheduler still checks canScheduleExactAlarms()
6 and falls back to inexact alarms. -->
7 <!-- MAOS: opt out of the GrapheneOS Sensors permission (OTHER_SENSORS). -->
8 <!-- This app uses no motion/environment sensors; MAOS withholds the -->
9 <!-- Sensors permission at install instead of auto-granting it. -->
10 <uses-permission android:name="com.vayunmathur.permission.SENSORS_OPTOUT" />
11
12 <!-- Single APK for phone and watch. Deliberately NO
13 android.hardware.type.watch uses-feature here: required="true"
14 would block every phone install, and required="false" is
15 disallowed for this feature (lint InvalidWearFeatureAttribute;
16 Google's packaging model does not support one APK for Wear and
17 non-Wear via Play). This app does not distribute through Play's
18 watch channel — it is sideloaded / F-Droid-installed, where no
19 feature declaration is needed to install on a watch — so the
20 APK carries no watch feature filter at all and
21 FormFactor.isWatch (PackageManager.FEATURE_WATCH, still
22 reported by watch hardware at runtime) routes the experience. -->
23 <uses-feature
24 android:name="android.hardware.touchscreen"
25 android:required="false" />
26 <!-- Watch-local sync wakes the watch CPU when the link connects. -->
27 <uses-permission android:name="android.permission.WAKE_LOCK" />
28
29 <uses-permission android:name="android.permission.USE_EXACT_ALARM" />
30 <uses-permission
31 android:name="android.permission.SCHEDULE_EXACT_ALARM"
32 android:maxSdkVersion="32" />
33 <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
34 <!-- Optional "show tasks in calendar" mirror into a local read-only calendar; asked for
35 only when the user turns it on in settings. -->
36 <uses-permission android:name="android.permission.READ_CALENDAR" />
37 <uses-permission android:name="android.permission.WRITE_CALENDAR" />
38 <!-- Alarms do not survive a reboot; re-armed by BootReceiver. -->
39 <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
40
41 <!-- Relay IPC for the everysync app's TodoSink. Signature-level: only apps signed
42 with the Modern Apps key can hold it, and the provider additionally narrows the
43 caller to com.vayunmathur.everysync at runtime. -->
44 <permission
45 android:name="com.vayunmathur.todo.permission.RELAY"
46 android:protectionLevel="signature" />
47
48 <!-- Assistant tools (get_todos / create_todo / complete_todo) for openassistant. -->
49 <permission
50 android:name="com.vayunmathur.todo.permissions.ACCESS_TODO"
51 android:protectionLevel="signature" />
52
53 <!-- Voice input in quick add goes through the user's speech recognizer. -->
54 <queries>
55 <intent>
56 <action android:name="android.speech.action.RECOGNIZE_SPEECH" />
57 </intent>
58 <!-- Settings' sync row opens EverySync. -->
59 <package android:name="com.vayunmathur.everysync" />
60 </queries>
61
62 <application
63 android:name=".TodoApplication"
64 android:allowBackup="true"
65 android:backupAgent=".platform.AppBackupAgent"
66 android:dataExtractionRules="@xml/data_extraction_rules"
67 android:icon="@mipmap/ic_launcher"
68 android:label="@string/app_name"
69 android:roundIcon="@mipmap/ic_launcher"
70 android:supportsRtl="true"
71 android:theme="@style/Theme.General">
72 <!-- Watch experience is paired with the phone app, not standalone. -->
73 <meta-data
74 android:name="com.google.android.wearable.standalone"
75 android:value="false" />
76 <activity
77 android:configChanges="mcc|mnc|colorMode|density|fontScale|fontWeightAdjustment|keyboard|keyboardHidden|layoutDirection|navigation|orientation|screenLayout|screenSize|smallestScreenSize|touchscreen|uiMode"
78 android:name=".MainActivity"
79 android:exported="true"
80 android:launchMode="singleTop"
81 android:theme="@style/Theme.General">
82 <intent-filter>
83 <action android:name="android.intent.action.MAIN" />
84 <category android:name="android.intent.category.LAUNCHER" />
85 </intent-filter>
86 <!-- Text shared from any app becomes a new task (one per line). -->
87 <intent-filter android:label="@string/share_label">
88 <action android:name="android.intent.action.SEND" />
89 <category android:name="android.intent.category.DEFAULT" />
90 <data android:mimeType="text/plain" />
91 </intent-filter>
92 <meta-data
93 android:name="android.app.shortcuts"
94 android:resource="@xml/shortcuts" />
95 </activity>
96
97 <activity
98 android:name=".intents.GetTodosIntent"
99 android:exported="true"
100 android:permission="com.vayunmathur.todo.permissions.ACCESS_TODO"
101 android:theme="@android:style/Theme.NoDisplay" />
102 <activity
103 android:name=".intents.InsertTodoIntent"
104 android:exported="true"
105 android:permission="com.vayunmathur.todo.permissions.ACCESS_TODO"
106 android:theme="@android:style/Theme.NoDisplay" />
107 <activity
108 android:name=".intents.CompleteTodoIntent"
109 android:exported="true"
110 android:permission="com.vayunmathur.todo.permissions.ACCESS_TODO"
111 android:theme="@android:style/Theme.NoDisplay" />
112
113 <receiver
114 android:name=".widget.TodayWidgetReceiver"
115 android:exported="true"
116 android:label="@string/widget_today_label">
117 <intent-filter>
118 <action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
119 </intent-filter>
120 <intent-filter>
121 <action android:name="android.intent.action.DATE_CHANGED" />
122 <action android:name="android.intent.action.TIME_SET" />
123 <action android:name="android.intent.action.TIMEZONE_CHANGED" />
124 </intent-filter>
125 <meta-data
126 android:name="android.appwidget.provider"
127 android:resource="@xml/today_widget_info" />
128 </receiver>
129 <receiver
130 android:name=".widget.QuickAddWidgetReceiver"
131 android:exported="true"
132 android:label="@string/widget_quick_add_label">
133 <intent-filter>
134 <action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
135 </intent-filter>
136 <meta-data
137 android:name="android.appwidget.provider"
138 android:resource="@xml/quick_add_widget_info" />
139 </receiver>
140
141 <service
142 android:name=".service.QuickAddTileService"
143 android:exported="true"
144 android:icon="@drawable/ic_add"
145 android:label="@string/tile_label"
146 android:permission="android.permission.BIND_QUICK_SETTINGS_TILE">
147 <intent-filter>
148 <action android:name="android.service.quicksettings.action.QS_TILE" />
149 </intent-filter>
150 </service>
151
152 <provider
153 android:name=".sync.RelayTodoProvider"
154 android:authorities="com.vayunmathur.todo.relay"
155 android:exported="true"
156 android:readPermission="com.vayunmathur.todo.permission.RELAY"
157 android:writePermission="com.vayunmathur.todo.permission.RELAY" />
158
159 <!-- Watch experience: entered only via MainActivity's watch routing
160 (no launcher filter of its own). Inert on a phone: it is reached
161 only on a watch, where WearTodoStore/WearLinkBridge run. -->
162 <activity
163 android:name=".ui.WearMainActivity"
164 android:exported="false"
165 android:taskAffinity=""
166 android:theme="@android:style/Theme.Material.NoActionBar" />
167
168 <receiver
169 android:name=".notifications.ReminderReceiver"
170 android:exported="false" />
171 <receiver
172 android:name=".notifications.ReminderActionReceiver"
173 android:exported="false" />
174 <receiver
175 android:name=".notifications.BootReceiver"
176 android:exported="true">
177 <intent-filter>
178 <action android:name="android.intent.action.BOOT_COMPLETED" />
179 <action android:name="android.intent.action.MY_PACKAGE_REPLACED" />
180 <action android:name="android.intent.action.TIME_SET" />
181 <action android:name="android.intent.action.TIMEZONE_CHANGED" />
182 </intent-filter>
183 </receiver>
184 </application>
185
186</manifest>