读取nfc数据和写入数据
This commit is contained in:
@@ -5,11 +5,13 @@
|
||||
<!--NFC权限-->
|
||||
<uses-permission android:name="android.permission.NFC" />
|
||||
<!--声明只有带NFC的手机才可以下载-->
|
||||
<uses-feature android:name="android.hardware.nfc" android:required="true" />
|
||||
|
||||
<uses-feature
|
||||
android:name="android.hardware.nfc"
|
||||
android:required="true" />
|
||||
|
||||
|
||||
<application
|
||||
android:name=".base.BaseApplication"
|
||||
android:allowBackup="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/app_name"
|
||||
@@ -24,28 +26,39 @@
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
|
||||
<activity
|
||||
android:name=".activity.nfc.NfcActivity"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.nfc.action.NDEF_DISCOVERED" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="text/plain" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.nfc.action.TECH_DISCOVERED" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="text/plain" /> <!-- 指定数据类型 -->
|
||||
</intent-filter>
|
||||
|
||||
<meta-data
|
||||
android:name="android.nfc.action.TECH_DISCOVERED"
|
||||
android:resource="@xml/nfc_tech_filter" />
|
||||
</activity>
|
||||
|
||||
<activity
|
||||
android:name=".activity.nfc.NfcActivity"
|
||||
android:exported="true"
|
||||
android:launchMode="singleTop">
|
||||
<!-- <intent-filter>-->
|
||||
<!-- <action android:name="android.nfc.action.NDEF_DISCOVERED" />-->
|
||||
<!-- <category android:name="android.intent.category.DEFAULT" />-->
|
||||
<!-- <data android:mimeType="text/plain" />-->
|
||||
<!-- </intent-filter>-->
|
||||
<!-- <intent-filter>-->
|
||||
<!-- <action android:name="android.nfc.action.TECH_DISCOVERED" />-->
|
||||
<!-- </intent-filter>-->
|
||||
|
||||
<!-- <meta-data-->
|
||||
<!-- android:name="android.nfc.action.TECH_DISCOVERED"-->
|
||||
<!-- android:resource="@xml/nfc_tech_filter" />-->
|
||||
</activity>
|
||||
|
||||
<service
|
||||
android:name="com.google.android.accessibility.selecttospeak.SelectToSpeakService"
|
||||
android:label="@string/accessibility_service_label"
|
||||
android:exported="true"
|
||||
android:label="@string/accessibility_service_label"
|
||||
android:permission="android.permission.BIND_ACCESSIBILITY_SERVICE">
|
||||
|
||||
<!-- android:priority="10000" 可提高服务在设置中的权重,排在前面 -->
|
||||
@@ -58,7 +71,12 @@
|
||||
android:resource="@xml/accessibility_service_config" />
|
||||
</service>
|
||||
|
||||
|
||||
<meta-data
|
||||
android:name="design_width_in_dp"
|
||||
android:value="360" />
|
||||
<meta-data
|
||||
android:name="design_height_in_dp"
|
||||
android:value="640" />
|
||||
</application>
|
||||
|
||||
</manifest>
|
||||
Reference in New Issue
Block a user