Skip to content

Commit 8ce7a27

Browse files
author
Nick Pelly
committed
Use Application#registerLifecycleEvents() instead of a Fragment for Beam.
Fragments don't work as desired if called after life-cycle events such as onDestory() or onSaveInstanceState(). The new approach doesn't work after onDestroy() either, but we can more easily detect this now. For pre-JB apps, we will log an error, and for JB and onwards we will throw. Update documentation to make these rules clear, and to encourage the use of a single Activity per API call, and to make the call in onCreate(). Bug: 5199662 Bug: 5994691 Bug: 6034901 Bug: 6125297 Change-Id: Ib0dde6abfa44cd56c7ddc13ba0ad0e83bbe30058
1 parent 3e67922 commit 8ce7a27

File tree

4 files changed

+406
-280
lines changed

4 files changed

+406
-280
lines changed

core/java/android/nfc/INfcAdapter.aidl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ interface INfcAdapter
4242

4343
void setForegroundDispatch(in PendingIntent intent,
4444
in IntentFilter[] filters, in TechListParcel techLists);
45-
void setForegroundNdefPush(in NdefMessage msg, in INdefPushCallback callback);
45+
void setNdefPushCallback(in INdefPushCallback callback);
4646

4747
void dispatch(in Tag tag);
4848

0 commit comments

Comments
 (0)