Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for android action.VIEW intent filter #58

Open
Mounix99 opened this issue Jun 2, 2023 · 4 comments
Open

Add support for android action.VIEW intent filter #58

Mounix99 opened this issue Jun 2, 2023 · 4 comments

Comments

@Mounix99
Copy link
Contributor

Mounix99 commented Jun 2, 2023

I think it is possible to add support for this intent filter for android

<intent-filter>
    <action android:name="android.intent.action.VIEW" />
    <category android:name="android.intent.category.DEFAULT" />
    <data android:mimeType="image/*" />
</intent-filter>

This filter is used for "Open with" option on android. It would be cool to have support for it among with other intent filters in this package

@starshipcoder
Copy link

starshipcoder commented Jul 7, 2023

The lib seems to support this intent, in my case it works with

`

            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />

            <category android:name="android.intent.category.BROWSABLE" />

            <data android:scheme="file" />

            <data android:scheme="http" />

            <data android:scheme="https" />

            <data android:scheme="content" />

            <data android:mimeType="*/*" />

            <data android:pathPattern=".*\.csv" />

            <data android:pathPattern=".*\.CSV" />

            <data android:host="*" />

        </intent-filter>

`

The problem is I receive an url (in content) and the attachments are null
I would prefere to receive the corresponding file or at least the content of the file

@Mounix99
Copy link
Contributor Author

Mounix99 commented Jul 9, 2023

@starshipcoder Same for me, by "add support" I meant replacing the URL with a direct attachment.

@filipenanclarez
Copy link

filipenanclarez commented Sep 11, 2023

@Mounix99 and @starshipcoder please look this comment:

KasemJaffer/receive_sharing_intent#160 (comment)

;)

@Mounix99
Copy link
Contributor Author

@filipenanclarez Thanks, this works as expected. But I have one more problem with that, I use go_router navigation and deep links and now it redirects me by content uri to "page not found" (as it should) Do you know any ways to block or disable redirection by content:// scheme but still have this "open with" option for files ?

Liloupar added a commit to Liloupar/share_handler that referenced this issue Jan 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants