summaryrefslogtreecommitdiffstats
path: root/core/java
diff options
context:
space:
mode:
authorMartijn Coenen <martijn.coenen@nxp.com>2010-12-13 12:31:29 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2010-12-13 12:31:29 -0800
commitc26ba7dd2786f4a25f28831db508ecf63cfbbd11 (patch)
treeed96c458d40643a9547c5df88be34b2bf1f343a1 /core/java
parent4e656372bd89a9b6e75ef01861b6224f83b055d0 (diff)
parent41e74b991bc50bfa16ba920e998c76a88aa8ae69 (diff)
downloadframeworks_base-c26ba7dd2786f4a25f28831db508ecf63cfbbd11.zip
frameworks_base-c26ba7dd2786f4a25f28831db508ecf63cfbbd11.tar.gz
frameworks_base-c26ba7dd2786f4a25f28831db508ecf63cfbbd11.tar.bz2
am 41e74b99: am b79173f6: Changed technology close() to reconnect to the tag instead of physical disconnect.
* commit '41e74b991bc50bfa16ba920e998c76a88aa8ae69': Changed technology close() to reconnect to the tag instead of physical disconnect.
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/nfc/INfcTag.aidl1
-rw-r--r--core/java/android/nfc/technology/BasicTagTechnology.java5
2 files changed, 5 insertions, 1 deletions
diff --git a/core/java/android/nfc/INfcTag.aidl b/core/java/android/nfc/INfcTag.aidl
index 69e5bc7..852ab5e 100644
--- a/core/java/android/nfc/INfcTag.aidl
+++ b/core/java/android/nfc/INfcTag.aidl
@@ -25,6 +25,7 @@ interface INfcTag
{
int close(int nativeHandle);
int connect(int nativeHandle);
+ int reconnect(int nativeHandle);
int[] getTechList(int nativeHandle);
byte[] getUid(int nativeHandle);
boolean isNdef(int nativeHandle);
diff --git a/core/java/android/nfc/technology/BasicTagTechnology.java b/core/java/android/nfc/technology/BasicTagTechnology.java
index ba8bd55..a50c10b 100644
--- a/core/java/android/nfc/technology/BasicTagTechnology.java
+++ b/core/java/android/nfc/technology/BasicTagTechnology.java
@@ -162,7 +162,10 @@ import android.util.Log;
public void close() {
mIsConnected = false;
try {
- mTagService.close(mTag.getServiceHandle());
+ /* Note that we don't want to physically disconnect the tag,
+ * but just reconnect to it to reset its state
+ */
+ mTagService.reconnect(mTag.getServiceHandle());
} catch (RemoteException e) {
attemptDeadServiceRecovery(e);
}