summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoman Birg <roman@cyngn.com>2016-06-09 17:33:28 -0700
committerGerrit Code Review <gerrit@cyanogenmod.org>2016-06-10 16:22:21 -0700
commite39d1d75b95c02b7fb055d7caab535c8e1e919ad (patch)
treef03161babc733cea444f53e0fa0a7e9fb1d5cf72
parent2c755a67e3eb7e3dd85a0de58507005436ed6588 (diff)
downloadframeworks_base-e39d1d75b95c02b7fb055d7caab535c8e1e919ad.zip
frameworks_base-e39d1d75b95c02b7fb055d7caab535c8e1e919ad.tar.gz
frameworks_base-e39d1d75b95c02b7fb055d7caab535c8e1e919ad.tar.bz2
Revert "base: start nfc service prior to systemui"
We no longer need to start NFC before anything else, System UI will properly handle getting a proper refernce to the Nfc Adapter. This reverts commit 1882a02f21f9e79550000e2b68a37acf21f26ec2. Ticket: OPO-755 Change-Id: I14514746a55fe89e6960f4e453309da5d21012f0
-rw-r--r--services/java/com/android/server/SystemServer.java28
1 files changed, 0 insertions, 28 deletions
diff --git a/services/java/com/android/server/SystemServer.java b/services/java/com/android/server/SystemServer.java
index 671bf89..f6a0619 100644
--- a/services/java/com/android/server/SystemServer.java
+++ b/services/java/com/android/server/SystemServer.java
@@ -1189,15 +1189,6 @@ public final class SystemServer {
Slog.i(TAG, "WebViewFactory preparation");
WebViewFactory.prepareWebViewInSystemServer();
- // Start Nfc before SystemUi to ensure NfcTile and other apps gets a
- // valid NfcAdapter from NfcManager
- try {
- startNfcService(context);
- } catch (Throwable e) {
- // Don't crash. Nfc is an optional service. Just annotate that isn't ready
- Slog.e(TAG, "Nfc service didn't start. Nfc will not be available.", e);
- }
-
try {
startSystemUi(context);
} catch (Throwable e) {
@@ -1316,23 +1307,4 @@ public final class SystemServer {
//Slog.d(TAG, "Starting service: " + intent);
context.startServiceAsUser(intent, UserHandle.OWNER);
}
-
- static final void startNfcService(Context context) {
- IPackageManager pm = ActivityThread.getPackageManager();
- if (pm == null) {
- Slog.w(TAG, "Cannot get package manager, assuming no NFC feature");
- return;
- }
- try {
- if (pm.hasSystemFeature(PackageManager.FEATURE_NFC)) {
- Intent intent = new Intent();
- intent.setComponent(new ComponentName("com.android.nfc",
- "com.android.nfc.NfcBootstrapService"));
- context.startServiceAsUser(intent, UserHandle.OWNER);
- }
- } catch (RemoteException e) {
- Slog.w(TAG, "Package manager query failed, assuming no NFC feature", e);
- return;
- }
- }
}