149 lines
7.4 KiB
XML
149 lines
7.4 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
|
package="net.typeblog.shelter"
|
|
android:installLocation="internalOnly" >
|
|
|
|
<uses-feature android:name="android.software.device_admin" android:required="true"/>
|
|
<uses-feature android:name="android.software.managed_users" android:required="true"/>
|
|
<!--<uses-permission android:name="android.permission.INTERACT_ACROSS_USERS"/>-->
|
|
|
|
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
|
|
<uses-permission android:name="android.permission.REQUEST_DELETE_PACKAGES" />
|
|
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
|
|
<uses-permission android:maxSdkVersion="25"
|
|
android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />
|
|
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
|
|
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
|
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />
|
|
<uses-permission android:name="android.permission.PACKAGE_USAGE_STATS" />
|
|
|
|
<!-- For querying apps on Android R and later -->
|
|
<queries>
|
|
<intent>
|
|
<action android:name="android.intent.action.MAIN"/>
|
|
</intent>
|
|
</queries>
|
|
|
|
<application
|
|
android:name=".ShelterApplication"
|
|
android:allowBackup="false"
|
|
android:icon="@mipmap/ic_launcher_egg"
|
|
android:label="@string/app_name"
|
|
android:roundIcon="@mipmap/ic_launcher_egg_round"
|
|
android:supportsRtl="true"
|
|
android:theme="@style/AppTheme">
|
|
|
|
<!-- The main activity for UI -->
|
|
<activity android:name=".ui.MainActivity"
|
|
android:launchMode="singleTask">
|
|
<intent-filter>
|
|
<action android:name="android.intent.action.MAIN" />
|
|
<category android:name="android.intent.category.LAUNCHER" />
|
|
</intent-filter>
|
|
</activity>
|
|
|
|
<!-- Setup Wizard -->
|
|
<activity android:name=".ui.SetupWizardActivity"
|
|
android:theme="@style/SuwThemeMaterial.Light"
|
|
android:launchMode="singleTask" />
|
|
|
|
<!-- The Settings activity -->
|
|
<activity android:name=".ui.SettingsActivity"
|
|
android:label="@string/settings" />
|
|
|
|
<!-- An activity that wraps intents that cross the profile boundary -->
|
|
<!-- Needed because only cross-profile Activity intents are supported -->
|
|
<activity android:name=".ui.DummyActivity"
|
|
android:excludeFromRecents="true"
|
|
android:launchMode="singleTask"
|
|
android:theme="@style/Theme.AppCompat.Translucent.NoTitleBar">
|
|
<intent-filter>
|
|
<action android:name="net.typeblog.shelter.action.FINALIZE_PROVISION" />
|
|
<action android:name="net.typeblog.shelter.action.START_SERVICE" />
|
|
<action android:name="net.typeblog.shelter.action.TRY_START_SERVICE" />
|
|
<action android:name="net.typeblog.shelter.action.INSTALL_PACKAGE" />
|
|
<action android:name="net.typeblog.shelter.action.UNINSTALL_PACKAGE" />
|
|
<action android:name="net.typeblog.shelter.action.UNFREEZE_AND_LAUNCH" />
|
|
<action android:name="net.typeblog.shelter.action.PUBLIC_UNFREEZE_AND_LAUNCH" />
|
|
<action android:name="net.typeblog.shelter.action.PUBLIC_FREEZE_ALL" />
|
|
<action android:name="net.typeblog.shelter.action.FREEZE_ALL_IN_LIST" />
|
|
<!-- We need two of these to avoid being prompted with an action chooser dialog -->
|
|
<!-- When the intent is actually already forwarded to work profile -->
|
|
<action android:name="net.typeblog.shelter.action.START_FILE_SHUTTLE" />
|
|
<action android:name="net.typeblog.shelter.action.START_FILE_SHUTTLE_2" />
|
|
<action android:name="net.typeblog.shelter.action.SYNCHRONIZE_PREFERENCE" />
|
|
<action android:name="net.typeblog.shelter.action.PACKAGEINSTALLER_CALLBACK" />
|
|
<category android:name="android.intent.category.DEFAULT" />
|
|
</intent-filter>
|
|
</activity>
|
|
|
|
<!-- Activity to forward ACTION_IMAGE_CAPTURE as ACTION_OPEN_DOCUMENT -->
|
|
<activity android:name=".ui.CameraProxyActivity"
|
|
android:excludeFromRecents="true"
|
|
android:theme="@android:style/Theme.Translucent.NoTitleBar"
|
|
android:label="@string/camera_proxy_activity">
|
|
<intent-filter>
|
|
<action android:name="android.media.action.IMAGE_CAPTURE" />
|
|
<category android:name="android.intent.category.DEFAULT" />
|
|
</intent-filter>
|
|
</activity>
|
|
|
|
<!-- Implementation of the device policy controller -->
|
|
<receiver android:name=".receivers.ShelterDeviceAdminReceiver"
|
|
android:label="@string/device_admin_label"
|
|
android:description="@string/device_admin_desc"
|
|
android:permission="android.permission.BIND_DEVICE_ADMIN">
|
|
<meta-data android:name="android.app.device_admin"
|
|
android:resource="@xml/device_admin" />
|
|
<intent-filter>
|
|
<action android:name="android.app.action.DEVICE_ADMIN_ENABLED" />
|
|
<action android:name="android.app.action.DEVICE_ADMIN_DISABLED" />
|
|
<action android:name="android.app.action.PROVISION_MANAGED_PROFILE" />
|
|
</intent-filter>
|
|
</receiver>
|
|
|
|
<!-- A FileProvider that proxies opened Fd from the other profile -->
|
|
<provider
|
|
android:name="net.typeblog.shelter.util.FileProviderProxy"
|
|
android:authorities="net.typeblog.shelter.files"
|
|
android:grantUriPermissions="true"
|
|
android:exported="false">
|
|
<meta-data
|
|
android:name="android.support.FILE_PROVIDER_PATHS"
|
|
android:resource="@xml/file_paths" />
|
|
</provider>
|
|
|
|
<!-- A DocumentsProvider that lists files in another profile -->
|
|
<provider
|
|
android:name="net.typeblog.shelter.util.CrossProfileDocumentsProvider"
|
|
android:authorities="net.typeblog.shelter.documents"
|
|
android:grantUriPermissions="true"
|
|
android:permission="android.permission.MANAGE_DOCUMENTS"
|
|
android:exported="true"
|
|
android:enabled="false">
|
|
<intent-filter>
|
|
<action android:name="android.content.action.DOCUMENTS_PROVIDER" />
|
|
</intent-filter>
|
|
</provider>
|
|
|
|
<!-- Core service running on both the main profile and the work profile -->
|
|
<!-- Actions like cloning / freezing apps will be performed by this service -->
|
|
<service android:name=".services.ShelterService"
|
|
android:exported="true"
|
|
android:permission="android.permission.BIND_DEVICE_ADMIN"/>
|
|
|
|
<!-- Service to forward file information between profiles -->
|
|
<service android:name=".services.FileShuttleService"
|
|
android:exported="true"
|
|
android:permission="android.permission.BIND_DEVICE_ADMIN" />
|
|
|
|
<!-- A hack service to ensure every ShelterService is killed when App is removed -->
|
|
<!-- from recent tasks -->
|
|
<service android:name=".services.KillerService" />
|
|
|
|
<!-- Service to freeze apps on screen lock -->
|
|
<service android:name=".services.FreezeService" />
|
|
</application>
|
|
|
|
</manifest> |