intentfilter - Android Open File Associations -
i can open custom file extensions when accessing browser links without problem. how can associate app file extensions locally on device?
specifically to: 1) open file has been downloaded - drag notifications screen top of display lists recent .xm files have been downloaded. able tap on , have application open these files.
2) likewise other file explorer apps if possible.
here intent filters. missing?
<intent-filter> <action android:name="android.intent.action.main" /> <category android:name="android.intent.category.launcher" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.view" /> <category android:name="android.intent.category.default" /> <data android:scheme="file" /> <data android:pathpattern=".*\\.xm" /> <data android:host="*" /> <data android:mimetype="text/plain"/> </intent-filter> <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" /> <data android:mimetype="*/*" /> <data android:pathpattern=".*\\.xm" /> <data android:host="*" /> </intent-filter> update: see below filters
<intent-filter> <action android:name="android.intent.action.view" /> <action android:name="android.intent.action.edit" /> <category android:name="android.intent.category.default" /> <data android:mimetype="application/octet-stream" android:host="*" android:pathpattern=".*\\.xm" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.view" /> <action android:name="android.intent.action.edit" /> <category android:name="android.intent.category.default" /> <data android:mimetype="application/mytype" android:host="*" android:pathpattern=".*\\.xm" />
this post has helped me solved problem. i'm including required intent filters above in original question.
Comments
Post a Comment