Merge "Remove old NFC unlock api" into lmp-dev

This commit is contained in:
Andres Morales
2014-08-21 17:07:31 +00:00
committed by Android (Google) Code Review
3 changed files with 0 additions and 36 deletions

View File

@@ -18716,7 +18716,6 @@ package android.nfc {
method public boolean invokeBeam(android.app.Activity);
method public boolean isEnabled();
method public boolean isNdefPushEnabled();
method public boolean registerLockscreenDispatch(android.nfc.NfcAdapter.NfcLockscreenDispatch, java.lang.String[]);
method public void setBeamPushUris(android.net.Uri[], android.app.Activity);
method public void setBeamPushUrisCallback(android.nfc.NfcAdapter.CreateBeamUrisCallback, android.app.Activity);
method public void setNdefPushMessage(android.nfc.NdefMessage, android.app.Activity, android.app.Activity...);
@@ -18752,10 +18751,6 @@ package android.nfc {
method public abstract android.nfc.NdefMessage createNdefMessage(android.nfc.NfcEvent);
}
public static abstract interface NfcAdapter.NfcLockscreenDispatch {
method public abstract boolean onTagDetected(android.nfc.Tag);
}
public static abstract interface NfcAdapter.OnNdefPushCompleteCallback {
method public abstract void onNdefPushComplete(android.nfc.NfcEvent);
}

View File

@@ -57,7 +57,6 @@ interface INfcAdapter
void setReaderMode (IBinder b, IAppCallback callback, int flags, in Bundle extras);
void setP2pModes(int initatorModes, int targetModes);
void registerLockscreenDispatch(INfcLockscreenDispatch lockscreenDispatch, in int[] techList);
void addNfcUnlockHandler(INfcUnlockHandler unlockHandler, in int[] techList);
void removeNfcUnlockHandler(INfcUnlockHandler unlockHandler);
}

View File

@@ -384,16 +384,6 @@ public final class NfcAdapter {
public Uri[] createBeamUris(NfcEvent event);
}
/**
* A callback to be invoked when an application has registered for receiving
* tags at the lockscreen.
*/
public interface NfcLockscreenDispatch {
public boolean onTagDetected(Tag tag);
}
/**
* A callback to be invoked when an application has registered as a
* handler to unlock the device given an NFC tag at the lockscreen.
@@ -1468,26 +1458,6 @@ public final class NfcAdapter {
}
}
public boolean registerLockscreenDispatch(final NfcLockscreenDispatch lockscreenDispatch,
String[] techList) {
try {
sService.registerLockscreenDispatch(new INfcLockscreenDispatch.Stub() {
@Override
public boolean onTagDetected(Tag tag) throws RemoteException {
return lockscreenDispatch.onTagDetected(tag);
}
}, Tag.getTechCodesFromStrings(techList));
} catch (RemoteException e) {
attemptDeadServiceRecovery(e);
return false;
} catch (IllegalArgumentException e) {
Log.e(TAG, "Unable to register LockscreenDispatch", e);
return false;
}
return true;
}
/**
* Registers a new NFC unlock handler with the NFC service.
*