- IntentTextReceiveActivityはシェアされたテキストを受け取る
- IntentUrlReceiveActivityは特定のURLを受け取る(http://play.google.com/store~)
Last active
December 23, 2015 17:19
-
-
Save sakebook/6668500 to your computer and use it in GitHub Desktop.
Intent Sample
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="YOUR_PACKAGE" | |
android:versionCode="1" | |
android:versionName="1.0.0" > | |
<uses-sdk | |
android:minSdkVersion="11" | |
android:targetSdkVersion="17" /> | |
<application | |
android:allowBackup="true" | |
android:icon="@drawable/ic_launcher" | |
android:label="@string/app_name" | |
android:theme="@style/AppTheme" > | |
<activity | |
android:name="YOUR_PACKAGE.MainActivity" | |
android:label="@string/app_name"> | |
<intent-filter> | |
<action android:name="android.intent.action.MAIN" /> | |
<category android:name="android.intent.category.LAUNCHER" /> | |
</intent-filter> | |
</activity> | |
<activity | |
android:name="YOUR_PACKAGE.IntentTextReceiveActivity" | |
android:label="@string/app_name" > | |
<intent-filter> | |
<action android:name="android.intent.action.SEND" /> | |
<category android:name="android.intent.category.DEFAULT" /> | |
<data android:mimeType="text/plain" /> | |
</intent-filter> | |
</activity> | |
<activity | |
android:name="YOUR_PACKAGE.IntentUrlReceiveActivity" | |
android:label="@string/app_name" > | |
<intent-filter> | |
<action android:name="android.intent.action.VIEW" /> | |
<category android:name="android.intent.category.DEFAULT" /> | |
<category android:name="android.intent.category.BROWSABLE" /> | |
<data android:scheme="http" | |
android:host="play.google.com" | |
android:pathPrefix="/store"/> | |
</intent-filter> | |
</activity> | |
</application> | |
</manifest> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment