-
Notifications
You must be signed in to change notification settings - Fork 18
Initial Setup
TheBotBox edited this page May 14, 2020
·
2 revisions
First and foremost, in order to fetch a list of used applications, we need to secure USAGE ACCESS permission from the user.
For that, declare below line in the application's Manifest.xml
<uses-permission
android:name="android.permission.PACKAGE_USAGE_STATS"
tools:ignore="ProtectedPermissions" />
& to check, if the permission is granted or not, call
if (Monitor.hasUsagePermission())
else
Monitor.requestUsagePermission();