0

インストールされている場合はAndroidブラウザーからアプリケーションを起動できるようにし、それ以外の場合はWebサイトを起動できるようにします。だからそれを機能させるために、私は置きます:

<activity android:name=".MMLogin" android:label="MeetMe" android:theme="@android:style/Theme.NoTitleBar" android:screenOrientation="portrait">
        <intent-filter>
    <data android:scheme="http" android:host="meet-me.com" android:path="/signin" />
    <action android:name="android.intent.action.VIEW" />
    <category android:name="android.intent.category.BROWSABLE"/>
    <category android:name="android.intent.category.DEFAULT" />
    </intent-filter>    
</activity>

マニフェストで、テスト用のダミーリンクを作成しました。そしてそれは機能していません。

  • 私はあるものとないものを試しました:BROWSABLEとDEFAULT

  • 私はmeetme:// datasを試して、スキームを変更しました。何も機能しませんでした。

私は次のようなstackoverflowでスレッドを使用しました: AndroidブラウザからカスタムAndroidアプリケーションを起動します

私は何を間違っているのですか、それともそれを機能させるために特別なことをする必要がありますか?私のアプリケーションはAPI7をサポートしています。

乾杯

4

1 に答える 1

0

私が使用 したのは、カスタムURIがクリックされたときにアクティビティを起動するためのインテントフィルターです。欠落していたのはこのブロックだと思います:

<intent-filter>
    <action android:name="android.intent.action.VIEW" />
    <action android:name="android.intent.action.EDIT" />
    <action android:name="android.intent.action.PICK" />
    <category android:name="android.intent.category.DEFAULT" />
    <category android:name="android.intent.category.BROWSABLE" />
    <category android:name="android.intent.category.DEFAULT" />
    <data android:mimeType="application/myapp" />
</intent-filter>
于 2011-12-13T11:00:47.660 に答える