ricvalerio / foregroundappchecker

Foreground application detection library for android.
Apache License 2.0
191 stars 50 forks source link

packageName returns null after 1 hour #18

Open ArpitJ1610 opened 7 months ago

ArpitJ1610 commented 7 months ago

AppChecker mAppChecker = new AppChecker(); foreground_app_package_name = mAppChecker.getForegroundApp(mContext);

 I am  using the above code to get the foreground app name from service in background. The code works fine till 60 minutes and at 61 minutes it gives null value at foreground_app_package_name .