0

In Android ICS, there are 3 ways to share data by P2P. 1. enableForegroundNdefPush(existed from gingerbread) 2. setdefPushMessage 3. setNdefPushMessageCallback

As I tried, in Android ICS, calling enableForegroundNdefPush pop "Tap to share" UI to beam the data if "Tap to share" setting is on. Is there any way to share data by P2P without popping "Tap to share" UI even if "Tap to share" setting is on as enableForegroundNdefPush did in Android gingerbread.

Moreover, setLocalNdefMessage is removed from ICS, is there other API I could use to replace it?

Thanks for your help.

kun
  • 1
  • 1

1 Answers1

0

No, at this moment there is no API to disable the UI when sharing P2P data.

setLocalNdefMessage() no longer exists, because almost every application will now share something over NFC by default - if the app itself doesn't share anything, the framework will automatically share a link to the app.

Martijn Coenen
  • 971
  • 6
  • 8