]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blob - app/src/main/AndroidManifest.xml
e23f8b7f792ea57bb09fbc6af1af6758ca98adcf
[PrivacyBrowserAndroid.git] / app / src / main / AndroidManifest.xml
1 <?xml version="1.0" encoding="utf-8"?>
2
3 <!--
4   Copyright © 2015-2021 Soren Stoutner <soren@stoutner.com>.
5
6   This file is part of Privacy Browser <https://www.stoutner.com/privacy-browser>.
7
8   Privacy Browser is free software: you can redistribute it and/or modify
9   it under the terms of the GNU General Public License as published by
10   the Free Software Foundation, either version 3 of the License, or
11   (at your option) any later version.
12
13   Privacy Browser is distributed in the hope that it will be useful,
14   but WITHOUT ANY WARRANTY; without even the implied warranty of
15   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16   GNU General Public License for more details.
17
18   You should have received a copy of the GNU General Public License
19   along with Privacy Browser.  If not, see <http://www.gnu.org/licenses/>. -->
20
21 <!-- Install location auto allows users to move Privacy Browser to an SD card if desired. -->
22 <manifest
23     xmlns:android="http://schemas.android.com/apk/res/android"
24     xmlns:tools="http://schemas.android.com/tools"
25     package="com.stoutner.privacybrowser"
26     android:installLocation="auto" >
27
28     <!-- Required to load websites. -->
29     <uses-permission android:name="android.permission.INTERNET" />
30
31     <!-- Required to create home screen shortcuts. -->
32     <uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />
33
34
35     <!-- Support Chromebooks that don't have a touch screen. -->
36     <uses-feature android:name="android.hardware.touchscreen" android:required="false" />
37
38     <!-- List the apps that Privacy Browser needs to query to see if they are installed. -->
39     <queries>
40         <!-- I2P. -->
41         <package android:name="net.i2p.android.router" />
42
43         <!-- Orbot. -->
44         <package android:name="org.torproject.android" />
45
46         <!-- OpenKeyChain. -->
47         <package android:name="org.sufficientlysecure.keychain" />
48     </queries>
49
50     <!-- For API >= 23, app data is automatically backed up to Google cloud servers unless `android:allowBackup="false"` and `android:fullBackupContent="false"` is set. -->
51     <application
52         android:label="@string/privacy_browser"
53         android:icon="@mipmap/privacy_browser"
54         android:roundIcon="@mipmap/privacy_browser_round"
55         android:allowBackup="false"
56         android:fullBackupContent="false"
57         android:supportsRtl="true"
58         android:networkSecurityConfig="@xml/network_security_config"
59         tools:ignore="UnusedAttribute" >
60
61         <!-- If `android:name="android.webkit.WebView.MetricsOptOut"` is not `true` then `WebViews` will upload metrics to Google.  <https://developer.android.com/reference/android/webkit/WebView.html> -->
62         <meta-data
63             android:name="android.webkit.WebView.MetricsOptOut"
64             android:value="true" />
65
66         <!-- Explicitly disable "Safe Browsing". -->
67         <meta-data
68             android:name="android.webkit.WebView.EnableSafeBrowsing"
69             android:value="false" />
70
71         <!-- Specify the Application ID used by the ads in the free flavor. -->
72         <meta-data
73             android:name="com.google.android.gms.ads.APPLICATION_ID"
74             android:value="@string/google_app_id" />
75
76         <!-- Don't initialize the ad system in the free flavor until it is explicitly called. -->
77         <meta-data
78             android:name="com.google.android.gms.ads.DELAY_APP_MEASUREMENT_INIT"
79             android:value="true"/>
80
81         <!-- The file provider is required to encrypt files with OpenKeychain. -->
82         <provider
83             android:name="androidx.core.content.FileProvider"
84             android:authorities="@string/file_provider"
85             android:exported="false"
86             android:grantUriPermissions="true" >
87
88             <meta-data
89                 android:name="android.support.FILE_PROVIDER_PATHS"
90                 android:resource="@xml/file_provider_paths" />
91         </provider>
92         
93         <!-- The label uses the short name so that it isn't truncated under the icon in the launcher on most phones.
94             The theme has to be defined here or an ugly title bar is displayed when the app launches.
95             `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
96             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
97             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
98             `android:launchMode="singleTask"` makes the app launch in a new task instead of inside the task of the program that sends it an intent.
99             It also makes it reuse an existing Privacy Browser activity if available instead of launching a new one.
100             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
101             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
102         <activity
103             android:name=".activities.MainWebViewActivity"
104             android:label="@string/short_name"
105             android:theme="@style/PrivacyBrowser"
106             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
107             android:launchMode="singleTask"
108             android:screenOrientation="fullUser"
109             android:persistableMode="persistNever"
110             tools:ignore="UnusedAttribute" >
111
112             <intent-filter>
113                 <action android:name="android.intent.action.MAIN" />
114                 <category android:name="android.intent.category.LAUNCHER" />
115             </intent-filter>
116
117             <!-- Process web intents. -->
118             <intent-filter>
119                 <action android:name="android.intent.action.VIEW" />
120
121                 <category android:name="android.intent.category.BROWSABLE" />
122                 <category android:name="android.intent.category.DEFAULT" />
123
124                 <data android:scheme="http" />
125                 <data android:scheme="https" />
126             </intent-filter>
127
128             <!-- Process all content intents. -->
129             <intent-filter>
130                 <action android:name="android.intent.action.VIEW" />
131
132                 <category android:name="android.intent.category.BROWSABLE" />
133                 <category android:name="android.intent.category.DEFAULT" />
134
135                 <data android:scheme="content" />
136
137                 <!-- Process text and images. -->
138                 <data android:mimeType="text/*" />
139                 <data android:mimeType="image/*" />
140
141                 <!-- Process MHT web archives. -->
142                 <data android:mimeType="multipart/related" />
143                 <data android:mimeType="message/rfc822" />
144             </intent-filter>
145
146             <!-- Process intents for text strings.  Sometimes URLs are presented this way. -->
147             <intent-filter>
148                 <action android:name="android.intent.action.SEND" />
149
150                 <category android:name="android.intent.category.DEFAULT" />
151
152                 <data android:mimeType="text/plain" />
153             </intent-filter>
154
155             <!-- Process web search intents. -->
156             <intent-filter>
157                 <action android:name="android.intent.action.WEB_SEARCH" />
158
159                 <category android:name="android.intent.category.BROWSABLE" />
160                 <category android:name="android.intent.category.DEFAULT" />
161             </intent-filter>
162         </activity>
163
164
165         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
166             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
167             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
168             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
169             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
170         <activity
171             android:name=".activities.BookmarksActivity"
172             android:label="@string/bookmarks"
173             android:parentActivityName=".activities.MainWebViewActivity"
174             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
175             android:screenOrientation="fullUser"
176             android:persistableMode="persistNever"
177             tools:ignore="UnusedAttribute" />
178
179         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
180             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
181             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
182             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
183             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
184         <activity
185             android:name=".activities.BookmarksDatabaseViewActivity"
186             android:label="@string/bookmarks_database_view"
187             android:parentActivityName=".activities.BookmarksActivity"
188             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
189             android:screenOrientation="fullUser"
190             android:persistableMode="persistNever"
191             tools:ignore="UnusedAttribute" />
192
193         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
194             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
195             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
196             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
197             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
198         <activity
199             android:name=".activities.RequestsActivity"
200             android:label="@string/requests"
201             android:parentActivityName=".activities.MainWebViewActivity"
202             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
203             android:screenOrientation="fullUser"
204             android:persistableMode="persistNever"
205             tools:ignore="UnusedAttribute" />
206
207         <!-- `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
208             `android:configChanges="keyboard|keyboardHidden"` makes the activity not reload when a bluetooth keyboard is activated/goes to sleep.
209             `android:windowSoftInputMode="stateAlwaysHidden"` keeps the keyboard from displaying when the screen is rotated and after the `AddDomainDialog` is dismissed.
210             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
211             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
212         <activity
213             android:name=".activities.DomainsActivity"
214             android:label="@string/domains"
215             android:parentActivityName=".activities.MainWebViewActivity"
216             android:configChanges="screenLayout|keyboard|keyboardHidden"
217             android:screenOrientation="fullUser"
218             android:windowSoftInputMode="stateAlwaysHidden"
219             android:persistableMode="persistNever"
220             tools:ignore="UnusedAttribute" />
221
222         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
223             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
224             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
225             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
226             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
227         <activity
228             android:name=".activities.SettingsActivity"
229             android:label="@string/settings"
230             android:parentActivityName=".activities.MainWebViewActivity"
231             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
232             android:screenOrientation="fullUser"
233             android:persistableMode="persistNever"
234             tools:ignore="UnusedAttribute" />
235
236         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
237             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
238             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
239             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
240             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
241         <activity
242             android:name=".activities.ImportExportActivity"
243             android:label="@string/import_export"
244             android:parentActivityName=".activities.MainWebViewActivity"
245             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
246             android:screenOrientation="fullUser"
247             android:persistableMode="persistNever"
248             tools:ignore="UnusedAttribute" />
249
250         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
251             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
252             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
253             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
254             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
255         <activity
256             android:name=".activities.LogcatActivity"
257             android:label="@string/logcat"
258             android:parentActivityName=".activities.MainWebViewActivity"
259             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
260             android:screenOrientation="fullUser"
261             android:persistableMode="persistNever"
262             tools:ignore="UnusedAttribute" />
263
264         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
265             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
266             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
267             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
268             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
269         <activity
270             android:name=".activities.GuideActivity"
271             android:label="@string/guide"
272             android:parentActivityName=".activities.MainWebViewActivity"
273             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
274             android:screenOrientation="fullUser"
275             android:persistableMode="persistNever"
276             tools:ignore="UnusedAttribute" />
277
278         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
279             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
280             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
281             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
282             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
283         <activity
284             android:name=".activities.AboutActivity"
285             android:label="@string/about_privacy_browser"
286             android:parentActivityName=".activities.MainWebViewActivity"
287             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
288             android:screenOrientation="fullUser"
289             android:persistableMode="persistNever"
290             tools:ignore="UnusedAttribute" />
291
292         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
293             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
294             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
295             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
296             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
297         <activity
298             android:name=".activities.ViewSourceActivity"
299             android:label="@string/view_source"
300             android:parentActivityName=".activities.MainWebViewActivity"
301             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
302             android:screenOrientation="fullUser"
303             android:persistableMode="persistNever"
304             tools:ignore="UnusedAttribute" />
305     </application>
306 </manifest>