use of android.content.pm.PackageUserState in project android_frameworks_base by ResurrectionRemix.
the class PackageSettingBase method disableComponentLPw.
boolean disableComponentLPw(String componentClassName, int userId) {
PackageUserState state = modifyUserStateComponents(userId, true, false);
boolean changed = state.enabledComponents != null ? state.enabledComponents.remove(componentClassName) : false;
changed |= state.disabledComponents.add(componentClassName);
return changed;
}
use of android.content.pm.PackageUserState in project android_frameworks_base by ResurrectionRemix.
the class Settings method isEnabledAndMatchLPr.
boolean isEnabledAndMatchLPr(ComponentInfo componentInfo, int flags, int userId) {
final PackageSetting ps = mPackages.get(componentInfo.packageName);
if (ps == null)
return false;
final PackageUserState userState = ps.readUserState(userId);
return userState.isMatch(componentInfo, flags);
}
use of android.content.pm.PackageUserState in project android_frameworks_base by ResurrectionRemix.
the class PackageSettingBase method setUserState.
void setUserState(int userId, long ceDataInode, int enabled, boolean installed, boolean stopped, boolean notLaunched, boolean hidden, boolean suspended, String lastDisableAppCaller, ArraySet<String> enabledComponents, ArraySet<String> disabledComponents, boolean blockUninstall, int domainVerifState, int linkGeneration, String[] resourceDirs, ArraySet<String> protectedComponents, ArraySet<String> visibleComponents) {
PackageUserState state = modifyUserState(userId);
state.ceDataInode = ceDataInode;
state.enabled = enabled;
state.installed = installed;
state.stopped = stopped;
state.notLaunched = notLaunched;
state.hidden = hidden;
state.suspended = suspended;
state.lastDisableAppCaller = lastDisableAppCaller;
state.enabledComponents = enabledComponents;
state.disabledComponents = disabledComponents;
state.blockUninstall = blockUninstall;
state.domainVerificationStatus = domainVerifState;
state.appLinkGeneration = linkGeneration;
state.protectedComponents = protectedComponents;
state.visibleComponents = visibleComponents;
state.resourceDirs = resourceDirs;
}
use of android.content.pm.PackageUserState in project android_frameworks_base by DirtyUnicorns.
the class PackageSettingBase method setUserState.
void setUserState(int userId, long ceDataInode, int enabled, boolean installed, boolean stopped, boolean notLaunched, boolean hidden, boolean suspended, String lastDisableAppCaller, ArraySet<String> enabledComponents, ArraySet<String> disabledComponents, boolean blockUninstall, int domainVerifState, int linkGeneration, String[] resourceDirs) {
PackageUserState state = modifyUserState(userId);
state.ceDataInode = ceDataInode;
state.enabled = enabled;
state.installed = installed;
state.stopped = stopped;
state.notLaunched = notLaunched;
state.hidden = hidden;
state.suspended = suspended;
state.lastDisableAppCaller = lastDisableAppCaller;
state.enabledComponents = enabledComponents;
state.disabledComponents = disabledComponents;
state.blockUninstall = blockUninstall;
state.domainVerificationStatus = domainVerifState;
state.appLinkGeneration = linkGeneration;
state.resourceDirs = resourceDirs;
}
use of android.content.pm.PackageUserState in project android_frameworks_base by DirtyUnicorns.
the class PackageSettingBase method setEnabled.
void setEnabled(int state, int userId, String callingPackage) {
PackageUserState st = modifyUserState(userId);
st.enabled = state;
st.lastDisableAppCaller = callingPackage;
}
Aggregations