AutoStartPermissionHelper is a handy Android library developed by Abrar Hussain Beigh (aka Koshur Boii), designed to simplify the process of checking for and requesting auto-start permission on various Android devices. With this library, developers can seamlessly integrate auto-start permission handling into their Android applications, ensuring smooth user experiences across different device manufacturers.
AutoStartPermissionHelper is an Android library that assists in checking for and requesting auto-start permission on various Android devices. It provides a unified interface to handle auto-start permissions across different device manufacturers.
- Checks if auto-start permission is available on the device.
- Requests auto-start permission if available.
- Supports various device manufacturers including Xiaomi, Asus, Huawei, Samsung, and more.
-
Integrating the Library: Add the
AutoStartPermissionHelper
class to your Android project. -
Checking for Permission:
AutoStartPermissionHelper autoStartPermissionHelper = AutoStartPermissionHelper.getInstance(); // Check if the auto-start permission is available on the device boolean isAutoStartPermissionAvailable = autoStartPermissionHelper.isAutoStartPermissionAvailable(this, false); // If the permission is available, request it if (isAutoStartPermissionAvailable) { boolean granted = autoStartPermissionHelper.getAutoStartPermission(this, true, false); }