Shelter/app/src/main/aidl/net/typeblog/shelter/services/IShelterService.aidl
Peter Cai f35f125c7d
fix: request system alert permission for File Shuttle
* I cannot think of a proper way to start File Shuttle services without
  hitting background activity limitations. Let's just request for system
  alert window permission.
* This is pretty dirty, and could mask other bugs that may happen when
  this is not enabled. I don't want to make this permission mandatory
  for Shelter, so always remember to test without this enabled.
* This won't work on Android Go, though.
2020-09-08 20:51:51 +08:00

30 lines
1.3 KiB
Plaintext

// IShelterService.aidl
package net.typeblog.shelter.services;
import android.content.pm.ApplicationInfo;
import net.typeblog.shelter.services.IAppInstallCallback;
import net.typeblog.shelter.services.IGetAppsCallback;
import net.typeblog.shelter.services.ILoadIconCallback;
import net.typeblog.shelter.services.IStartActivityProxy;
import net.typeblog.shelter.util.ApplicationInfoWrapper;
import net.typeblog.shelter.util.UriForwardProxy;
interface IShelterService {
void ping();
void stopShelterService(boolean kill);
void getApps(IGetAppsCallback callback, boolean showAll);
void loadIcon(in ApplicationInfoWrapper info, ILoadIconCallback callback);
void installApp(in ApplicationInfoWrapper app, IAppInstallCallback callback);
void installApk(in UriForwardProxy uri, IAppInstallCallback callback);
void uninstallApp(in ApplicationInfoWrapper app, IAppInstallCallback callback);
void freezeApp(in ApplicationInfoWrapper app);
void unfreezeApp(in ApplicationInfoWrapper app);
boolean hasUsageStatsPermission();
boolean hasSystemAlertPermission();
boolean hasAllFileAccessPermission();
List<String> getCrossProfileWidgetProviders();
boolean setCrossProfileWidgetProviderEnabled(String pkgName, boolean enabled);
void setStartActivityProxy(in IStartActivityProxy proxy);
}