Merge "Added OWNERS file to am package." into pi-dev
diff --git a/api/removed.txt b/api/removed.txt
index 833d8ec..f35348e 100644
--- a/api/removed.txt
+++ b/api/removed.txt
@@ -321,14 +321,6 @@
public static abstract class NetworkBadging.Badging implements java.lang.annotation.Annotation {
}
- public class NetworkRequest implements android.os.Parcelable {
- method public boolean hasUnwantedCapability(int);
- }
-
- public static class NetworkRequest.Builder {
- method public android.net.NetworkRequest.Builder addUnwantedCapability(int);
- }
-
public class SSLCertificateSocketFactory extends javax.net.ssl.SSLSocketFactory {
method public static deprecated org.apache.http.conn.ssl.SSLSocketFactory getHttpSocketFactory(int, android.net.SSLSessionCache);
}
diff --git a/config/hiddenapi-light-greylist.txt b/config/hiddenapi-light-greylist.txt
index 23b4939..1fb940a 100644
--- a/config/hiddenapi-light-greylist.txt
+++ b/config/hiddenapi-light-greylist.txt
@@ -1,7 +1,27 @@
Landroid/accounts/AccountManager;->mContext:Landroid/content/Context;
+Landroid/accounts/IAccountAuthenticator$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/accounts/IAccountAuthenticator$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/accounts/IAccountAuthenticator$Stub;->asInterface(Landroid/os/IBinder;)Landroid/accounts/IAccountAuthenticator;
+Landroid/accounts/IAccountAuthenticator;->addAccount(Landroid/accounts/IAccountAuthenticatorResponse;Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Landroid/os/Bundle;)V
+Landroid/accounts/IAccountAuthenticator;->confirmCredentials(Landroid/accounts/IAccountAuthenticatorResponse;Landroid/accounts/Account;Landroid/os/Bundle;)V
+Landroid/accounts/IAccountAuthenticator;->editProperties(Landroid/accounts/IAccountAuthenticatorResponse;Ljava/lang/String;)V
+Landroid/accounts/IAccountAuthenticator;->getAccountRemovalAllowed(Landroid/accounts/IAccountAuthenticatorResponse;Landroid/accounts/Account;)V
+Landroid/accounts/IAccountAuthenticator;->getAuthToken(Landroid/accounts/IAccountAuthenticatorResponse;Landroid/accounts/Account;Ljava/lang/String;Landroid/os/Bundle;)V
+Landroid/accounts/IAccountAuthenticator;->getAuthTokenLabel(Landroid/accounts/IAccountAuthenticatorResponse;Ljava/lang/String;)V
+Landroid/accounts/IAccountAuthenticator;->hasFeatures(Landroid/accounts/IAccountAuthenticatorResponse;Landroid/accounts/Account;[Ljava/lang/String;)V
+Landroid/accounts/IAccountAuthenticator;->updateCredentials(Landroid/accounts/IAccountAuthenticatorResponse;Landroid/accounts/Account;Ljava/lang/String;Landroid/os/Bundle;)V
+Landroid/accounts/IAccountAuthenticatorResponse$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/accounts/IAccountAuthenticatorResponse$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Landroid/accounts/IAccountAuthenticatorResponse$Stub;-><init>()V
+Landroid/accounts/IAccountAuthenticatorResponse$Stub;->asInterface(Landroid/os/IBinder;)Landroid/accounts/IAccountAuthenticatorResponse;
Landroid/accounts/IAccountManager$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/accounts/IAccountManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/accounts/IAccountManager;
+Landroid/accounts/IAccountManagerResponse$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/accounts/IAccountManagerResponse$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/accounts/IAccountManagerResponse$Stub;-><init>()V
+Landroid/accounts/IAccountManagerResponse$Stub;->asInterface(Landroid/os/IBinder;)Landroid/accounts/IAccountManagerResponse;
+Landroid/accounts/IAccountManagerResponse;->onError(ILjava/lang/String;)V
+Landroid/accounts/IAccountManagerResponse;->onResult(Landroid/os/Bundle;)V
Landroid/animation/LayoutTransition;->cancel()V
Landroid/animation/LayoutTransition;->cancel(I)V
Landroid/animation/ValueAnimator;->animateValue(F)V
@@ -301,12 +321,31 @@
Landroid/app/ISearchManager$Stub$Proxy;->getGlobalSearchActivity()Landroid/content/ComponentName;
Landroid/app/ISearchManager$Stub$Proxy;->getWebSearchActivity()Landroid/content/ComponentName;
Landroid/app/ISearchManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/app/ISearchManager;
+Landroid/app/IServiceConnection$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/app/IServiceConnection$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/app/IServiceConnection$Stub;-><init>()V
Landroid/app/IServiceConnection$Stub;->asInterface(Landroid/os/IBinder;)Landroid/app/IServiceConnection;
+Landroid/app/IStopUserCallback$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/app/IStopUserCallback$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/app/IStopUserCallback$Stub;-><init>()V
Landroid/app/IStopUserCallback;->userStopped(I)V
Landroid/app/IUiModeManager$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/app/IWallpaperManager;->getWallpaper(Ljava/lang/String;Landroid/app/IWallpaperManagerCallback;ILandroid/os/Bundle;I)Landroid/os/ParcelFileDescriptor;
+Landroid/app/job/IJobCallback$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/app/job/IJobCallback$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/app/job/IJobCallback$Stub;-><init>()V
+Landroid/app/job/IJobCallback$Stub;->asInterface(Landroid/os/IBinder;)Landroid/app/job/IJobCallback;
+Landroid/app/job/IJobCallback;->acknowledgeStartMessage(IZ)V
+Landroid/app/job/IJobCallback;->acknowledgeStopMessage(IZ)V
+Landroid/app/job/IJobCallback;->jobFinished(IZ)V
Landroid/app/job/IJobScheduler$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/app/job/IJobScheduler$Stub;->asInterface(Landroid/os/IBinder;)Landroid/app/job/IJobScheduler;
+Landroid/app/job/IJobService$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/app/job/IJobService$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/app/job/IJobService$Stub;-><init>()V
+Landroid/app/job/IJobService$Stub;->asInterface(Landroid/os/IBinder;)Landroid/app/job/IJobService;
+Landroid/app/job/IJobService;->startJob(Landroid/app/job/JobParameters;)V
+Landroid/app/job/IJobService;->stopJob(Landroid/app/job/JobParameters;)V
Landroid/app/LoadedApk;->getAssets()Landroid/content/res/AssetManager;
Landroid/app/LoadedApk;->getClassLoader()Ljava/lang/ClassLoader;
Landroid/app/LoadedApk;->getCompatibilityInfo()Landroid/content/res/CompatibilityInfo;
@@ -363,6 +402,7 @@
Landroid/app/ResourcesManager;->appendLibAssetForMainAssetPath(Ljava/lang/String;Ljava/lang/String;)V
Landroid/app/ResourcesManager;->getInstance()Landroid/app/ResourcesManager;
Landroid/app/ResourcesManager;->mActivityResourceReferences:Ljava/util/WeakHashMap;
+Landroid/app/ResourcesManager;->mResConfiguration:Landroid/content/res/Configuration;
Landroid/app/ResourcesManager;->mResourceImpls:Landroid/util/ArrayMap;
Landroid/app/ResourcesManager;->mResourceReferences:Ljava/util/ArrayList;
Landroid/app/Service;->attach(Landroid/content/Context;Landroid/app/ActivityThread;Ljava/lang/String;Landroid/os/IBinder;Landroid/app/Application;Ljava/lang/Object;)V
@@ -571,11 +611,21 @@
Landroid/content/IContentService;->cancelSync(Landroid/accounts/Account;Ljava/lang/String;Landroid/content/ComponentName;)V
Landroid/content/IContentService;->getMasterSyncAutomatically()Z
Landroid/content/IContentService;->setMasterSyncAutomatically(Z)V
+Landroid/content/IIntentReceiver$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/IIntentReceiver$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/IIntentReceiver$Stub;-><init>()V
Landroid/content/Intent;->ACTION_ALARM_CHANGED:Ljava/lang/String;
Landroid/content/Intent;->mExtras:Landroid/os/Bundle;
Landroid/content/Intent;->putExtra(Ljava/lang/String;Landroid/os/IBinder;)Landroid/content/Intent;
Landroid/content/Intent;->toInsecureString()Ljava/lang/String;
Landroid/content/IntentFilter;->mActions:Ljava/util/ArrayList;
+Landroid/content/ISyncAdapter$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/ISyncAdapter$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/ISyncContext$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/ISyncContext$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/ISyncContext$Stub;->asInterface(Landroid/os/IBinder;)Landroid/content/ISyncContext;
+Landroid/content/ISyncStatusObserver$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/ISyncStatusObserver$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Landroid/content/pm/ActivityInfo;->resizeMode:I
Landroid/content/pm/ActivityInfo;->supportsPictureInPicture()Z
Landroid/content/pm/ApplicationInfo;->enabledSetting:I
@@ -590,7 +640,28 @@
Landroid/content/pm/ApplicationInfo;->secondaryNativeLibraryDir:Ljava/lang/String;
Landroid/content/pm/ApplicationInfo;->versionCode:I
Landroid/content/pm/ComponentInfo;->getComponentName()Landroid/content/ComponentName;
+Landroid/content/pm/IPackageDataObserver$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageDataObserver$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Landroid/content/pm/IPackageDataObserver$Stub;->asInterface(Landroid/os/IBinder;)Landroid/content/pm/IPackageDataObserver;
+Landroid/content/pm/IPackageDeleteObserver2$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageDeleteObserver2$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/pm/IPackageDeleteObserver2;->onPackageDeleted(Ljava/lang/String;ILjava/lang/String;)V
+Landroid/content/pm/IPackageInstallerCallback$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageInstallerCallback$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/pm/IPackageInstallerCallback$Stub;->asInterface(Landroid/os/IBinder;)Landroid/content/pm/IPackageInstallerCallback;
+Landroid/content/pm/IPackageInstallerCallback;->onSessionActiveChanged(IZ)V
+Landroid/content/pm/IPackageInstallerCallback;->onSessionBadgingChanged(I)V
+Landroid/content/pm/IPackageInstallerCallback;->onSessionCreated(I)V
+Landroid/content/pm/IPackageInstallerCallback;->onSessionFinished(IZ)V
+Landroid/content/pm/IPackageInstallerCallback;->onSessionProgressChanged(IF)V
+Landroid/content/pm/IPackageInstallerSession$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageInstallerSession$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/pm/IPackageInstallerSession$Stub;-><init>()V
+Landroid/content/pm/IPackageInstallerSession$Stub;->asInterface(Landroid/os/IBinder;)Landroid/content/pm/IPackageInstallerSession;
+Landroid/content/pm/IPackageInstallObserver2$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageInstallObserver2$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/content/pm/IPackageInstallObserver2$Stub;-><init>()V
+Landroid/content/pm/IPackageInstallObserver2;->onPackageInstalled(Ljava/lang/String;ILjava/lang/String;Landroid/os/Bundle;)V
Landroid/content/pm/IPackageManager$Stub$Proxy;->getInstalledPackages(II)Landroid/content/pm/ParceledListSlice;
Landroid/content/pm/IPackageManager$Stub$Proxy;->getPackageInfo(Ljava/lang/String;II)Landroid/content/pm/PackageInfo;
Landroid/content/pm/IPackageManager$Stub$Proxy;->getPackagesForUid(I)[Ljava/lang/String;
@@ -612,6 +683,8 @@
Landroid/content/pm/IPackageManager;->setLastChosenActivity(Landroid/content/Intent;Ljava/lang/String;ILandroid/content/IntentFilter;ILandroid/content/ComponentName;)V
Landroid/content/pm/IPackageMoveObserver$Stub;-><init>()V
Landroid/content/pm/IPackageMoveObserver$Stub;->asInterface(Landroid/os/IBinder;)Landroid/content/pm/IPackageMoveObserver;
+Landroid/content/pm/IPackageStatsObserver$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/content/pm/IPackageStatsObserver$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Landroid/content/pm/IPackageStatsObserver$Stub;-><init>()V
Landroid/content/pm/IShortcutService$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/content/pm/LauncherActivityInfo;->mActivityInfo:Landroid/content/pm/ActivityInfo;
@@ -625,6 +698,7 @@
Landroid/content/pm/PackageManager;->freeStorageAndNotify(JLandroid/content/pm/IPackageDataObserver;)V
Landroid/content/pm/PackageManager;->freeStorageAndNotify(Ljava/lang/String;JLandroid/content/pm/IPackageDataObserver;)V
Landroid/content/pm/PackageManager;->getApplicationInfoAsUser(Ljava/lang/String;II)Landroid/content/pm/ApplicationInfo;
+Landroid/content/pm/PackageManager;->getHomeActivities(Ljava/util/List;)Landroid/content/ComponentName;
Landroid/content/pm/PackageManager;->getPackageCandidateVolumes(Landroid/content/pm/ApplicationInfo;)Ljava/util/List;
Landroid/content/pm/PackageManager;->getPackageInfoAsUser(Ljava/lang/String;II)Landroid/content/pm/PackageInfo;
Landroid/content/pm/PackageManager;->getPackageSizeInfo(Ljava/lang/String;Landroid/content/pm/IPackageStatsObserver;)V
@@ -637,6 +711,7 @@
Landroid/content/pm/PackageParser$Component;->className:Ljava/lang/String;
Landroid/content/pm/PackageParser$Component;->getComponentName()Landroid/content/ComponentName;
Landroid/content/pm/PackageParser$Component;->intents:Ljava/util/ArrayList;
+Landroid/content/pm/PackageParser$Component;->metaData:Landroid/os/Bundle;
Landroid/content/pm/PackageParser$Instrumentation;->info:Landroid/content/pm/InstrumentationInfo;
Landroid/content/pm/PackageParser$IntentInfo;-><init>()V
Landroid/content/pm/PackageParser$IntentInfo;->banner:I
@@ -647,8 +722,12 @@
Landroid/content/pm/PackageParser$IntentInfo;->nonLocalizedLabel:Ljava/lang/CharSequence;
Landroid/content/pm/PackageParser$Package;->activities:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->applicationInfo:Landroid/content/pm/ApplicationInfo;
+Landroid/content/pm/PackageParser$Package;->configPreferences:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->instrumentation:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->mAppMetaData:Landroid/os/Bundle;
+Landroid/content/pm/PackageParser$Package;->mPreferredOrder:I
+Landroid/content/pm/PackageParser$Package;->mSharedUserId:Ljava/lang/String;
+Landroid/content/pm/PackageParser$Package;->mSharedUserLabel:I
Landroid/content/pm/PackageParser$Package;->mVersionCode:I
Landroid/content/pm/PackageParser$Package;->mVersionName:Ljava/lang/String;
Landroid/content/pm/PackageParser$Package;->packageName:Ljava/lang/String;
@@ -656,8 +735,10 @@
Landroid/content/pm/PackageParser$Package;->permissions:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->providers:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->receivers:Ljava/util/ArrayList;
+Landroid/content/pm/PackageParser$Package;->reqFeatures:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->requestedPermissions:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Package;->services:Ljava/util/ArrayList;
+Landroid/content/pm/PackageParser$Package;->usesLibraries:Ljava/util/ArrayList;
Landroid/content/pm/PackageParser$Provider;->info:Landroid/content/pm/ProviderInfo;
Landroid/content/pm/PackageParser$ProviderIntentInfo;->provider:Landroid/content/pm/PackageParser$Provider;
Landroid/content/pm/PackageParser$Service;->info:Landroid/content/pm/ServiceInfo;
@@ -766,7 +847,19 @@
Landroid/content/res/XmlBlock;->newParser()Landroid/content/res/XmlResourceParser;
Landroid/content/SearchRecentSuggestionsProvider;->mSuggestionProjection:[Ljava/lang/String;
Landroid/content/SyncContext;->setStatusText(Ljava/lang/String;)V
+Landroid/content/SyncStatusInfo;-><init>(Landroid/os/Parcel;)V
+Landroid/content/SyncStatusInfo;->authorityId:I
+Landroid/content/SyncStatusInfo;->CREATOR:Landroid/os/Parcelable$Creator;
+Landroid/content/SyncStatusInfo;->ensurePeriodicSyncTimeSize(I)V
+Landroid/content/SyncStatusInfo;->initialFailureTime:J
+Landroid/content/SyncStatusInfo;->initialize:Z
+Landroid/content/SyncStatusInfo;->lastFailureMesg:Ljava/lang/String;
+Landroid/content/SyncStatusInfo;->lastFailureSource:I
+Landroid/content/SyncStatusInfo;->lastFailureTime:J
+Landroid/content/SyncStatusInfo;->lastSuccessSource:I
Landroid/content/SyncStatusInfo;->lastSuccessTime:J
+Landroid/content/SyncStatusInfo;->pending:Z
+Landroid/content/SyncStatusInfo;->periodicSyncTimes:Ljava/util/ArrayList;
Landroid/content/UriMatcher;->mChildren:Ljava/util/ArrayList;
Landroid/content/UriMatcher;->mText:Ljava/lang/String;
Landroid/database/AbstractCursor;->mExtras:Landroid/os/Bundle;
@@ -991,6 +1084,7 @@
Landroid/hardware/camera2/utils/TypeReference;->createSpecializedTypeReference(Ljava/lang/reflect/Type;)Landroid/hardware/camera2/utils/TypeReference;
Landroid/hardware/Camera;->addCallbackBuffer([BI)V
Landroid/hardware/Camera;->mNativeContext:J
+Landroid/hardware/Camera;->native_setup(Ljava/lang/Object;IILjava/lang/String;)I
Landroid/hardware/Camera;->openLegacy(II)Landroid/hardware/Camera;
Landroid/hardware/Camera;->postEventFromNative(Ljava/lang/Object;IIILjava/lang/Object;)V
Landroid/hardware/display/WifiDisplayStatus;->mActiveDisplay:Landroid/hardware/display/WifiDisplay;
@@ -1086,6 +1180,9 @@
Landroid/location/GeocoderParams;->getLocale()Ljava/util/Locale;
Landroid/location/IGeocodeProvider$Stub;-><init>()V
Landroid/location/IGeofenceProvider$Stub;-><init>()V
+Landroid/location/ILocationListener$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/location/ILocationListener$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/location/ILocationListener;->onLocationChanged(Landroid/location/Location;)V
Landroid/location/ILocationManager$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/location/ILocationManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/location/ILocationManager;
Landroid/location/LocationManager;->mService:Landroid/location/ILocationManager;
@@ -1248,6 +1345,7 @@
Landroid/media/RemoteDisplayState;-><init>()V
Landroid/media/RemoteDisplayState;->displays:Ljava/util/ArrayList;
Landroid/media/RingtoneManager;->getRingtone(Landroid/content/Context;Landroid/net/Uri;I)Landroid/media/Ringtone;
+Landroid/media/session/MediaSession;->getCallingPackage()Ljava/lang/String;
Landroid/media/session/MediaSession;->mCallback:Landroid/media/session/MediaSession$CallbackMessageHandler;
Landroid/media/session/MediaSessionLegacyHelper;->getHelper(Landroid/content/Context;)Landroid/media/session/MediaSessionLegacyHelper;
Landroid/media/soundtrigger/SoundTriggerDetector$EventPayload;->getCaptureSession()Ljava/lang/Integer;
@@ -1312,6 +1410,7 @@
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetherableIfaces()[Ljava/lang/String;
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetherableUsbRegexs()[Ljava/lang/String;
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetheredIfaces()[Ljava/lang/String;
+Landroid/net/IConnectivityManager$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Landroid/net/IConnectivityManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/net/IConnectivityManager;
Landroid/net/IConnectivityManager;->getActiveLinkProperties()Landroid/net/LinkProperties;
Landroid/net/IConnectivityManager;->getActiveNetworkInfo()Landroid/net/NetworkInfo;
@@ -1379,6 +1478,9 @@
Landroid/net/Uri;-><init>()V
Landroid/net/wifi/IWifiManager$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Landroid/net/wifi/IWifiManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/net/wifi/IWifiManager;
+Landroid/net/wifi/IWifiScanner$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
+Landroid/net/wifi/IWifiScanner$Stub$Proxy;->mRemote:Landroid/os/IBinder;
+Landroid/net/wifi/IWifiScanner$Stub;-><init>()V
Landroid/net/wifi/p2p/WifiP2pGroup;->getNetworkId()I
Landroid/net/wifi/p2p/WifiP2pGroup;->TEMPORARY_NET_ID:I
Landroid/net/wifi/p2p/WifiP2pGroupList;->getGroupList()Ljava/util/Collection;
@@ -1466,6 +1568,7 @@
Landroid/os/BatteryStats$Uid$Proc;->countExcessivePowers()I
Landroid/os/BatteryStats$Uid$Proc;->getExcessivePower(I)Landroid/os/BatteryStats$Uid$Proc$ExcessivePower;
Landroid/os/BatteryStats$Uid$Proc;->getForegroundTime(I)J
+Landroid/os/BatteryStats$Uid$Proc;->getStarts(I)I
Landroid/os/BatteryStats$Uid$Proc;->getSystemTime(I)J
Landroid/os/BatteryStats$Uid$Proc;->getUserTime(I)J
Landroid/os/BatteryStats$Uid$Sensor;->getHandle()I
@@ -1613,7 +1716,9 @@
Landroid/os/Process;->readProcFile(Ljava/lang/String;[I[Ljava/lang/String;[J[F)Z
Landroid/os/Process;->readProcLines(Ljava/lang/String;[Ljava/lang/String;[J)V
Landroid/os/Process;->setArgV0(Ljava/lang/String;)V
+Landroid/os/SELinux;->checkSELinuxAccess(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Z
Landroid/os/SELinux;->getFileContext(Ljava/lang/String;)Ljava/lang/String;
+Landroid/os/SELinux;->getPidContext(I)Ljava/lang/String;
Landroid/os/SELinux;->isSELinuxEnabled()Z
Landroid/os/SELinux;->isSELinuxEnforced()Z
Landroid/os/ServiceManager;-><init>()V
@@ -2039,6 +2144,8 @@
Landroid/service/media/IMediaBrowserServiceCallbacks;->onLoadChildrenWithOptions(Ljava/lang/String;Landroid/content/pm/ParceledListSlice;Landroid/os/Bundle;)V
Landroid/service/media/MediaBrowserService$Result;->mFlags:I
Landroid/service/media/MediaBrowserService;->KEY_MEDIA_ITEM:Ljava/lang/String;
+Landroid/service/notification/NotificationListenerService;->isBound()Z
+Landroid/service/notification/NotificationListenerService;->mHandler:Landroid/os/Handler;
Landroid/service/notification/NotificationListenerService;->registerAsSystemService(Landroid/content/Context;Landroid/content/ComponentName;I)V
Landroid/service/notification/NotificationListenerService;->unregisterAsSystemService()V
Landroid/service/notification/StatusBarNotification;->getUid()I
@@ -2707,6 +2814,7 @@
Landroid/webkit/WebView;->sEnforceThreadChecking:Z
Landroid/webkit/WebViewClient;->onUnhandledInputEvent(Landroid/webkit/WebView;Landroid/view/InputEvent;)V
Landroid/webkit/WebViewFactory;->getProvider()Landroid/webkit/WebViewFactoryProvider;
+Landroid/webkit/WebViewFactory;->getUpdateService()Landroid/webkit/IWebViewUpdateService;
Landroid/webkit/WebViewFactory;->getWebViewContextAndSetProvider()Landroid/content/Context;
Landroid/webkit/WebViewFactory;->sPackageInfo:Landroid/content/pm/PackageInfo;
Landroid/webkit/WebViewFactory;->sProviderInstance:Landroid/webkit/WebViewFactoryProvider;
@@ -2764,6 +2872,7 @@
Landroid/widget/AutoCompleteTextView;->setDropDownAlwaysVisible(Z)V
Landroid/widget/AutoCompleteTextView;->setForceIgnoreOutsideTouch(Z)V
Landroid/widget/BaseAdapter;->mDataSetObservable:Landroid/database/DataSetObservable;
+Landroid/widget/CompoundButton;->mBroadcasting:Z
Landroid/widget/CompoundButton;->mButtonDrawable:Landroid/graphics/drawable/Drawable;
Landroid/widget/CompoundButton;->mOnCheckedChangeListener:Landroid/widget/CompoundButton$OnCheckedChangeListener;
Landroid/widget/CursorAdapter;->mChangeObserver:Landroid/widget/CursorAdapter$ChangeObserver;
@@ -3293,6 +3402,7 @@
Lcom/android/internal/telephony/ISub$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Lcom/android/internal/telephony/ITelephony$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
Lcom/android/internal/telephony/ITelephony$Stub$Proxy;->endCall()Z
+Lcom/android/internal/telephony/ITelephony$Stub$Proxy;->mRemote:Landroid/os/IBinder;
Lcom/android/internal/telephony/ITelephony$Stub;->asInterface(Landroid/os/IBinder;)Lcom/android/internal/telephony/ITelephony;
Lcom/android/internal/telephony/ITelephony$Stub;->TRANSACTION_call:I
Lcom/android/internal/telephony/ITelephony$Stub;->TRANSACTION_endCall:I
@@ -3510,6 +3620,7 @@
Ljava/lang/ref/Reference;->referent:Ljava/lang/Object;
Ljava/lang/ref/ReferenceQueue;->add(Ljava/lang/ref/Reference;)V
Ljava/lang/reflect/Executable;->artMethod:J
+Ljava/lang/reflect/Field;->accessFlags:I
Ljava/lang/reflect/Parameter;-><init>(Ljava/lang/String;ILjava/lang/reflect/Executable;I)V
Ljava/lang/reflect/Proxy;->invoke(Ljava/lang/reflect/Proxy;Ljava/lang/reflect/Method;[Ljava/lang/Object;)Ljava/lang/Object;
Ljava/lang/Runtime;->load(Ljava/lang/String;Ljava/lang/ClassLoader;)V
diff --git a/core/java/android/net/NetworkRequest.java b/core/java/android/net/NetworkRequest.java
index bd4a27c..227a4cb 100644
--- a/core/java/android/net/NetworkRequest.java
+++ b/core/java/android/net/NetworkRequest.java
@@ -228,7 +228,7 @@
* @param capability The capability to add to unwanted capability list.
* @return The builder to facilitate chaining.
*
- * @removed
+ * @hide
*/
public Builder addUnwantedCapability(@NetworkCapabilities.NetCapability int capability) {
mNetworkCapabilities.addUnwantedCapability(capability);
@@ -436,7 +436,7 @@
/**
* @see Builder#addUnwantedCapability(int)
*
- * @removed
+ * @hide
*/
public boolean hasUnwantedCapability(@NetCapability int capability) {
return networkCapabilities.hasUnwantedCapability(capability);
diff --git a/graphics/java/android/graphics/drawable/NinePatchDrawable.java b/graphics/java/android/graphics/drawable/NinePatchDrawable.java
index 66f2a31..5ff49ab 100644
--- a/graphics/java/android/graphics/drawable/NinePatchDrawable.java
+++ b/graphics/java/android/graphics/drawable/NinePatchDrawable.java
@@ -692,13 +692,13 @@
mPadding = new Rect();
}
mPadding.left = Drawable.scaleFromDensity(
- sourcePadding.left, sourceDensity, targetDensity, false);
+ sourcePadding.left, sourceDensity, targetDensity, true);
mPadding.top = Drawable.scaleFromDensity(
- sourcePadding.top, sourceDensity, targetDensity, false);
+ sourcePadding.top, sourceDensity, targetDensity, true);
mPadding.right = Drawable.scaleFromDensity(
- sourcePadding.right, sourceDensity, targetDensity, false);
+ sourcePadding.right, sourceDensity, targetDensity, true);
mPadding.bottom = Drawable.scaleFromDensity(
- sourcePadding.bottom, sourceDensity, targetDensity, false);
+ sourcePadding.bottom, sourceDensity, targetDensity, true);
} else {
mPadding = null;
}
diff --git a/libs/hwui/hwui/Bitmap.cpp b/libs/hwui/hwui/Bitmap.cpp
index 795ec5b..263d249 100644
--- a/libs/hwui/hwui/Bitmap.cpp
+++ b/libs/hwui/hwui/Bitmap.cpp
@@ -296,6 +296,11 @@
outBitmap->allocPixels(info());
}
uirenderer::renderthread::RenderProxy::copyGraphicBufferInto(graphicBuffer(), outBitmap);
+ if (mInfo.colorSpace()) {
+ sk_sp<SkPixelRef> pixelRef = sk_ref_sp(outBitmap->pixelRef());
+ outBitmap->setInfo(mInfo);
+ outBitmap->setPixelRef(std::move(pixelRef), 0, 0);
+ }
return;
}
outBitmap->setInfo(mInfo, rowBytes());
diff --git a/packages/SystemUI/res/values/config_car.xml b/packages/SystemUI/res/values/config_car.xml
index db829f2..2c549bc 100644
--- a/packages/SystemUI/res/values/config_car.xml
+++ b/packages/SystemUI/res/values/config_car.xml
@@ -27,4 +27,5 @@
<bool name="config_enableLeftNavigationBar">false</bool>
<bool name="config_enableRightNavigationBar">false</bool>
<bool name="config_enableBottomNavigationBar">true</bool>
+ <bool name="config_hideNavWhenKeyguardBouncerShown">true</bool>
</resources>
diff --git a/packages/SystemUI/res/values/ids_car.xml b/packages/SystemUI/res/values/ids_car.xml
new file mode 100644
index 0000000..27ed2e2
--- /dev/null
+++ b/packages/SystemUI/res/values/ids_car.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2018 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License
+ -->
+
+<resources>
+ <!-- Values used for finding elements on the system ui nav bars -->
+ <item type="id" name="lock_screen_nav_buttons"/>
+ <item type="id" name="nav_buttons"/>
+</resources>
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/car/CarSystemUIFactory.java b/packages/SystemUI/src/com/android/systemui/car/CarSystemUIFactory.java
index 9459ce1..cc9fec0 100644
--- a/packages/SystemUI/src/com/android/systemui/car/CarSystemUIFactory.java
+++ b/packages/SystemUI/src/com/android/systemui/car/CarSystemUIFactory.java
@@ -17,17 +17,29 @@
import android.content.Context;
import android.util.ArrayMap;
+import android.view.View;
+import com.android.internal.widget.LockPatternUtils;
+import com.android.keyguard.ViewMediatorCallback;
import com.android.systemui.Dependency.DependencyProvider;
import com.android.systemui.SystemUIFactory;
import com.android.systemui.statusbar.NotificationEntryManager;
import com.android.systemui.statusbar.car.CarFacetButtonController;
+import com.android.systemui.statusbar.car.CarStatusBar;
+import com.android.systemui.statusbar.car.CarStatusBarKeyguardViewManager;
import com.android.systemui.statusbar.car.hvac.HvacController;
+import com.android.systemui.statusbar.phone.StatusBarKeyguardViewManager;
/**
* Class factory to provide car specific SystemUI components.
*/
public class CarSystemUIFactory extends SystemUIFactory {
+
+ public StatusBarKeyguardViewManager createStatusBarKeyguardViewManager(Context context,
+ ViewMediatorCallback viewMediatorCallback, LockPatternUtils lockPatternUtils) {
+ return new CarStatusBarKeyguardViewManager(context, viewMediatorCallback, lockPatternUtils);
+ }
+
@Override
public void injectDependencies(ArrayMap<Object, DependencyProvider> providers,
Context context) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarFacetButtonController.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarFacetButtonController.java
index 8160f90..20986ad 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarFacetButtonController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarFacetButtonController.java
@@ -7,6 +7,7 @@
import android.content.pm.PackageManager;
import android.content.pm.ResolveInfo;
import android.view.Display;
+import android.view.View;
import java.util.HashMap;
import java.util.List;
@@ -73,36 +74,43 @@
*/
public void taskChanged(List<ActivityManager.StackInfo> stackInfoList) {
int displayId = getDisplayId();
+ ActivityManager.StackInfo validStackInfo = null;
for (ActivityManager.StackInfo stackInfo :stackInfoList) {
- // if the display id is known and does not match the stack we skip
- if (displayId != -1 && displayId != stackInfo.displayId ||
- stackInfo.topActivity == null) {
- continue;
- }
-
- if (mSelectedFacetButton != null) {
- mSelectedFacetButton.setSelected(false);
- }
-
- String packageName = stackInfo.topActivity.getPackageName();
- CarFacetButton facetButton = findFacetButtongByComponentName(stackInfo.topActivity);
- if (facetButton == null) {
- facetButton = mButtonsByPackage.get(packageName);
- }
-
- if (facetButton == null) {
- String category = getPackageCategory(packageName);
- if (category != null) {
- facetButton = mButtonsByCategory.get(category);
- }
- }
-
- if (facetButton != null) {
- facetButton.setSelected(true);
- mSelectedFacetButton = facetButton;
- return;
+ // If the display id is unknown or it matches the stack, it's valid for use
+ if ((displayId == -1 || displayId == stackInfo.displayId) &&
+ stackInfo.topActivity != null) {
+ validStackInfo = stackInfo;
+ break;
}
}
+
+ if (validStackInfo == null) {
+ // No stack was found that was on the same display as the facet buttons thus return
+ return;
+ }
+
+ if (mSelectedFacetButton != null) {
+ mSelectedFacetButton.setSelected(false);
+ }
+
+ String packageName = validStackInfo.topActivity.getPackageName();
+ CarFacetButton facetButton = findFacetButtongByComponentName(validStackInfo.topActivity);
+ if (facetButton == null) {
+ facetButton = mButtonsByPackage.get(packageName);
+ }
+
+ if (facetButton == null) {
+ String category = getPackageCategory(packageName);
+ if (category != null) {
+ facetButton = mButtonsByCategory.get(category);
+ }
+ }
+
+ if (facetButton != null && facetButton.getVisibility() == View.VISIBLE) {
+ facetButton.setSelected(true);
+ mSelectedFacetButton = facetButton;
+ }
+
}
private int getDisplayId() {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarNavigationBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarNavigationBarView.java
index b2cef16..9ed0929 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarNavigationBarView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarNavigationBarView.java
@@ -36,10 +36,11 @@
* in a linear layout.
*/
class CarNavigationBarView extends LinearLayout {
- private LinearLayout mNavButtons;
+ private View mNavButtons;
private AlphaOptimizedImageButton mNotificationsButton;
private CarStatusBar mCarStatusBar;
private Context mContext;
+ private View mLockScreenButtons;
public CarNavigationBarView(Context context, AttributeSet attrs) {
super(context, attrs);
@@ -49,6 +50,7 @@
@Override
public void onFinishInflate() {
mNavButtons = findViewById(R.id.nav_buttons);
+ mLockScreenButtons = findViewById(R.id.lock_screen_nav_buttons);
mNotificationsButton = findViewById(R.id.notifications);
if (mNotificationsButton != null) {
@@ -74,4 +76,28 @@
protected void onNotificationsClick(View v) {
mCarStatusBar.togglePanel();
}
+
+ /**
+ * If there are buttons declared in the layout they will be shown and the normal
+ * Nav buttons will be hidden.
+ */
+ public void showKeyguardButtons() {
+ if (mLockScreenButtons == null) {
+ return;
+ }
+ mLockScreenButtons.setVisibility(View.VISIBLE);
+ mNavButtons.setVisibility(View.GONE);
+ }
+
+ /**
+ * If there are buttons declared in the layout they will be hidden and the normal
+ * Nav buttons will be shown.
+ */
+ public void hideKeyguardButtons() {
+ if (mLockScreenButtons == null) {
+ return;
+ }
+ mNavButtons.setVisibility(View.VISIBLE);
+ mLockScreenButtons.setVisibility(View.GONE);
+ }
}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBar.java
index 9c60f5c..83021ca 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBar.java
@@ -141,6 +141,52 @@
buildNavBarContent();
}
+ /**
+ * Allows for showing or hiding just the navigation bars. This is indented to be used when
+ * the full screen user selector is shown.
+ */
+ void setNavBarVisibility(@View.Visibility int visibility) {
+ if (mNavigationBarWindow != null) {
+ mNavigationBarWindow.setVisibility(visibility);
+ }
+ if (mLeftNavigationBarWindow != null) {
+ mLeftNavigationBarWindow.setVisibility(visibility);
+ }
+ if (mRightNavigationBarWindow != null) {
+ mRightNavigationBarWindow.setVisibility(visibility);
+ }
+ }
+
+
+ @Override
+ public boolean hideKeyguard() {
+ boolean result = super.hideKeyguard();
+ if (mNavigationBarView != null) {
+ mNavigationBarView.hideKeyguardButtons();
+ }
+ if (mLeftNavigationBarView != null) {
+ mLeftNavigationBarView.hideKeyguardButtons();
+ }
+ if (mRightNavigationBarView != null) {
+ mRightNavigationBarView.hideKeyguardButtons();
+ }
+ return result;
+ }
+
+
+ @Override
+ public void showKeyguard() {
+ super.showKeyguard();
+ if (mNavigationBarView != null) {
+ mNavigationBarView.showKeyguardButtons();
+ }
+ if (mLeftNavigationBarView != null) {
+ mLeftNavigationBarView.showKeyguardButtons();
+ }
+ if (mRightNavigationBarView != null) {
+ mRightNavigationBarView.showKeyguardButtons();
+ }
+ }
@Override
public void destroy() {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBarKeyguardViewManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBarKeyguardViewManager.java
new file mode 100644
index 0000000..7a8d22b
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/CarStatusBarKeyguardViewManager.java
@@ -0,0 +1,31 @@
+package com.android.systemui.statusbar.car;
+
+import android.content.Context;
+import android.view.View;
+
+import com.android.internal.widget.LockPatternUtils;
+import com.android.keyguard.ViewMediatorCallback;
+import com.android.systemui.R;
+import com.android.systemui.statusbar.phone.StatusBarKeyguardViewManager;
+
+public class CarStatusBarKeyguardViewManager extends StatusBarKeyguardViewManager {
+
+ protected boolean mShouldHideNavBar;
+
+ public CarStatusBarKeyguardViewManager(Context context,
+ ViewMediatorCallback callback,
+ LockPatternUtils lockPatternUtils) {
+ super(context, callback, lockPatternUtils);
+ mShouldHideNavBar =context.getResources()
+ .getBoolean(R.bool.config_hideNavWhenKeyguardBouncerShown);
+ }
+
+ @Override
+ protected void updateNavigationBarVisibility(boolean navBarVisible) {
+ if(!mShouldHideNavBar) {
+ return;
+ }
+ CarStatusBar statusBar = (CarStatusBar) mStatusBar;
+ statusBar.setNavBarVisibility(navBarVisible ? View.VISIBLE : View.GONE);
+ }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureTextView.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureTextView.java
new file mode 100644
index 0000000..8143c13
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureTextView.java
@@ -0,0 +1,85 @@
+/*
+ * Copyright 2018 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.systemui.statusbar.car.hvac;
+
+import android.content.Context;
+import android.content.res.TypedArray;
+import android.util.AttributeSet;
+import android.widget.TextView;
+
+import com.android.systemui.Dependency;
+import com.android.systemui.R;
+
+/**
+ * Simple text display of HVAC properties, It is designed to show temperature and is configured in
+ * the XML.
+ * XML properties:
+ * hvacPropertyId - Example: CarHvacManager.ID_ZONED_TEMP_SETPOINT (16385)
+ * hvacAreaId - Example: VehicleSeat.SEAT_ROW_1_LEFT (1)
+ * hvacTempFormat - Example: "%.1f\u00B0" (1 decimal and the degree symbol)
+ *
+ * Note: It registers itself with {@link HvacController}
+ */
+public class TemperatureTextView extends TextView implements TemperatureView {
+
+ private final int mAreaId;
+ private final int mPropertyId;
+ private final String mTempFormat;
+
+ public TemperatureTextView(Context context, AttributeSet attrs) {
+ super(context, attrs);
+ TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.TemperatureView);
+ mAreaId = typedArray.getInt(R.styleable.TemperatureView_hvacAreaId,-1);
+ mPropertyId = typedArray.getInt(R.styleable.TemperatureView_hvacPropertyId, -1);
+ String format = typedArray.getString(R.styleable.TemperatureView_hvacTempFormat);
+ mTempFormat = (format == null) ? "%.1f\u00B0" : format;
+
+ // register with controller
+ HvacController hvacController = Dependency.get(HvacController.class);
+ hvacController.addHvacTextView(this);
+ }
+
+ /**
+ * Formats the float for display
+ * @param temp - The current temp or NaN
+ */
+ @Override
+ public void setTemp(float temp) {
+ if (Float.isNaN(temp)) {
+ setText("--");
+ return;
+ }
+ setText(String.format(mTempFormat, temp));
+ }
+
+ /**
+ * @return propertiyId Example: CarHvacManager.ID_ZONED_TEMP_SETPOINT (16385)
+ */
+ @Override
+ public int getPropertyId() {
+ return mPropertyId;
+ }
+
+ /**
+ * @return hvac AreaId - Example: VehicleSeat.SEAT_ROW_1_LEFT (1)
+ */
+ @Override
+ public int getAreaId() {
+ return mAreaId;
+ }
+}
+
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureView.java b/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureView.java
index 4049ec3..7651356 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/car/hvac/TemperatureView.java
@@ -16,67 +16,25 @@
package com.android.systemui.statusbar.car.hvac;
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.util.AttributeSet;
-import android.widget.TextView;
-
-import com.android.systemui.Dependency;
-import com.android.systemui.R;
-
/**
- * Simple text display of HVAC properties, It is designed to show temperature and is configured in
- * the XML.
- * XML properties:
- * hvacPropertyId - Example: CarHvacManager.ID_ZONED_TEMP_SETPOINT (16385)
- * hvacAreaId - Example: VehicleSeat.SEAT_ROW_1_LEFT (1)
- * hvacTempFormat - Example: "%.1f\u00B0" (1 decimal and the degree symbol)
- *
- * Note: It registers itself with {@link HvacController}
+ * Interface for Views that display temperature HVAC properties
*/
-public class TemperatureView extends TextView {
-
- private final int mAreaId;
- private final int mPropertyId;
- private final String mTempFormat;
-
- public TemperatureView(Context context, AttributeSet attrs) {
- super(context, attrs);
- TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.TemperatureView);
- mAreaId = typedArray.getInt(R.styleable.TemperatureView_hvacAreaId,-1);
- mPropertyId = typedArray.getInt(R.styleable.TemperatureView_hvacPropertyId, -1);
- String format = typedArray.getString(R.styleable.TemperatureView_hvacTempFormat);
- mTempFormat = (format == null) ? "%.1f\u00B0" : format;
-
- // register with controller
- HvacController hvacController = Dependency.get(HvacController.class);
- hvacController.addHvacTextView(this);
- }
-
+public interface TemperatureView {
/**
* Formats the float for display
+ *
* @param temp - The current temp or NaN
*/
- public void setTemp(float temp) {
- if (Float.isNaN(temp)) {
- setText("--");
- return;
- }
- setText(String.format(mTempFormat, temp));
- }
+ void setTemp(float temp);
+
/**
* @return propertiyId Example: CarHvacManager.ID_ZONED_TEMP_SETPOINT (16385)
*/
- public int getPropertyId() {
- return mPropertyId;
- }
+ int getPropertyId();
/**
* @return hvac AreaId - Example: VehicleSeat.SEAT_ROW_1_LEFT (1)
*/
- public int getAreaId() {
- return mAreaId;
- }
+ int getAreaId();
}
-
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
index e63a2e5..b517d11 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
@@ -586,20 +586,7 @@
boolean navBarVisible = isNavBarVisible();
boolean lastNavBarVisible = getLastNavBarVisible();
if (navBarVisible != lastNavBarVisible || mFirstUpdate) {
- if (mStatusBar.getNavigationBarView() != null) {
- if (navBarVisible) {
- long delay = getNavBarShowDelay();
- if (delay == 0) {
- mMakeNavigationBarVisibleRunnable.run();
- } else {
- mContainer.postOnAnimationDelayed(mMakeNavigationBarVisibleRunnable,
- delay);
- }
- } else {
- mContainer.removeCallbacks(mMakeNavigationBarVisibleRunnable);
- mStatusBar.getNavigationBarView().getRootView().setVisibility(View.GONE);
- }
- }
+ updateNavigationBarVisibility(navBarVisible);
}
if (bouncerShowing != mLastBouncerShowing || mFirstUpdate) {
@@ -626,6 +613,23 @@
mStatusBar.onKeyguardViewManagerStatesUpdated();
}
+ protected void updateNavigationBarVisibility(boolean navBarVisible) {
+ if (mStatusBar.getNavigationBarView() != null) {
+ if (navBarVisible) {
+ long delay = getNavBarShowDelay();
+ if (delay == 0) {
+ mMakeNavigationBarVisibleRunnable.run();
+ } else {
+ mContainer.postOnAnimationDelayed(mMakeNavigationBarVisibleRunnable,
+ delay);
+ }
+ } else {
+ mContainer.removeCallbacks(mMakeNavigationBarVisibleRunnable);
+ mStatusBar.getNavigationBarView().getRootView().setVisibility(View.GONE);
+ }
+ }
+ }
+
/**
* @return Whether the navigation bar should be made visible based on the current state.
*/
diff --git a/services/core/java/com/android/server/BluetoothManagerService.java b/services/core/java/com/android/server/BluetoothManagerService.java
index 8d10cfa..2c0e97e 100644
--- a/services/core/java/com/android/server/BluetoothManagerService.java
+++ b/services/core/java/com/android/server/BluetoothManagerService.java
@@ -285,6 +285,9 @@
try {
mBluetoothLock.readLock().lock();
if (mBluetooth != null) {
+ addActiveLog(
+ BluetoothProtoEnums.ENABLE_DISABLE_REASON_AIRPLANE_MODE,
+ mContext.getPackageName(), false);
mBluetooth.onBrEdrDown();
mEnable = false;
mEnableExternal = false;
@@ -677,6 +680,8 @@
try {
mBluetoothLock.readLock().lock();
if (mBluetooth != null) {
+ addActiveLog(BluetoothProtoEnums.ENABLE_DISABLE_REASON_APPLICATION_REQUEST,
+ mContext.getPackageName(), false);
mBluetooth.onBrEdrDown();
}
} catch (RemoteException e) {
diff --git a/services/core/java/com/android/server/TelephonyRegistry.java b/services/core/java/com/android/server/TelephonyRegistry.java
index 60d11d7..83fe976 100644
--- a/services/core/java/com/android/server/TelephonyRegistry.java
+++ b/services/core/java/com/android/server/TelephonyRegistry.java
@@ -1426,31 +1426,6 @@
}
}
- public void notifyOemHookRawEventForSubscriber(int subId, byte[] rawData) {
- if (!checkNotifyPermission("notifyOemHookRawEventForSubscriber")) {
- return;
- }
-
- synchronized (mRecords) {
- for (Record r : mRecords) {
- if (VDBG) {
- log("notifyOemHookRawEventForSubscriber: r=" + r + " subId=" + subId);
- }
- if ((r.matchPhoneStateListenerEvent(
- PhoneStateListener.LISTEN_OEM_HOOK_RAW_EVENT)) &&
- ((r.subId == subId) ||
- (r.subId == SubscriptionManager.DEFAULT_SUBSCRIPTION_ID))) {
- try {
- r.callback.onOemHookRawEvent(rawData);
- } catch (RemoteException ex) {
- mRemoveList.add(r.binder);
- }
- }
- }
- handleRemoveListLocked();
- }
- }
-
@Override
public void dump(FileDescriptor fd, PrintWriter writer, String[] args) {
final IndentingPrintWriter pw = new IndentingPrintWriter(writer, " ");
@@ -1718,11 +1693,6 @@
android.Manifest.permission.READ_PRECISE_PHONE_STATE, null);
}
- if ((events & PhoneStateListener.LISTEN_OEM_HOOK_RAW_EVENT) != 0) {
- mContext.enforceCallingOrSelfPermission(
- android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, null);
- }
-
return true;
}
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 6cd6a31..ae26c237 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -5306,7 +5306,8 @@
final long origId = Binder.clearCallingIdentity();
try {
synchronized (this) {
- mWindowManager.cancelRecentsAnimation(restoreHomeStackPosition
+ // Cancel the recents animation synchronously (do not hold the WM lock)
+ mWindowManager.cancelRecentsAnimationSynchronously(restoreHomeStackPosition
? REORDER_MOVE_TO_ORIGINAL_POSITION
: REORDER_KEEP_IN_PLACE, "cancelRecentsAnimation");
}
diff --git a/services/core/java/com/android/server/am/RecentsAnimation.java b/services/core/java/com/android/server/am/RecentsAnimation.java
index f2ed6a2..b14f5b6 100644
--- a/services/core/java/com/android/server/am/RecentsAnimation.java
+++ b/services/core/java/com/android/server/am/RecentsAnimation.java
@@ -179,8 +179,9 @@
targetActivity.mLaunchTaskBehind = true;
// Fetch all the surface controls and pass them to the client to get the animation
- // started
- mWindowManager.cancelRecentsAnimation(REORDER_MOVE_TO_ORIGINAL_POSITION,
+ // started. Cancel any existing recents animation running synchronously (do not hold the
+ // WM lock)
+ mWindowManager.cancelRecentsAnimationSynchronously(REORDER_MOVE_TO_ORIGINAL_POSITION,
"startRecentsActivity");
mWindowManager.initializeRecentsAnimation(mTargetActivityType, recentsAnimationRunner,
this, display.mDisplayId, mStackSupervisor.mRecentTasks.getRecentTaskIds());
@@ -200,12 +201,11 @@
}
}
- @Override
- public void onAnimationFinished(@RecentsAnimationController.ReorderMode int reorderMode) {
+ private void finishAnimation(@RecentsAnimationController.ReorderMode int reorderMode) {
synchronized (mService) {
if (DEBUG) Slog.d(TAG, "onAnimationFinished(): controller="
- + mWindowManager.getRecentsAnimationController()
- + " reorderMode=" + reorderMode);
+ + mWindowManager.getRecentsAnimationController()
+ + " reorderMode=" + reorderMode);
// Cancel the associated assistant data request
if (mAssistDataRequester != null) {
@@ -298,6 +298,16 @@
}
}
+ @Override
+ public void onAnimationFinished(@RecentsAnimationController.ReorderMode int reorderMode,
+ boolean runSychronously) {
+ if (runSychronously) {
+ finishAnimation(reorderMode);
+ } else {
+ mService.mHandler.post(() -> finishAnimation(reorderMode));
+ }
+ }
+
/**
* Called only when the animation should be canceled prior to starting.
*/
diff --git a/services/core/java/com/android/server/location/GnssGeofenceProvider.java b/services/core/java/com/android/server/location/GnssGeofenceProvider.java
new file mode 100644
index 0000000..6ac4aeb
--- /dev/null
+++ b/services/core/java/com/android/server/location/GnssGeofenceProvider.java
@@ -0,0 +1,188 @@
+package com.android.server.location;
+
+import android.location.IGpsGeofenceHardware;
+import android.os.Handler;
+import android.os.IBinder;
+import android.os.Looper;
+import android.util.Log;
+import android.util.SparseArray;
+
+import com.android.internal.annotations.VisibleForTesting;
+
+import java.util.concurrent.Callable;
+import java.util.concurrent.ExecutionException;
+import java.util.concurrent.FutureTask;
+
+/**
+ * Manages GNSS Geofence operations.
+ */
+class GnssGeofenceProvider extends IGpsGeofenceHardware.Stub {
+
+ private static final String TAG = "GnssGeofenceProvider";
+ private static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
+
+ /** Holds the parameters of a geofence. */
+ private static class GeofenceEntry {
+ public int geofenceId;
+ public double latitude;
+ public double longitude;
+ public double radius;
+ public int lastTransition;
+ public int monitorTransitions;
+ public int notificationResponsiveness;
+ public int unknownTimer;
+ public boolean paused;
+ }
+
+ private final GnssGeofenceProviderNative mNative;
+ private final SparseArray<GeofenceEntry> mGeofenceEntries = new SparseArray<>();
+ private final Handler mHandler;
+
+ GnssGeofenceProvider(Looper looper) {
+ this(looper, new GnssGeofenceProviderNative());
+ }
+
+ @VisibleForTesting
+ GnssGeofenceProvider(Looper looper, GnssGeofenceProviderNative gnssGeofenceProviderNative) {
+ mHandler = new Handler(looper);
+ mNative = gnssGeofenceProviderNative;
+ }
+
+ // TODO(b/37460011): use this method in HAL death recovery.
+ void resumeIfStarted() {
+ if (DEBUG) {
+ Log.d(TAG, "resumeIfStarted");
+ }
+ mHandler.post(() -> {
+ for (int i = 0; i < mGeofenceEntries.size(); i++) {
+ GeofenceEntry entry = mGeofenceEntries.valueAt(i);
+ boolean added = mNative.addGeofence(entry.geofenceId, entry.latitude,
+ entry.longitude,
+ entry.radius,
+ entry.lastTransition, entry.monitorTransitions,
+ entry.notificationResponsiveness, entry.unknownTimer);
+ if (added && entry.paused) {
+ mNative.pauseGeofence(entry.geofenceId);
+ }
+ }
+ });
+ }
+
+ private boolean runOnHandlerThread(Callable<Boolean> callable) {
+ FutureTask<Boolean> futureTask = new FutureTask<>(callable);
+ mHandler.post(futureTask);
+ try {
+ return futureTask.get();
+ } catch (InterruptedException | ExecutionException e) {
+ Log.e(TAG, "Failed running callable.", e);
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isHardwareGeofenceSupported() {
+ return runOnHandlerThread(mNative::isGeofenceSupported);
+ }
+
+ @Override
+ public boolean addCircularHardwareGeofence(int geofenceId, double latitude,
+ double longitude, double radius, int lastTransition, int monitorTransitions,
+ int notificationResponsiveness, int unknownTimer) {
+ return runOnHandlerThread(() -> {
+ boolean added = mNative.addGeofence(geofenceId, latitude, longitude, radius,
+ lastTransition, monitorTransitions, notificationResponsiveness,
+ unknownTimer);
+ if (added) {
+ GeofenceEntry entry = new GeofenceEntry();
+ entry.geofenceId = geofenceId;
+ entry.latitude = latitude;
+ entry.longitude = longitude;
+ entry.radius = radius;
+ entry.lastTransition = lastTransition;
+ entry.monitorTransitions = monitorTransitions;
+ entry.notificationResponsiveness = notificationResponsiveness;
+ entry.unknownTimer = unknownTimer;
+ mGeofenceEntries.put(geofenceId, entry);
+ }
+ return added;
+ });
+ }
+
+ @Override
+ public boolean removeHardwareGeofence(int geofenceId) {
+ return runOnHandlerThread(() -> {
+ boolean removed = mNative.removeGeofence(geofenceId);
+ if (removed) {
+ mGeofenceEntries.remove(geofenceId);
+ }
+ return removed;
+ });
+ }
+
+ @Override
+ public boolean pauseHardwareGeofence(int geofenceId) {
+ return runOnHandlerThread(() -> {
+ boolean paused = mNative.pauseGeofence(geofenceId);
+ if (paused) {
+ GeofenceEntry entry = mGeofenceEntries.get(geofenceId);
+ if (entry != null) {
+ entry.paused = true;
+ }
+ }
+ return paused;
+ });
+ }
+
+ @Override
+ public boolean resumeHardwareGeofence(int geofenceId, int monitorTransitions) {
+ return runOnHandlerThread(() -> {
+ boolean resumed = mNative.resumeGeofence(geofenceId, monitorTransitions);
+ if (resumed) {
+ GeofenceEntry entry = mGeofenceEntries.get(geofenceId);
+ if (entry != null) {
+ entry.paused = false;
+ entry.monitorTransitions = monitorTransitions;
+ }
+ }
+ return resumed;
+ });
+ }
+
+ @VisibleForTesting
+ static class GnssGeofenceProviderNative {
+ public boolean isGeofenceSupported() {
+ return native_is_geofence_supported();
+ }
+
+ public boolean addGeofence(int geofenceId, double latitude, double longitude, double radius,
+ int lastTransition, int monitorTransitions, int notificationResponsiveness,
+ int unknownTimer) {
+ return native_add_geofence(geofenceId, latitude, longitude, radius, lastTransition,
+ monitorTransitions, notificationResponsiveness, unknownTimer);
+ }
+
+ public boolean removeGeofence(int geofenceId) {
+ return native_remove_geofence(geofenceId);
+ }
+
+ public boolean resumeGeofence(int geofenceId, int transitions) {
+ return native_resume_geofence(geofenceId, transitions);
+ }
+
+ public boolean pauseGeofence(int geofenceId) {
+ return native_pause_geofence(geofenceId);
+ }
+ }
+
+ private static native boolean native_is_geofence_supported();
+
+ private static native boolean native_add_geofence(int geofenceId, double latitude,
+ double longitude, double radius, int lastTransition, int monitorTransitions,
+ int notificationResponsivenes, int unknownTimer);
+
+ private static native boolean native_remove_geofence(int geofenceId);
+
+ private static native boolean native_resume_geofence(int geofenceId, int transitions);
+
+ private static native boolean native_pause_geofence(int geofenceId);
+}
diff --git a/services/core/java/com/android/server/location/GnssLocationProvider.java b/services/core/java/com/android/server/location/GnssLocationProvider.java
index 756d06b..312b21c 100644
--- a/services/core/java/com/android/server/location/GnssLocationProvider.java
+++ b/services/core/java/com/android/server/location/GnssLocationProvider.java
@@ -419,6 +419,7 @@
private final LocationChangeListener mFusedLocationListener = new FusedLocationListener();
private final NtpTimeHelper mNtpTimeHelper;
private final GnssBatchingProvider mGnssBatchingProvider;
+ private final GnssGeofenceProvider mGnssGeofenceProvider;
// Handler for processing events
private Handler mHandler;
@@ -493,7 +494,7 @@
}
public IGpsGeofenceHardware getGpsGeofenceProxy() {
- return mGpsGeofenceBinder;
+ return mGnssGeofenceProvider;
}
public GnssMeasurementsProvider getGnssMeasurementsProvider() {
@@ -887,6 +888,7 @@
looper, this);
mHandler.post(mGnssSatelliteBlacklistHelper::updateSatelliteBlacklist);
mGnssBatchingProvider = new GnssBatchingProvider();
+ mGnssGeofenceProvider = new GnssGeofenceProvider(looper);
}
/**
@@ -1501,31 +1503,6 @@
}
}
- private IGpsGeofenceHardware mGpsGeofenceBinder = new IGpsGeofenceHardware.Stub() {
- public boolean isHardwareGeofenceSupported() {
- return native_is_geofence_supported();
- }
-
- public boolean addCircularHardwareGeofence(int geofenceId, double latitude,
- double longitude, double radius, int lastTransition, int monitorTransitions,
- int notificationResponsiveness, int unknownTimer) {
- return native_add_geofence(geofenceId, latitude, longitude, radius,
- lastTransition, monitorTransitions, notificationResponsiveness, unknownTimer);
- }
-
- public boolean removeHardwareGeofence(int geofenceId) {
- return native_remove_geofence(geofenceId);
- }
-
- public boolean pauseHardwareGeofence(int geofenceId) {
- return native_pause_geofence(geofenceId);
- }
-
- public boolean resumeHardwareGeofence(int geofenceId, int monitorTransition) {
- return native_resume_geofence(geofenceId, monitorTransition);
- }
- };
-
private boolean deleteAidingData(Bundle extras) {
int flags;
@@ -2813,19 +2790,6 @@
private native void native_update_network_state(boolean connected, int type,
boolean roaming, boolean available, String extraInfo, String defaultAPN);
- // Hardware Geofence support.
- private static native boolean native_is_geofence_supported();
-
- private static native boolean native_add_geofence(int geofenceId, double latitude,
- double longitude, double radius, int lastTransition, int monitorTransitions,
- int notificationResponsivenes, int unknownTimer);
-
- private static native boolean native_remove_geofence(int geofenceId);
-
- private static native boolean native_resume_geofence(int geofenceId, int transitions);
-
- private static native boolean native_pause_geofence(int geofenceId);
-
// Gps Hal measurements support.
private static native boolean native_is_measurement_supported();
diff --git a/services/core/java/com/android/server/om/OverlayManagerService.java b/services/core/java/com/android/server/om/OverlayManagerService.java
index fd51be5..3b8a994 100644
--- a/services/core/java/com/android/server/om/OverlayManagerService.java
+++ b/services/core/java/com/android/server/om/OverlayManagerService.java
@@ -694,25 +694,32 @@
private final class OverlayChangeListener
implements OverlayManagerServiceImpl.OverlayChangeListener {
@Override
- public void onOverlaysChanged(@NonNull final String targetPackageName, final int userId) {
+ public void onChanged(@NonNull final String targetPackageName, final int userId,
+ boolean targetChanged, boolean overlayChanged) {
schedulePersistSettings();
FgThread.getHandler().post(() -> {
- updateAssets(userId, targetPackageName);
-
- final Intent intent = new Intent(Intent.ACTION_OVERLAY_CHANGED,
- Uri.fromParts("package", targetPackageName, null));
- intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
-
- if (DEBUG) {
- Slog.d(TAG, "send broadcast " + intent);
+ // Update the targets' overlays if a change to the target or an overlay occurs
+ if (targetChanged || overlayChanged) {
+ updateAssets(userId, targetPackageName);
}
- try {
- ActivityManager.getService().broadcastIntent(null, intent, null, null, 0,
- null, null, null, android.app.AppOpsManager.OP_NONE, null, false, false,
- userId);
- } catch (RemoteException e) {
- // Intentionally left empty.
+ // Create the broadcast if the overlay changes
+ if (overlayChanged) {
+ final Intent intent = new Intent(Intent.ACTION_OVERLAY_CHANGED,
+ Uri.fromParts("package", targetPackageName, null));
+ intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
+
+ if (DEBUG) {
+ Slog.d(TAG, "send broadcast " + intent);
+ }
+
+ try {
+ ActivityManager.getService().broadcastIntent(null, intent, null, null, 0,
+ null, null, null, android.app.AppOpsManager.OP_NONE, null, false,
+ false, userId);
+ } catch (RemoteException e) {
+ // Intentionally left empty.
+ }
}
});
}
diff --git a/services/core/java/com/android/server/om/OverlayManagerServiceImpl.java b/services/core/java/com/android/server/om/OverlayManagerServiceImpl.java
index 74eb2ea..a487ae9 100644
--- a/services/core/java/com/android/server/om/OverlayManagerServiceImpl.java
+++ b/services/core/java/com/android/server/om/OverlayManagerServiceImpl.java
@@ -207,9 +207,7 @@
Slog.d(TAG, "onTargetPackageAdded packageName=" + packageName + " userId=" + userId);
}
- if (updateAllOverlaysForTarget(packageName, userId, 0)) {
- mListener.onOverlaysChanged(packageName, userId);
- }
+ updateAllOverlaysForTarget(packageName, userId, 0);
}
void onTargetPackageChanged(@NonNull final String packageName, final int userId) {
@@ -217,9 +215,7 @@
Slog.d(TAG, "onTargetPackageChanged packageName=" + packageName + " userId=" + userId);
}
- if (updateAllOverlaysForTarget(packageName, userId, 0)) {
- mListener.onOverlaysChanged(packageName, userId);
- }
+ updateAllOverlaysForTarget(packageName, userId, 0);
}
void onTargetPackageUpgrading(@NonNull final String packageName, final int userId) {
@@ -228,9 +224,7 @@
+ userId);
}
- if (updateAllOverlaysForTarget(packageName, userId, FLAG_TARGET_IS_UPGRADING)) {
- mListener.onOverlaysChanged(packageName, userId);
- }
+ updateAllOverlaysForTarget(packageName, userId, FLAG_TARGET_IS_UPGRADING);
}
void onTargetPackageUpgraded(@NonNull final String packageName, final int userId) {
@@ -238,9 +232,7 @@
Slog.d(TAG, "onTargetPackageUpgraded packageName=" + packageName + " userId=" + userId);
}
- if (updateAllOverlaysForTarget(packageName, userId, 0)) {
- mListener.onOverlaysChanged(packageName, userId);
- }
+ updateAllOverlaysForTarget(packageName, userId, 0);
}
void onTargetPackageRemoved(@NonNull final String packageName, final int userId) {
@@ -248,17 +240,17 @@
Slog.d(TAG, "onTargetPackageRemoved packageName=" + packageName + " userId=" + userId);
}
- if (updateAllOverlaysForTarget(packageName, userId, 0)) {
- mListener.onOverlaysChanged(packageName, userId);
- }
+ updateAllOverlaysForTarget(packageName, userId, 0);
}
/**
- * Returns true if the settings were modified for this target.
+ * Calls OverlayChangeListener#onChanged if the settings for the overlay target were modified,
+ * and calls OverlayChangeListener#onTargetChanged to signal a change in the target package that
+ * requires updating target overlays.
*/
- private boolean updateAllOverlaysForTarget(@NonNull final String targetPackageName,
+ private void updateAllOverlaysForTarget(@NonNull final String targetPackageName,
final int userId, final int flags) {
- boolean modified = false;
+ boolean overlayModified = false;
final List<OverlayInfo> ois = mSettings.getOverlaysForTarget(targetPackageName, userId);
final int N = ois.size();
for (int i = 0; i < N; i++) {
@@ -266,18 +258,19 @@
final PackageInfo overlayPackage = mPackageManager.getPackageInfo(oi.packageName,
userId);
if (overlayPackage == null) {
- modified |= mSettings.remove(oi.packageName, oi.userId);
+ overlayModified |= mSettings.remove(oi.packageName, oi.userId);
removeIdmapIfPossible(oi);
} else {
try {
- modified |= updateState(targetPackageName, oi.packageName, userId, flags);
+ overlayModified |= updateState(targetPackageName, oi.packageName, userId, flags);
} catch (OverlayManagerSettings.BadKeyException e) {
Slog.e(TAG, "failed to update settings", e);
- modified |= mSettings.remove(oi.packageName, userId);
+ overlayModified |= mSettings.remove(oi.packageName, userId);
}
}
}
- return modified;
+
+ mListener.onChanged(targetPackageName, userId, /* targetChanged */ true, overlayModified);
}
void onOverlayPackageAdded(@NonNull final String packageName, final int userId) {
@@ -298,7 +291,8 @@
overlayPackage.overlayCategory);
try {
if (updateState(overlayPackage.overlayTarget, packageName, userId, 0)) {
- mListener.onOverlaysChanged(overlayPackage.overlayTarget, userId);
+ mListener.onChanged(overlayPackage.overlayTarget, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
} catch (OverlayManagerSettings.BadKeyException e) {
Slog.e(TAG, "failed to update settings", e);
@@ -314,7 +308,8 @@
try {
final OverlayInfo oi = mSettings.getOverlayInfo(packageName, userId);
if (updateState(oi.targetPackageName, packageName, userId, 0)) {
- mListener.onOverlaysChanged(oi.targetPackageName, userId);
+ mListener.onChanged(oi.targetPackageName, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
} catch (OverlayManagerSettings.BadKeyException e) {
Slog.e(TAG, "failed to update settings", e);
@@ -331,7 +326,8 @@
final OverlayInfo oi = mSettings.getOverlayInfo(packageName, userId);
if (updateState(oi.targetPackageName, packageName, userId, FLAG_OVERLAY_IS_UPGRADING)) {
removeIdmapIfPossible(oi);
- mListener.onOverlaysChanged(oi.targetPackageName, userId);
+ mListener.onChanged(oi.targetPackageName, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
} catch (OverlayManagerSettings.BadKeyException e) {
Slog.e(TAG, "failed to update settings", e);
@@ -365,7 +361,8 @@
}
if (updateState(pkg.overlayTarget, packageName, userId, 0)) {
- mListener.onOverlaysChanged(pkg.overlayTarget, userId);
+ mListener.onChanged(pkg.overlayTarget, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
} catch (OverlayManagerSettings.BadKeyException e) {
Slog.e(TAG, "failed to update settings", e);
@@ -379,7 +376,8 @@
removeIdmapIfPossible(overlayInfo);
if (overlayInfo.isEnabled()) {
// Only trigger updates if the overlay was enabled.
- mListener.onOverlaysChanged(overlayInfo.targetPackageName, userId);
+ mListener.onChanged(overlayInfo.targetPackageName, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
}
} catch (OverlayManagerSettings.BadKeyException e) {
@@ -427,7 +425,8 @@
modified |= updateState(oi.targetPackageName, oi.packageName, userId, 0);
if (modified) {
- mListener.onOverlaysChanged(oi.targetPackageName, userId);
+ mListener.onChanged(oi.targetPackageName, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
return true;
} catch (OverlayManagerSettings.BadKeyException e) {
@@ -486,7 +485,8 @@
modified |= updateState(targetPackageName, packageName, userId, 0);
if (modified) {
- mListener.onOverlaysChanged(targetPackageName, userId);
+ mListener.onChanged(targetPackageName, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
return true;
} catch (OverlayManagerSettings.BadKeyException e) {
@@ -519,7 +519,8 @@
}
if (mSettings.setPriority(packageName, newParentPackageName, userId)) {
- mListener.onOverlaysChanged(overlayPackage.overlayTarget, userId);
+ mListener.onChanged(overlayPackage.overlayTarget, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
return true;
}
@@ -539,7 +540,8 @@
}
if (mSettings.setHighestPriority(packageName, userId)) {
- mListener.onOverlaysChanged(overlayPackage.overlayTarget, userId);
+ mListener.onChanged(overlayPackage.overlayTarget, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
return true;
}
@@ -559,7 +561,8 @@
}
if (mSettings.setLowestPriority(packageName, userId)) {
- mListener.onOverlaysChanged(overlayPackage.overlayTarget, userId);
+ mListener.onChanged(overlayPackage.overlayTarget, userId,
+ /* targetChanged */ false, /* overlayChanged */ true);
}
return true;
}
@@ -690,7 +693,8 @@
}
interface OverlayChangeListener {
- void onOverlaysChanged(@NonNull String targetPackage, int userId);
+ void onChanged(@NonNull String targetPackage, int userId,
+ boolean targetChanged, boolean overlayChanged);
}
interface PackageManagerHelper {
diff --git a/services/core/java/com/android/server/wm/OWNERS b/services/core/java/com/android/server/wm/OWNERS
new file mode 100644
index 0000000..fff42c5
--- /dev/null
+++ b/services/core/java/com/android/server/wm/OWNERS
@@ -0,0 +1,7 @@
+ogunwale@google.com
+jjaggi@google.com
+racarr@google.com
+chaviw@google.com
+brycelee@google.com
+akulian@google.com
+roosa@google.com
diff --git a/services/core/java/com/android/server/wm/RecentsAnimationController.java b/services/core/java/com/android/server/wm/RecentsAnimationController.java
index b057b1d..85e4ac7 100644
--- a/services/core/java/com/android/server/wm/RecentsAnimationController.java
+++ b/services/core/java/com/android/server/wm/RecentsAnimationController.java
@@ -83,9 +83,8 @@
private final RecentsAnimationCallbacks mCallbacks;
private final ArrayList<TaskAnimationAdapter> mPendingAnimations = new ArrayList<>();
private final int mDisplayId;
- private final Runnable mFailsafeRunnable = () -> {
- cancelAnimation(REORDER_MOVE_TO_ORIGINAL_POSITION, "failSafeRunnable");
- };
+ private final Runnable mFailsafeRunnable = () ->
+ cancelAnimation(REORDER_MOVE_TO_ORIGINAL_POSITION, "failSafeRunnable");
// The recents component app token that is shown behind the visibile tasks
private AppWindowToken mTargetAppToken;
@@ -112,7 +111,7 @@
private boolean mLinkedToDeathOfRunner;
public interface RecentsAnimationCallbacks {
- void onAnimationFinished(@ReorderMode int reorderMode);
+ void onAnimationFinished(@ReorderMode int reorderMode, boolean runSychronously);
}
private final IRecentsAnimationController mController =
@@ -164,7 +163,8 @@
// prior to calling the callback
mCallbacks.onAnimationFinished(moveHomeToTop
? REORDER_MOVE_TO_TOP
- : REORDER_MOVE_TO_ORIGINAL_POSITION);
+ : REORDER_MOVE_TO_ORIGINAL_POSITION,
+ true /* runSynchronously */);
} finally {
Binder.restoreCallingIdentity(token);
}
@@ -385,7 +385,17 @@
}
void cancelAnimation(@ReorderMode int reorderMode, String reason) {
- if (DEBUG_RECENTS_ANIMATIONS) Slog.d(TAG, "cancelAnimation(): reason=" + reason);
+ cancelAnimation(reorderMode, false /* runSynchronously */, reason);
+ }
+
+ void cancelAnimationSynchronously(@ReorderMode int reorderMode, String reason) {
+ cancelAnimation(reorderMode, true /* runSynchronously */, reason);
+ }
+
+ private void cancelAnimation(@ReorderMode int reorderMode, boolean runSynchronously,
+ String reason) {
+ if (DEBUG_RECENTS_ANIMATIONS) Slog.d(TAG, "cancelAnimation(): reason=" + reason
+ + " runSynchronously=" + runSynchronously);
synchronized (mService.getWindowManagerLock()) {
if (mCanceled) {
// We've already canceled the animation
@@ -401,8 +411,7 @@
}
// Clean up and return to the previous app
- // Don't hold the WM lock here as it calls back to AM/RecentsAnimation
- mCallbacks.onAnimationFinished(reorderMode);
+ mCallbacks.onAnimationFinished(reorderMode, runSynchronously);
}
void cleanupAnimation(@ReorderMode int reorderMode) {
diff --git a/services/core/java/com/android/server/wm/RootWindowContainer.java b/services/core/java/com/android/server/wm/RootWindowContainer.java
index fd965fb..50d0d0a 100644
--- a/services/core/java/com/android/server/wm/RootWindowContainer.java
+++ b/services/core/java/com/android/server/wm/RootWindowContainer.java
@@ -692,6 +692,7 @@
wallpaperDestroyed = true;
}
win.destroySurfaceUnchecked();
+ win.mWinAnimator.destroyPreservedSurfaceLocked();
} while (i > 0);
mService.mDestroySurface.clear();
}
diff --git a/services/core/java/com/android/server/wm/WindowManagerService.java b/services/core/java/com/android/server/wm/WindowManagerService.java
index 06e8d47..04554ef 100644
--- a/services/core/java/com/android/server/wm/WindowManagerService.java
+++ b/services/core/java/com/android/server/wm/WindowManagerService.java
@@ -2732,17 +2732,15 @@
/**
* Cancels any running recents animation. The caller should NOT hold the WM lock while calling
- * this method, as it can call back into AM, and locking will be done in the animation
- * controller itself.
+ * this method, as it will call back into AM and may cause a deadlock. Any locking will be done
+ * in the animation controller itself.
*/
- public void cancelRecentsAnimation(@RecentsAnimationController.ReorderMode int reorderMode,
- String reason) {
- // Note: Do not hold the WM lock, this will lock appropriately in the call which also
- // calls through to AM/RecentsAnimation.onAnimationFinished()
+ public void cancelRecentsAnimationSynchronously(
+ @RecentsAnimationController.ReorderMode int reorderMode, String reason) {
if (mRecentsAnimationController != null) {
// This call will call through to cleanupAnimation() below after the animation is
// canceled
- mRecentsAnimationController.cancelAnimation(reorderMode, reason);
+ mRecentsAnimationController.cancelAnimationSynchronously(reorderMode, reason);
}
}
diff --git a/services/core/jni/com_android_server_location_GnssLocationProvider.cpp b/services/core/jni/com_android_server_location_GnssLocationProvider.cpp
index 92ef9f1..3a9bbe4 100644
--- a/services/core/jni/com_android_server_location_GnssLocationProvider.cpp
+++ b/services/core/jni/com_android_server_location_GnssLocationProvider.cpp
@@ -1745,12 +1745,12 @@
}
}
-static jboolean android_location_GnssLocationProvider_is_geofence_supported(
+static jboolean android_location_GnssGeofenceProvider_is_geofence_supported(
JNIEnv* /* env */, jobject /* obj */) {
return (gnssGeofencingIface != nullptr) ? JNI_TRUE : JNI_FALSE;
}
-static jboolean android_location_GnssLocationProvider_add_geofence(JNIEnv* /* env */,
+static jboolean android_location_GnssGeofenceProvider_add_geofence(JNIEnv* /* env */,
jobject /* obj */, jint geofenceId, jdouble latitude, jdouble longitude, jdouble radius,
jint last_transition, jint monitor_transition, jint notification_responsiveness,
jint unknown_timer) {
@@ -1766,7 +1766,7 @@
return JNI_FALSE;
}
-static jboolean android_location_GnssLocationProvider_remove_geofence(JNIEnv* /* env */,
+static jboolean android_location_GnssGeofenceProvider_remove_geofence(JNIEnv* /* env */,
jobject /* obj */, jint geofenceId) {
if (gnssGeofencingIface != nullptr) {
auto result = gnssGeofencingIface->removeGeofence(geofenceId);
@@ -1777,7 +1777,7 @@
return JNI_FALSE;
}
-static jboolean android_location_GnssLocationProvider_pause_geofence(JNIEnv* /* env */,
+static jboolean android_location_GnssGeofenceProvider_pause_geofence(JNIEnv* /* env */,
jobject /* obj */, jint geofenceId) {
if (gnssGeofencingIface != nullptr) {
auto result = gnssGeofencingIface->pauseGeofence(geofenceId);
@@ -1788,7 +1788,7 @@
return JNI_FALSE;
}
-static jboolean android_location_GnssLocationProvider_resume_geofence(JNIEnv* /* env */,
+static jboolean android_location_GnssGeofenceProvider_resume_geofence(JNIEnv* /* env */,
jobject /* obj */, jint geofenceId, jint monitor_transition) {
if (gnssGeofencingIface != nullptr) {
auto result = gnssGeofencingIface->resumeGeofence(geofenceId, monitor_transition);
@@ -2178,20 +2178,6 @@
{"native_update_network_state",
"(ZIZZLjava/lang/String;Ljava/lang/String;)V",
reinterpret_cast<void *>(android_location_GnssLocationProvider_update_network_state)},
- {"native_is_geofence_supported",
- "()Z",
- reinterpret_cast<void *>(android_location_GnssLocationProvider_is_geofence_supported)},
- {"native_add_geofence",
- "(IDDDIIII)Z",
- reinterpret_cast<void *>(android_location_GnssLocationProvider_add_geofence)},
- {"native_remove_geofence",
- "(I)Z",
- reinterpret_cast<void *>(android_location_GnssLocationProvider_remove_geofence)},
- {"native_pause_geofence", "(I)Z", reinterpret_cast<void *>(
- android_location_GnssLocationProvider_pause_geofence)},
- {"native_resume_geofence",
- "(II)Z",
- reinterpret_cast<void *>(android_location_GnssLocationProvider_resume_geofence)},
{"native_is_measurement_supported",
"()Z",
reinterpret_cast<void *>(
@@ -2265,12 +2251,35 @@
reinterpret_cast<void *>(android_location_GnssBatchingProvider_cleanup_batching)},
};
+static const JNINativeMethod sGeofenceMethods[] = {
+ /* name, signature, funcPtr */
+ {"native_is_geofence_supported",
+ "()Z",
+ reinterpret_cast<void *>(android_location_GnssGeofenceProvider_is_geofence_supported)},
+ {"native_add_geofence",
+ "(IDDDIIII)Z",
+ reinterpret_cast<void *>(android_location_GnssGeofenceProvider_add_geofence)},
+ {"native_remove_geofence",
+ "(I)Z",
+ reinterpret_cast<void *>(android_location_GnssGeofenceProvider_remove_geofence)},
+ {"native_pause_geofence", "(I)Z", reinterpret_cast<void *>(
+ android_location_GnssGeofenceProvider_pause_geofence)},
+ {"native_resume_geofence",
+ "(II)Z",
+ reinterpret_cast<void *>(android_location_GnssGeofenceProvider_resume_geofence)},
+};
+
int register_android_server_location_GnssLocationProvider(JNIEnv* env) {
jniRegisterNativeMethods(
env,
"com/android/server/location/GnssBatchingProvider",
sMethodsBatching,
NELEM(sMethodsBatching));
+ jniRegisterNativeMethods(
+ env,
+ "com/android/server/location/GnssGeofenceProvider",
+ sGeofenceMethods,
+ NELEM(sGeofenceMethods));
return jniRegisterNativeMethods(
env,
"com/android/server/location/GnssLocationProvider",
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
index 51ce7c2..94f8f38 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
@@ -3961,8 +3961,6 @@
DevicePolicyData policy = getUserData(credentialOwner);
PasswordMetrics metrics = getUserPasswordMetricsLocked(credentialOwner);
if (metrics == null) {
- Slog.wtf(LOG_TAG, "Should have had a valid password metrics for updating checkpoint " +
- "validity.");
metrics = new PasswordMetrics();
}
policy.mPasswordValidAtLastCheckpoint =
@@ -4511,7 +4509,8 @@
}
if (metrics == null) {
- Slog.wtf(LOG_TAG, "FBE device, should have been unlocked and had valid metrics.");
+ // This could happen if the user never had a password set, for example, so
+ // setActivePasswordState has never been called for it.
metrics = new PasswordMetrics();
}
return isPasswordSufficientForUserWithoutCheckpointLocked(metrics, userHandle, parent);
diff --git a/services/robotests/src/com/android/server/location/GnssGeofenceProviderTest.java b/services/robotests/src/com/android/server/location/GnssGeofenceProviderTest.java
new file mode 100644
index 0000000..187303c
--- /dev/null
+++ b/services/robotests/src/com/android/server/location/GnssGeofenceProviderTest.java
@@ -0,0 +1,121 @@
+package com.android.server.location;
+
+import static org.mockito.Matchers.anyDouble;
+import static org.mockito.Matchers.anyInt;
+import static org.mockito.Matchers.eq;
+import static org.mockito.Mockito.times;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+
+import android.os.Looper;
+import android.os.RemoteException;
+import android.platform.test.annotations.Presubmit;
+
+import com.android.server.testing.FrameworkRobolectricTestRunner;
+import com.android.server.testing.SystemLoaderPackages;
+
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.robolectric.annotation.Config;
+
+/**
+ * Unit tests for {@link GnssGeofenceProvider}.
+ */
+@RunWith(FrameworkRobolectricTestRunner.class)
+@Config(
+ manifest = Config.NONE,
+ sdk = 27
+)
+@SystemLoaderPackages({"com.android.server.location"})
+@Presubmit
+public class GnssGeofenceProviderTest {
+ private static final int GEOFENCE_ID = 12345;
+ private static final double LATITUDE = 10.0;
+ private static final double LONGITUDE = 20.0;
+ private static final double RADIUS = 5.0;
+ private static final int LAST_TRANSITION = 0;
+ private static final int MONITOR_TRANSITIONS = 0;
+ private static final int NOTIFICATION_RESPONSIVENESS = 0;
+ private static final int UNKNOWN_TIMER = 0;
+ @Mock
+ private GnssGeofenceProvider.GnssGeofenceProviderNative mMockNative;
+ private GnssGeofenceProvider mTestProvider;
+
+ @Before
+ public void setUp() {
+ MockitoAnnotations.initMocks(this);
+ when(mMockNative.addGeofence(anyInt(), anyDouble(), anyDouble(), anyDouble(), anyInt(),
+ anyInt(), anyInt(), anyInt())).thenReturn(true);
+ when(mMockNative.pauseGeofence(anyInt())).thenReturn(true);
+ when(mMockNative.removeGeofence(anyInt())).thenReturn(true);
+ when(mMockNative.resumeGeofence(anyInt(), anyInt())).thenReturn(true);
+ mTestProvider = new GnssGeofenceProvider(Looper.myLooper(), mMockNative);
+ mTestProvider.addCircularHardwareGeofence(GEOFENCE_ID, LATITUDE,
+ LONGITUDE, RADIUS, LAST_TRANSITION, MONITOR_TRANSITIONS,
+ NOTIFICATION_RESPONSIVENESS,
+ UNKNOWN_TIMER);
+ }
+
+ @Test
+ public void addGeofence_nativeAdded() {
+ verify(mMockNative).addGeofence(eq(GEOFENCE_ID), eq(LATITUDE), eq(LONGITUDE),
+ eq(RADIUS), eq(LAST_TRANSITION), eq(MONITOR_TRANSITIONS),
+ eq(NOTIFICATION_RESPONSIVENESS),
+ eq(UNKNOWN_TIMER));
+ }
+
+ @Test
+ public void pauseGeofence_nativePaused() {
+ mTestProvider.pauseHardwareGeofence(GEOFENCE_ID);
+ verify(mMockNative).pauseGeofence(eq(GEOFENCE_ID));
+ }
+
+ @Test
+ public void removeGeofence_nativeRemoved() {
+ mTestProvider.removeHardwareGeofence(GEOFENCE_ID);
+ verify(mMockNative).removeGeofence(eq(GEOFENCE_ID));
+ }
+
+ @Test
+ public void resumeGeofence_nativeResumed() {
+ mTestProvider.pauseHardwareGeofence(GEOFENCE_ID);
+ mTestProvider.resumeHardwareGeofence(GEOFENCE_ID, MONITOR_TRANSITIONS);
+ verify(mMockNative).resumeGeofence(eq(GEOFENCE_ID), eq(MONITOR_TRANSITIONS));
+ }
+
+ @Test
+ public void addGeofence_restart_added() throws RemoteException {
+ mTestProvider.resumeIfStarted();
+
+ verify(mMockNative, times(2)).addGeofence(eq(GEOFENCE_ID), eq(LATITUDE), eq(LONGITUDE),
+ eq(RADIUS), eq(LAST_TRANSITION), eq(MONITOR_TRANSITIONS),
+ eq(NOTIFICATION_RESPONSIVENESS),
+ eq(UNKNOWN_TIMER));
+ }
+
+ @Test
+ public void removeGeofence_restart_notAdded() throws RemoteException {
+ mTestProvider.removeHardwareGeofence(GEOFENCE_ID);
+ mTestProvider.resumeIfStarted();
+
+ verify(mMockNative, times(1)).addGeofence(eq(GEOFENCE_ID), eq(LATITUDE), eq(LONGITUDE),
+ eq(RADIUS), eq(LAST_TRANSITION), eq(MONITOR_TRANSITIONS),
+ eq(NOTIFICATION_RESPONSIVENESS),
+ eq(UNKNOWN_TIMER));
+ }
+
+ @Test
+ public void pauseGeofence_restart_paused() throws RemoteException {
+ mTestProvider.pauseHardwareGeofence(GEOFENCE_ID);
+ mTestProvider.resumeIfStarted();
+
+ verify(mMockNative, times(2)).addGeofence(eq(GEOFENCE_ID), eq(LATITUDE), eq(LONGITUDE),
+ eq(RADIUS), eq(LAST_TRANSITION), eq(MONITOR_TRANSITIONS),
+ eq(NOTIFICATION_RESPONSIVENESS),
+ eq(UNKNOWN_TIMER));
+ verify(mMockNative, times(2)).pauseGeofence(eq(GEOFENCE_ID));
+ }
+}
diff --git a/telephony/java/android/telephony/PhoneStateListener.java b/telephony/java/android/telephony/PhoneStateListener.java
index c16701b..0ff2982 100644
--- a/telephony/java/android/telephony/PhoneStateListener.java
+++ b/telephony/java/android/telephony/PhoneStateListener.java
@@ -204,16 +204,6 @@
public static final int LISTEN_VOLTE_STATE = 0x00004000;
/**
- * Listen for OEM hook raw event
- *
- * @see #onOemHookRawEvent
- * @hide
- * @deprecated OEM needs a vendor-extension hal and their apps should use that instead
- */
- @Deprecated
- public static final int LISTEN_OEM_HOOK_RAW_EVENT = 0x00008000;
-
- /**
* Listen for carrier network changes indicated by a carrier app.
*
* @see #onCarrierNetworkRequest
@@ -377,9 +367,6 @@
case LISTEN_USER_MOBILE_DATA_STATE:
PhoneStateListener.this.onUserMobileDataStateChanged((boolean)msg.obj);
break;
- case LISTEN_OEM_HOOK_RAW_EVENT:
- PhoneStateListener.this.onOemHookRawEvent((byte[])msg.obj);
- break;
case LISTEN_CARRIER_NETWORK_CHANGE:
PhoneStateListener.this.onCarrierNetworkChange((boolean)msg.obj);
break;
@@ -596,16 +583,6 @@
}
/**
- * Callback invoked when OEM hook raw event is received. Requires
- * the READ_PRIVILEGED_PHONE_STATE permission.
- * @param rawData is the byte array of the OEM hook raw data.
- * @hide
- */
- public void onOemHookRawEvent(byte[] rawData) {
- // default implementation empty
- }
-
- /**
* Callback invoked when telephony has received notice from a carrier
* app that a network action that could result in connectivity loss
* has been requested by an app using
@@ -721,10 +698,6 @@
send(LISTEN_USER_MOBILE_DATA_STATE, 0, 0, enabled);
}
- public void onOemHookRawEvent(byte[] rawData) {
- send(LISTEN_OEM_HOOK_RAW_EVENT, 0, 0, rawData);
- }
-
public void onCarrierNetworkChange(boolean active) {
send(LISTEN_CARRIER_NETWORK_CHANGE, 0, 0, active);
}
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index c850004..3880f2f 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -6479,29 +6479,6 @@
return retVal;
}
- /**
- * Returns the result and response from RIL for oem request
- *
- * @param oemReq the data is sent to ril.
- * @param oemResp the respose data from RIL.
- * @return negative value request was not handled or get error
- * 0 request was handled succesfully, but no response data
- * positive value success, data length of response
- * @hide
- * @deprecated OEM needs a vendor-extension hal and their apps should use that instead
- */
- @Deprecated
- public int invokeOemRilRequestRaw(byte[] oemReq, byte[] oemResp) {
- try {
- ITelephony telephony = getITelephony();
- if (telephony != null)
- return telephony.invokeOemRilRequestRaw(oemReq, oemResp);
- } catch (RemoteException ex) {
- } catch (NullPointerException ex) {
- }
- return -1;
- }
-
/** @hide */
@SystemApi
@RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE)
diff --git a/telephony/java/com/android/internal/telephony/IPhoneStateListener.aidl b/telephony/java/com/android/internal/telephony/IPhoneStateListener.aidl
index 0d315e5..1cfe8c2 100644
--- a/telephony/java/com/android/internal/telephony/IPhoneStateListener.aidl
+++ b/telephony/java/com/android/internal/telephony/IPhoneStateListener.aidl
@@ -47,7 +47,6 @@
void onVoLteServiceStateChanged(in VoLteServiceState lteState);
void onVoiceActivationStateChanged(int activationState);
void onDataActivationStateChanged(int activationState);
- void onOemHookRawEvent(in byte[] rawData);
void onCarrierNetworkChange(in boolean active);
void onUserMobileDataStateChanged(in boolean enabled);
}
diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl
index 73cd498..7e8b2de 100644
--- a/telephony/java/com/android/internal/telephony/ITelephony.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl
@@ -1071,17 +1071,6 @@
in List<String> cdmaNonRoamingList);
/**
- * Returns the result and response from RIL for oem request
- *
- * @param oemReq the data is sent to ril.
- * @param oemResp the respose data from RIL.
- * @return negative value request was not handled or get error
- * 0 request was handled succesfully, but no response data
- * positive value success, data length of response
- */
- int invokeOemRilRequestRaw(in byte[] oemReq, out byte[] oemResp);
-
- /**
* Check if any mobile Radios need to be shutdown.
*
* @return true is any mobile radio needs to be shutdown
diff --git a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
index 0127db9..06dc13e 100644
--- a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
@@ -70,7 +70,6 @@
void notifyVoLteServiceStateChanged(in VoLteServiceState lteState);
void notifySimActivationStateChangedForPhoneId(in int phoneId, in int subId,
int activationState, int activationType);
- void notifyOemHookRawEventForSubscriber(in int subId, in byte[] rawData);
void notifySubscriptionInfoChanged();
void notifyCarrierNetworkChange(in boolean active);
void notifyUserMobileDataStateChangedForPhoneId(in int phoneId, in int subId, in boolean state);