]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blob - app/src/main/AndroidManifest.xml
Redesign file access to work with the scoped storage. https://redmine.stoutner.com...
[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
39     <!-- For API >= 23, app data is automatically backed up to Google cloud servers unless `android:allowBackup="false"` and `android:fullBackupContent="false"` is set. -->
40     <application
41         android:label="@string/privacy_browser"
42         android:icon="@mipmap/privacy_browser"
43         android:roundIcon="@mipmap/privacy_browser_round"
44         android:allowBackup="false"
45         android:fullBackupContent="false"
46         android:supportsRtl="true"
47         android:networkSecurityConfig="@xml/network_security_config"
48         tools:ignore="UnusedAttribute" >
49
50         <!-- 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> -->
51         <meta-data
52             android:name="android.webkit.WebView.MetricsOptOut"
53             android:value="true" />
54
55         <!-- Explicitly disable "Safe Browsing". -->
56         <meta-data
57             android:name="android.webkit.WebView.EnableSafeBrowsing"
58             android:value="false" />
59
60         <!-- Specify the Application ID used by the ads in the free flavor. -->
61         <meta-data
62             android:name="com.google.android.gms.ads.APPLICATION_ID"
63             android:value="@string/google_app_id" />
64
65         <!-- Don't initialize the ad system in the free flavor until it is explicitly called. -->
66         <meta-data
67             android:name="com.google.android.gms.ads.DELAY_APP_MEASUREMENT_INIT"
68             android:value="true"/>
69
70         <!-- The file provider is required to encrypt files with OpenKeychain. -->
71         <provider
72             android:name="androidx.core.content.FileProvider"
73             android:authorities="@string/file_provider"
74             android:exported="false"
75             android:grantUriPermissions="true" >
76
77             <meta-data
78                 android:name="android.support.FILE_PROVIDER_PATHS"
79                 android:resource="@xml/file_provider_paths" />
80         </provider>
81         
82         <!-- The label uses the short name so that it isn't truncated under the icon in the launcher on most phones.
83             The theme has to be defined here or an ugly title bar is displayed when the app launches.
84             `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
85             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
86             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
87             `android:launchMode="singleTask"` makes the app launch in a new task instead of inside the task of the program that sends it an intent.
88             It also makes it reuse an existing Privacy Browser activity if available instead of launching a new one.
89             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
90             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
91         <activity
92             android:name=".activities.MainWebViewActivity"
93             android:label="@string/short_name"
94             android:theme="@style/PrivacyBrowser"
95             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
96             android:launchMode="singleTask"
97             android:screenOrientation="fullUser"
98             android:persistableMode="persistNever"
99             tools:ignore="UnusedAttribute" >
100
101             <intent-filter>
102                 <action android:name="android.intent.action.MAIN" />
103                 <category android:name="android.intent.category.LAUNCHER" />
104             </intent-filter>
105
106             <!-- Process web intents. -->
107             <intent-filter>
108                 <action android:name="android.intent.action.VIEW" />
109
110                 <category android:name="android.intent.category.BROWSABLE" />
111                 <category android:name="android.intent.category.DEFAULT" />
112
113                 <data android:scheme="http" />
114                 <data android:scheme="https" />
115             </intent-filter>
116
117             <!-- Process content intents for text files. -->
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="content" />
125                 <data android:mimeType="text/*" />
126             </intent-filter>
127
128             <!-- Process intents for text strings.  Sometimes URLs are presented this way. -->
129             <intent-filter>
130                 <action android:name="android.intent.action.SEND" />
131
132                 <category android:name="android.intent.category.DEFAULT" />
133
134                 <data android:mimeType="text/plain" />
135             </intent-filter>
136
137             <!-- Process web search intents. -->
138             <intent-filter>
139                 <action android:name="android.intent.action.WEB_SEARCH" />
140
141                 <category android:name="android.intent.category.BROWSABLE" />
142                 <category android:name="android.intent.category.DEFAULT" />
143             </intent-filter>
144         </activity>
145
146
147         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
148             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
149             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
150             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
151             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
152         <activity
153             android:name=".activities.BookmarksActivity"
154             android:label="@string/bookmarks"
155             android:parentActivityName=".activities.MainWebViewActivity"
156             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
157             android:screenOrientation="fullUser"
158             android:persistableMode="persistNever"
159             tools:ignore="UnusedAttribute" />
160
161         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
162             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
163             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
164             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
165             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
166         <activity
167             android:name=".activities.BookmarksDatabaseViewActivity"
168             android:label="@string/bookmarks_database_view"
169             android:parentActivityName=".activities.BookmarksActivity"
170             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
171             android:screenOrientation="fullUser"
172             android:persistableMode="persistNever"
173             tools:ignore="UnusedAttribute" />
174
175         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
176             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
177             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
178             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
179             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
180         <activity
181             android:name=".activities.RequestsActivity"
182             android:label="@string/requests"
183             android:parentActivityName=".activities.MainWebViewActivity"
184             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
185             android:screenOrientation="fullUser"
186             android:persistableMode="persistNever"
187             tools:ignore="UnusedAttribute" />
188
189         <!-- `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
190             `android:configChanges="keyboard|keyboardHidden"` makes the activity not reload when a bluetooth keyboard is activated/goes to sleep.
191             `android:windowSoftInputMode="stateAlwaysHidden"` keeps the keyboard from displaying when the screen is rotated and after the `AddDomainDialog` is dismissed.
192             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
193             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
194         <activity
195             android:name=".activities.DomainsActivity"
196             android:label="@string/domains"
197             android:parentActivityName=".activities.MainWebViewActivity"
198             android:configChanges="screenLayout|keyboard|keyboardHidden"
199             android:screenOrientation="fullUser"
200             android:windowSoftInputMode="stateAlwaysHidden"
201             android:persistableMode="persistNever"
202             tools:ignore="UnusedAttribute" />
203
204         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
205             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
206             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
207             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
208             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
209         <activity
210             android:name=".activities.SettingsActivity"
211             android:label="@string/settings"
212             android:parentActivityName=".activities.MainWebViewActivity"
213             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
214             android:screenOrientation="fullUser"
215             android:persistableMode="persistNever"
216             tools:ignore="UnusedAttribute" />
217
218         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
219             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
220             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
221             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
222             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
223         <activity
224             android:name=".activities.ImportExportActivity"
225             android:label="@string/import_export"
226             android:parentActivityName=".activities.MainWebViewActivity"
227             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
228             android:screenOrientation="fullUser"
229             android:persistableMode="persistNever"
230             tools:ignore="UnusedAttribute" />
231
232         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
233             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
234             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
235             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
236             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
237         <activity
238             android:name=".activities.LogcatActivity"
239             android:label="@string/logcat"
240             android:parentActivityName=".activities.MainWebViewActivity"
241             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
242             android:screenOrientation="fullUser"
243             android:persistableMode="persistNever"
244             tools:ignore="UnusedAttribute" />
245
246         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
247             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
248             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
249             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
250             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
251         <activity
252             android:name=".activities.GuideActivity"
253             android:label="@string/guide"
254             android:parentActivityName=".activities.MainWebViewActivity"
255             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
256             android:screenOrientation="fullUser"
257             android:persistableMode="persistNever"
258             tools:ignore="UnusedAttribute" />
259
260         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
261             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
262             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
263             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
264             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
265         <activity
266             android:name=".activities.AboutActivity"
267             android:label="@string/about_privacy_browser"
268             android:parentActivityName=".activities.MainWebViewActivity"
269             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
270             android:screenOrientation="fullUser"
271             android:persistableMode="persistNever"
272             tools:ignore="UnusedAttribute" />
273
274         <!-- `android:configChanges="orientation|screenSize"` makes the activity not restart when the orientation changes, which preserves scroll location in the WebView.
275             `android:configChanges="screenLayout"` makes the activity not restart when entering or exiting split screen mode.
276             `android:configChanges="keyboard|keyboardHidden"` makes the activity not restart when a bluetooth keyboard is activated/goes to sleep.
277             `android:persistableMode="persistNever"` removes Privacy Browser from the recent apps list on a device reboot.
278             `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
279         <activity
280             android:name=".activities.ViewSourceActivity"
281             android:label="@string/view_source"
282             android:parentActivityName=".activities.MainWebViewActivity"
283             android:configChanges="orientation|screenSize|screenLayout|keyboard|keyboardHidden"
284             android:screenOrientation="fullUser"
285             android:persistableMode="persistNever"
286             tools:ignore="UnusedAttribute" />
287     </application>
288 </manifest>